-
Notifications
You must be signed in to change notification settings - Fork 512
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
[BUGFIX] Update nginx deployment to mount nginx.conf as file #4954
Conversation
hi, thanks for opening this PR. Can you provide some instructions to reproduce this bug? When I install the chart with the default options I see the configmap is mounted as a file in |
Hi @dimitarvdimitrov, sorry, I thought this was still in draft mode. At the moment, the nginx-config configmap is mounted as folder, masking everything else that is located in With the current setup, this fails with the following logs: With the proposed change, the Unfortunately, I did not find any parameters to nginx which would allow an alternative module path (e.g. in Alternative fixes would include larger changes, such as moving the config volume & mount to the Please let me know what you think. |
I understand, thank you for explaining. In that case I think this change makes sense. I ran the change locally and it appears that there are also other files and directories we were overwriting. All of the below apart from
Can I also ask you to carry out the change on the mimir/operations/helm/charts/mimir-distributed/templates/gateway/gateway-dep.yaml Lines 90 to 91 in 18f1dd0
Also, to get the CI passing, you can run |
Closing this PR due to inactivity, but please feel free to re-open it anytime if you plan to get back to this. Thanks! |
Reopen with updated fixes |
@blut the Reopen button is grayed out even for maintainers (tooltip says "The main branch was force-pushed or recreated"). Is it the same for you? If neither of us can reopen the PR, maybe you should just recreate it. |
Thank you, I will recreate the PR |
Moved to #7150 |
What this PR does
At the moment, the nginx-config configmap is mounted as folder, masking everything else that is located in
/etc/nginx
.I'm trying to load a module in the
nginx.conf
withload_module modules/ngx_http_js_module.so;
.With the current setup, this fails with the following logs:
/docker-entrypoint.sh: No files found in /docker-entrypoint.d/, skipping configuration 2023/05/09 11:46:27 [emerg] 1#1: dlopen() "/etc/nginx/modules/ngx_http_js_module.so" failed (/etc/nginx/modules/ngx_http_js_module.so: cannot open shared object file: No such file or directory) in /etc/nginx/nginx.conf:1 nginx: [emerg] dlopen() "/etc/nginx/modules/ngx_http_js_module.so" failed (/etc/nginx/modules/ngx_http_js_module.so: cannot open shared object file: No such file or directory) in /etc/nginx/nginx.conf:1
With the proposed change, the
nginx.conf
file is still mounted to/etc/nginx/nginx.conf
, however loading modules is now possible.Unfortunately, I did not find any parameters to nginx which would allow an alternative module path (e.g. in
/usr/lib/nginx/modules
) and since the directory is mounted read-only, it is not possible copying the module through an entrypoint script.Alternative fixes would include larger changes, such as moving the config volume & mount to the
values.yaml
Which issue(s) this PR fixes or relates to
Fixes #
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]