CheckMk in a Docker Container

For big infrastructures you shoul'd deploy checkmk NOT as a docker container. But for small to medium sized structures there is the possibility to do so.
Lets start with the Caddyfile:
checkmk.youredomain.io:443 {
tls /certs/certificate.cer /certs/private_key.key
header Strict-Transport-Security max-age=31536000;
reverse_proxy localhost:8888
log {
format transform {common_log}
output file /data/log/access.log {
roll_size 10mb
roll_keep 10
roll_keep_for 36h
}
}
}
Here is my docker-compose file for checkmk.
version: '3.8'
services:
monitoring:
image: checkmk/check-mk-raw:2.3.0-latest
container_name: checkmk
ports:
- "8888:5000"
- "9080:8000"
tmpfs:
- /opt/omd/sites/cmk/tmp:uid=1000,gid=1000
volumes:
- checkmk:/omd/sites
- /etc/localtime:/etc/localtime:ro
restart: always
volumes:
checkmk:
compose it up.
docker-compose up
you should see the password initially created for your cmkadmin account.
Open the port 9080. On this port checkmk is listening or the clients.
Login into you're domain with it and than change it instantly.
Congratulation you're cmk instance is up and running.