Skip to Content
Menu
This question has been flagged
1 Reply
647 Views

Hi Community,

I’m setting up Odoo 18 in Docker with HashiCorp Vault for secrets management, but the container fails health checks. Here’s my setup:

Error:

ERROR: for odoo Container "8659c****02" is unhealthy. ERROR: Encountered errors while bringing up the project.

Configuration:dp

  1. Docker Compose:
    services:
      vault:
        image: hashicorp/vault
        # ... (dev mode setup)
      odoo:
        depends_on:
          vault:
            condition: service_healthy
        healthcheck:
          test: ["CMD", "curl", "-f", "http://localhost:8069/web/health"]
  2. Symptoms:
    • Odoo container starts but exits as "unhealthy"
    • Vault logs show successful secret storage
    • Manual curl to http://localhost:8069 works

What I’ve Tried:

✅ Verified Vault secrets are injected (docker exec odoo cat /etc/odoo/odoo.conf)

✅ Increased start_period to 120s

✅ Added workers = 0 to odoo.conf for debugging

Need Help With:

  1. Why does the health check fail despite Odoo responding?
  2. Are there better health check parameters for Odoo?
  3. How to debug Vault-Odoo connection issues?
Avatar
Discard
Best Answer

The thing is that curl may not installed inside your container.

I don't know Odoo, but I've just solved the same problem with Vault. 

I tried 

test: ["CMD", "curl", "-f", "http://localhost:8200/v1/sys/health"]

got the same error, made "docker inspect my-app-vault-1" command to get a log and here's what I found out: 

"Output": "OCI runtime exec failed: exec failed: unable to start container process: exec: \"curl\": executable file not found in $PATH: unknown"

So I replaced test field with:

test: ["CMD", "vault", "status", "-address=http://127.0.0.1:8200"]

where "vault" is a CLI command and now everything's ok. 

Maybe this will help you or someone else.

Avatar
Discard
Related Posts Replies Views Activity
1
Jun 25
11035
1
Nov 22
4159
1
Nov 20
6211
6
Jun 20
22776
1
Aug 25
2254