Repository navigation
fix: add apt-get install retry logic to handle stale package archives #682
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 |
|---|---|---|
| @@ -1,14 +1,18 @@ | ||
| FROM ubuntu/squid:latest | ||
|
|
||
| # Install additional tools for debugging, healthcheck, and SSL Bump | ||
| # Retry logic handles transient 404s when Ubuntu archive supersedes package versions mid-build | ||
| RUN apt-get update && \ | ||
| apt-get install -y --no-install-recommends \ | ||
| ( apt-get install -y --no-install-recommends \ | ||
| curl \ | ||
| dnsutils \ | ||
| net-tools \ | ||
| netcat-openbsd \ | ||
| openssl \ | ||
| squid-openssl && \ | ||
| squid-openssl || \ | ||
| (rm -rf /var/lib/apt/lists/* && apt-get update && \ | ||
| apt-get install -y --no-install-recommends \ | ||
| curl dnsutils net-tools netcat-openbsd openssl squid-openssl) ) && \ | ||
|
||
| rm -rf /var/lib/apt/lists/* | ||
|
|
||
| # Create log directory and SSL database directory | ||
|
|
||
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.
The retry path repeats the full package list, which can drift from the primary install list above if it’s edited later. To avoid future inconsistencies, define the packages once (e.g., in a shell variable) and use that in both the initial install and the retry.
This issue also appears on line 80 of the same file.