Repository navigation
1.97.1: the Docker image starts Keepalived again on a volume from an older image - #7
Merged
Merged
Conversation
…older image
Debian 13 builds Keepalived reproducibly, which moves its build-options
string out of the binary into /etc/keepalived/keepalived.config-opts, and
Keepalived refuses to start without that file ("Unable to read build config
options file"). /etc/keepalived is a volume, and Docker only seeds a volume
from the image when it is created empty, so every node upgraded from 1.96.0
kept a volume without the file and lost its VIP.
The image now keeps a copy next to the binary, a location Keepalived also
accepts, and the entrypoint refreshes /etc/keepalived/keepalived.config-opts
from it on every start, so the file is there for the bare `keepalived -t`
the app runs and always matches the binary in the image.
Closes #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #6
What broke
1.97.0 moved the image to Debian 13, whose Keepalived (2.3.3) is built reproducibly. That build moves the build-options string out of the binary into
/etc/keepalived/keepalived.config-opts, and Keepalived exits withUnable to read build config options filewhen it is missing. The file is informational only; Keepalived does not check its contents./etc/keepalivedis a volume. Docker seeds a named volume from the image only when the volume is created empty, so a volume populated by 1.96.0 hides the image's copy. Fresh installs, host installs and the Proxmox container are unaffected; every Docker upgrade from an older image is.The fix
Dockerfile: keep an image-only copy at/usr/sbin/keepalived.config-opts, a fallback location Keepalived also reads when launched by full path.docker/entrypoint.sh: copy it into/etc/keepalived/on every start. This is needed because the app validates configs with a barekeepalived -tfrom its own directory, where the fallback does not apply (verified). Refreshing on every start also keeps the file matching the binary across future Keepalived bumps.Verified
Built the image locally and ran it against a directory holding only a
keepalived.conf, the shape of an upgraded volume: the entrypoint adds the file, and bothkeepalived -tand/usr/sbin/keepalived -tpass. Against an empty directory the file is created too. Before the change the same directory fails with the reported message.