forked from pypa/manylinux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use upstream images directly, instead of rebasing (#1)
- Loading branch information
Showing
61 changed files
with
50 additions
and
15,824 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
name: Create multi-arch image | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
tags: | ||
- v* | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
permissions: | ||
packages: write | ||
|
||
jobs: | ||
image: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Create multi-arch image | ||
run: | | ||
echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin | ||
for arch in x86_64 aarch64 ppc64le; do | ||
docker pull quay.io/pypa/manylinux2014_$arch | ||
docker tag quay.io/pypa/manylinux2014_$arch ghcr.io/spack/manylinux2014:latest-$arch | ||
docker push ghcr.io/spack/manylinux2014:latest-$arch | ||
done | ||
# use tag pr-<number>, latest, or v* tag for multi-arch image tag. | ||
if [ -n "$GITHUB_REF" ]; then | ||
if [ "$GITHUB_REF" = "refs/pull/${{ github.event.pull_request.number }}/merge" ]; then | ||
tag_name=pr-${{ github.event.pull_request.number }} | ||
elif [ "$GITHUB_REF" = "refs/heads/main" ]; then | ||
tag_name=latest | ||
else | ||
tag_name=${GITHUB_REF/refs\/tags\//} | ||
fi | ||
else | ||
tag_name=latest | ||
fi | ||
docker manifest create ghcr.io/spack/manylinux2014:$tag_name \ | ||
ghcr.io/spack/manylinux2014:latest-x86_64 \ | ||
ghcr.io/spack/manylinux2014:latest-aarch64 \ | ||
ghcr.io/spack/manylinux2014:latest-ppc64le | ||
docker manifest push ghcr.io/spack/manylinux2014:$tag_name |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.