Fix 32-bit Promtail ARM docker builds from Drone #1740
Merged
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.
Drone's non-64 bit ARM builds run on armv8l rather than the armv7l on 32-bit Raspberry Pis. When the Docker image is built, the
apt-get
commands causeldconfig
to be rerun and removes armv7l-specific shared libraries, causing Promtail to not work on these platforms.Note that this problem is only seen in Promtail because it needs to be built without static linking for scraping from the Journal to work. This issue was introduced by #1469, as Promtail was built with static linking prior to that PR.
The workaround mentioned in #1575 (symbolically linking the existing shared library to the one with the expected name) is used by this PR as a temporary solution to allow the next release to work on 32-bit ARM platforms. A more proper solution with Buildkit and a cross-compiler should be implemented in the future.
/cc @slim-bean