Skip to content

Don't require separately built nginx container#30

Draft
mattcen wants to merge 1 commit into
mainfrom
nginx-tidy
Draft

Don't require separately built nginx container#30
mattcen wants to merge 1 commit into
mainfrom
nginx-tidy

Conversation

@mattcen
Copy link
Copy Markdown
Owner

@mattcen mattcen commented Apr 25, 2026

Important

Needs testing before merge

Often when running an nginx container or similar, one might use the
upstream container image but override its config by using a volume to
bind-mount in a new config file from a local directory.

If running docker compose targeting a remote host, the bind-mount
looks for its source on the remote host, rather than the local, so the
sought file doesn't exist.

I'd been working around this by building a custom nginx container whose
only change was its config.

This change instead uses an inline Docker Config object to work around
this. I'd tried sourcing the config object from a local file, but this
has the same problem as the above, in that it looks for the config
source on the remote host.

Often when running an nginx container or similar, one might use the
upstream container image but override its config by using a volume to
bind-mount in a new config file from a local directory.

If running `docker compose` targeting a remote host, the bind-mount
looks for its source on the remote host, rather than the local, so the
sought file doesn't exist.

I'd been working around this by building a custom nginx container whose
only change was its config.

This change instead uses an inline Docker Config object to work around
this. I'd tried sourcing the config object from a local file, but this
has the same problem as the above, in that it looks for the config
source on the remote host.
@mattcen mattcen self-assigned this Apr 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant