Closed wna-se closed 7 months ago
After reading up on the changes made to docker compose over the last few years I found that you can override extra_hosts
(and any other key) like this: extra_hosts: !override []
It seems like the issue related to formatting the healthcheck.test
command relates to the fact that the docker-compose
implementation interacts with an API that is not directly supported by Podman. The podman-compose
implementation supposably supports the healthcheck syntax but does not support the version required to support the extends
in combination with depends_on
.
Solved by #13
There are some differences in default configurations and available features across Podman and Docker. This issue will collect reflections and workarounds to make the instructions work on Podman.
Background
Originally posted by @wna-se in https://github.com/NBISweden/ejprd/issues/6#issuecomment-2025542134
I managed to get it running by changing some of the configurations and disabling some of the health checks. A summary of my “hacks” in hopes of finding better solutions. Also, is there a particular reason for using the host network?
rabbitmq
Need to run as user rabbitmq to avoid the permission related issue from my first comment and the health check always fails for some reason (running the same command in the container itself using compose exec rabbitmq is successful). I also named the volume defined in the rabbitmq base Docker file.
Edit: Seems like reformatting the value for healthcheck test solves the problem for Podman, e.g.
test: rabbitmq-diagnostics -q check_running && rabbitmq-diagnostics -q check_local_alarms
s3inbox, download, oidc
Removed the
extra_hosts
section relying on thehost-gateway
keyword since it’s not available in Podman and instead set the environment variableDOCKERHOST=host.containers.internal
to access the host network directly. I made the changes in thedocker-compose.yml
file since I didn’t find a way to override it in thedocker-compose-demo.yml
.oidc
Health check always fails for some reason (running the same command in the container itself using compose exec oidc is successful), e.g.
test: [ "CMD", "sh", "-c", "true" ]
.Edit: Seems like reformatting the value for healthcheck test solves the problem for Podman, e.g.
test: python3 -c 'import requests; print(requests.get(url = "https://localhost:8080/jwk", verify="/shared/cert/ca.crt").text)'