An example apache virtual host for reverse proxy of everything to a checkmk instance

Hi all, can someone please give me a definitive apache2 virtualhost configuration for proxying to my checkmk instance?
So far I’ve not found anything that works. I have many virtual hosts proxying to many different installed apps/services across my servers so I’m not coming at this as a newbie.
I’ve installed check-mk-cloud-2.4.0.p21 on my Debian 12 physical host, check-mk is running and bound to 127.0.0.1:5000 so I’m unable to reach it from my PC and the server is headless.
My apache2 instance is on the same physical server so I just need to proxy to localhost.

Any help would be greatly appreciated as I’m trying to trial this initially for myself so I can then demonstrate it to the higher ups at work.

Thanks in advance.
Martin

At installation time of the first CMK package it installs the only needed configuration to the system Apache.

–> /etc/apache2/conf-enabled/zzz_omd.conf → ../conf-available/zzz_omd.conf

And this file is also really small

Include /omd/apache/*.conf

That’s all what is needed inside the system Apache.

Inside the /omd/apache/ folder every created site stores the config needed for the system Apache to reach this site.

What is not working on your system if you try to reach your site?

2 Likes

Hi Andreas, thanks for the quick and detailed reply. I understand now and I’ve got it working after adding ‘Include /omd/apache/*.conf’ to my apache2 configuration.
My apache2 is very locked down for security reasons and only includes virtual hosts from sites-enabled so the /omd/ ones weren’t getting picked up.
I’ll see about getting a single VirtualHost working from the /omd/apache2/ one as there are tests for source IP ranges and client certificate checks.
Thank you again for pointing me in the right direction and happy for this case to be closed.
Martin