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.
Continues: #2427
What is the purpose of the change
This PR adds additional flavors to the osmosis Docker image.
Now you can run the
osmosisd
binary from:All images have
amd64
andarm64
support.I have also changed the default docker image from
static:nonroot
tostatic
.Why all of this
Distroless container images are IMHO the best way to run a golang binary. However,
nonroot
images have created permission problems in the past. To simplify, I'm proposing to usestatic
distroless images as our default but still offer the possibility to run anonroot
Docker image via the-nonroot
suffix.Distroless images contain, by design, only the binary and no shell.
This limitation led to the proliferation of various spurious Docker images created ad-hoc to solve specific problems.
Introducing
alpine
images could help reduce the number of Docker images we have: #1679, and it can be helpful in dev/testing scenarios.Brief Changelog
gcr.io/distroless/static
osmosisd
docker images with the same binary.Testing and Verifying
I have tested the workflow from my fork: https://github.com/niccoloraspa/osmosis/actions/runs/2875632534.
Triggered the workflow by creating a fake tag
v12.12.22
that pushed the following images in theosmolabs/osmosis-test
registry.docker run osmolabs/osmosis-test:12.12.22 docker run osmolabs/osmosis-test:12.12.22-alpine docker run osmolabs/osmosis-test:12.12.22-distroless docker run osmolabs/osmosis-test:12.12.22-nonroot # Also osmolabs/osmosis-test:12, osmolabs/osmosis-test:12.12, osmolabs/osmosis-test:latest
Documentation and Release Note
Unreleased
section inCHANGELOG.md
? no