-
Notifications
You must be signed in to change notification settings - Fork 2k
fix(docker compose): make ports optional #5500
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -53,8 +53,8 @@ services: | |||||||||
- inference_model_server | ||||||||||
- minio | ||||||||||
restart: unless-stopped | ||||||||||
# ports: | ||||||||||
# - "8080:8080" | ||||||||||
ports: | ||||||||||
- "${API_PORT:-}" | ||||||||||
|
- "${API_PORT:-}" | |
- "${API_PORT:-8080:8080}" |
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interpolating an empty value for API_PORT results in an invalid ports entry and docker-compose parsing failure. Provide a valid default mapping or remove the ports block when not mapping ports.
Prompt for AI agents
Address the following comment on deployment/docker_compose/docker-compose.yml at line 57:
<comment>Interpolating an empty value for API_PORT results in an invalid ports entry and docker-compose parsing failure. Provide a valid default mapping or remove the ports block when not mapping ports.</comment>
<file context>
@@ -53,8 +53,8 @@ services:
- # ports:
- # - "8080:8080"
+ ports:
+ - "${API_PORT:-}"
environment:
# Auth Settings
</file context>
- "${API_PORT:-}" | |
- "${API_PORT:-8080:8080}" |
✅ Addressed in 2fea661
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: Same issue with empty environment variable expansion for Postgres port.
- "${POSTGRES_PORT:-}" | |
- "${POSTGRES_PORT:-5432:5432}" |
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interpolating an empty value for POSTGRES_PORT results in an invalid ports entry and docker-compose parsing failure. Provide a valid default mapping or remove the ports block when not mapping ports.
Prompt for AI agents
Address the following comment on deployment/docker_compose/docker-compose.yml at line 232:
<comment>Interpolating an empty value for POSTGRES_PORT results in an invalid ports entry and docker-compose parsing failure. Provide a valid default mapping or remove the ports block when not mapping ports.</comment>
<file context>
@@ -228,8 +228,8 @@ services:
- # ports:
- # - "5432:5432"
+ ports:
+ - "${POSTGRES_PORT:-}"
volumes:
- db_volume:/var/lib/postgresql/data
</file context>
- "${POSTGRES_PORT:-}" | |
- "${POSTGRES_PORT:-5432:5432}" |
✅ Addressed in 2fea661
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unnecessary host port exposure for Postgres; tests use the Docker network (relational_db) and do not require binding 5432 on the host. This can cause port conflicts and increases attack surface in CI.
Prompt for AI agents
✅ Addressed in
2fea661