Skip to content
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

[nginx] docker build failing for nginx/nginx-prometheus-exporter #632

Closed
shauke opened this issue Mar 23, 2021 · 2 comments · Fixed by #633
Closed

[nginx] docker build failing for nginx/nginx-prometheus-exporter #632

shauke opened this issue Mar 23, 2021 · 2 comments · Fixed by #633
Assignees
Labels
bug Something isn't working
Milestone

Comments

@shauke
Copy link
Collaborator

shauke commented Mar 23, 2021

Actual Behavior

Running docker build -t nginx nginx currently results in an error for the nginx/nginx-prometheus-exporter step.

 > [stage-2 4/6] COPY --from=nginx/nginx-prometheus-exporter /usr/bin/exporter /nginx-prometheus-exporter:
------
failed to compute cache key: "/usr/bin/exporter" not found: not found

image

Investigation Notes
The problem occurs with the latest version (0.9.0) of https://hub.docker.com/r/nginx/nginx-prometheus-exporter/tags?page=1&ordering=last_updated that was just recently released.

With a pined version nginx/nginx-prometheus-exporter:0.8.0 this problem does not occur.

Quick Fix
Change the according line in nginx/Dockerfile from

COPY --from=nginx/nginx-prometheus-exporter /usr/bin/exporter /nginx-prometheus-exporter

to

COPY --from=nginx/nginx-prometheus-exporter:0.8.0 /usr/bin/exporter /nginx-prometheus-exporter

Environment Details

  • Docker version 20.10.5, build 55c4c88
@shauke shauke added the bug Something isn't working label Mar 23, 2021
@shauke shauke added this to the 0.29 milestone Mar 23, 2021
@shauke shauke self-assigned this Mar 23, 2021
@jometzner
Copy link
Collaborator

Using latest as tag of base image can result in such failures.

@shauke
Copy link
Collaborator Author

shauke commented Mar 23, 2021

Reason for Build Failure
The entrypoint for the nginx/nginx-prometheus-exporter was changed from ENTRYPOINT [ "/usr/bin/exporter" ] to ENTRYPOINT [ "/usr/bin/nginx-prometheus-exporter" ] so our /nginx/Dockerfile needs to be adapted as well to build again.
https://github.com/nginxinc/nginx-prometheus-exporter/pull/164/files#diff-5aecd73bbcb9b7410938673269f0d4e676dd18509277b0ff2f2787c9d3e22604R17

0.8.0
image

0.9.0
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants