-
Notifications
You must be signed in to change notification settings - Fork 35
Conversation
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_PASSWORD }} |
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.
these two you would have to add to https://github.com/stevearc/pypicloud-docker/settings/secrets/actions
which is safe as only you can trigger this workflow
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.
One small Q
LGTM, thanks for the PR |
build: | ||
runs-on: ubuntu-latest | ||
env: | ||
BUILDX_PLATFORMS: linux/amd64,linux/arm64,linux/arm/v7 |
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.
this env var can be customised also in local env: all available archs will be printed by QEMU setup
on: | ||
release: | ||
types: [released, prereleased] | ||
workflow_dispatch: # allow manually running from the Actions tab |
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.
@stevearc fwiw you as maintainer can trigger the flow manually for any branch from the Actions tab.
did the acript fail locally or in CI?
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.
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.
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.
correction: just saw psycopg2-binary
, with the 2. none of those have arm wheels available ;( solutions would be to add support for v3 (maybe no breaking changes that hit us), or prepare the dockerfile so the v2 install from source will succeed
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.
could try adding the apt package libpq-dev
and see if source install in the arm image starts working
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.
an alternative: https://github.com/docker/setup-buildx-action/blob/master/README.md#max-parallelism
although no space left can probably be avoided 'properly' as this should not be a heavy build
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.
Looks like most of the builds finish pretty quickly; it's just alpine linux on arm64 that's heavy. Kind of expected, since you can't use most binary packages and instead have to compile almost everything yourself https://github.com/stevearc/pypicloud-docker/runs/8039880052
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.
ah yes, alpine... always a pain especially for python projects 😅 we once tried it at work cuz of 'smaller images' fetish, ended up quickly reverting to debian slim
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.
Finally managed to build and release 1.3.9 images! I ended up disabling the arm build on alpine.
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.
whoop whoop!! 🎉 thanks so much for your perseverance 🙏
Will additionally push armv8 (arm64) and armv7 (32bit) docker images to dockerhub when a github release is (pre)released, or manually from the Actions tab after pushing a tag (but not releasing it as github release).
The script can still be used locally with a recent docker version that comes with buildx, also without QEMU emulator installed, to build and push the AMD image only (the default if
BUILDX_PLATFORMS
env var is not set)pushing multi-arch manifest separately from the build command like it was is iffy (
regctl
needed), so just running build command again but with--push
, which should be minimal overhead.