Merge pull request 'Fix Dockerfile healthcheck for Coolify PORT override' (#2) from agent/opencode-deepseek/1fa9d179 into main
All checks were successful
CI / validate (push) Successful in 23m18s
All checks were successful
CI / validate (push) Successful in 23m18s
Reviewed-on: #2
This commit was merged in pull request #2.
This commit is contained in:
@@ -63,8 +63,10 @@ COPY --from=build /app/packages/game-engine packages/game-engine
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
# Coolify (and other hosts) override PORT at runtime; probe that port, not a
|
||||
# hardcoded one.
|
||||
HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 \
|
||||
CMD node -e "fetch('http://127.0.0.1:3000/').then(r=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))"
|
||||
CMD node -e "fetch('http://127.0.0.1:' + (process.env.PORT || 3000) + '/').then(r=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))"
|
||||
|
||||
# The Nuxt web server reads its config through Nuxt runtimeConfig, which is
|
||||
# baked at build time and overridden at runtime only by NUXT_-prefixed env
|
||||
|
||||
Reference in New Issue
Block a user