OpenTAKServer icon indicating copy to clipboard operation
OpenTAKServer copied to clipboard

Health Check Url

Open nerdalertdk opened this issue 10 months ago • 0 comments

Hi

I'm not the biggest python person. But i tried to add an url that have no auth so I can add healthcheck to the Docker setup I'm working on.

This also helps me "boot" the containers in the correct order.

docker ps --format "table {{.Names}}\t{{.Status}}"
NAMES           STATUS
opentakserver   Up 15 minutes
rabbitmq        Up 15 minutes (healthy)
nginx           Up 15 minutes (healthy)

As you see opentakserver is missing !


Added one to nginx also

server {

    listen 80;
    server_name _;

    location = /health {
        access_log off;
        add_header 'Content-Type' 'application/json';
        return 200 '{"status":"healthy"}';
    }

}
curl -k https://localhost/health
{"status":"healthy"}

nerdalertdk avatar Apr 26 '24 13:04 nerdalertdk