Skip to content

Commit

Permalink
Merge branch 'main' into user/ashdhin/IssueTemplateRegressionCheckbox
Browse files Browse the repository at this point in the history
  • Loading branch information
jmklix authored Nov 4, 2024
2 parents 9f4203b + 7386bcf commit fb42d94
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 42 deletions.
2 changes: 1 addition & 1 deletion .github/docker-images/manylinux1-x86/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ RUN curl -sSL https://d19elf31gohf1l.cloudfront.net/_binaries/cmake/cmake-3.13-m
###############################################################################
ADD entrypoint.sh /usr/local/bin/builder
RUN chmod a+x /usr/local/bin/builder
ENTRYPOINT ["/usr/local/bin/builder"]
ENTRYPOINT ["/usr/local/bin/builder"]
2 changes: 2 additions & 0 deletions .github/docker-images/manylinux2014-x64/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ FROM quay.io/pypa/manylinux2014_x86_64
# Basics
###############################################################################
RUN yum -y install sudo cmake3 \
# used in java release pipeline
maven \
&& yum clean all \
&& ln -s `which cmake3` /usr/bin/cmake \
&& ln -s `which ctest3` /usr/bin/ctest \
Expand Down
2 changes: 2 additions & 0 deletions .github/docker-images/manylinux2014-x86/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ FROM quay.io/pypa/manylinux2014_i686
# Basics
###############################################################################
RUN yum -y install sudo \
# used in java release pipeline
maven \
&& yum clean all

###############################################################################
Expand Down
84 changes: 43 additions & 41 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,32 +53,34 @@ jobs:
fail-fast: false
matrix:
variant:
- manylinux1-x86
- manylinux1-x64
- manylinux2014-x86
- manylinux2014-x64
- manylinux2014-aarch64
- musllinux-1-1-aarch64
- musllinux-1-1-x64
- al2012-x64
- al2-x64
- ubuntu-18-x64
- ubuntu-20-x64
- ubuntu-20-aarch64
- node-10-linux-x64
- swift-5-al2-x64
- swift-5-centos-x64
- swift-5-ubuntu-x64
- rhel8-x64
- opensuse-leap
- fedora-34-x64
- raspbian-bullseye
- alpine-3.16-x64
- alpine-3.16-x86
- alpine-3.16-arm64
- alpine-3.16-armv7
- alpine-3.16-armv6
- openwrt-x64-openjdk8
- name: manylinux1-x86
- name: manylinux1-x64
- name: manylinux2014-x86
- name: manylinux2014-x64
- name: manylinux2014-aarch64
- name: musllinux-1-1-aarch64
- name: musllinux-1-1-x64
- name: al2012-x64
- name: al2-x64
- name: ubuntu-18-x64
- name: ubuntu-20-x64
- name: ubuntu-20-aarch64
extra-build-flag: --platform=linux/aarch64
- name: ubuntu-22-x64
- name: node-10-linux-x64
- name: swift-5-al2-x64
- name: swift-5-centos-x64
- name: swift-5-ubuntu-x64
- name: rhel8-x64
- name: opensuse-leap
- name: fedora-34-x64
- name: raspbian-bullseye
- name: alpine-3.16-x64
- name: alpine-3.16-x86
- name: alpine-3.16-arm64
- name: alpine-3.16-armv7
- name: alpine-3.16-armv6
- name: openwrt-x64-openjdk8

steps:
- name: Checkout Sources
Expand All @@ -89,46 +91,46 @@ jobs:
id: tag

- name: Install entrypoint
run: cat .github/docker-images/entrypoint.sh | sed s/version=LATEST/version=${{ steps.tag.outputs.release_tag }}/ > .github/docker-images/${{ matrix.variant }}/entrypoint.sh
run: cat .github/docker-images/entrypoint.sh | sed s/version=LATEST/version=${{ steps.tag.outputs.release_tag }}/ > .github/docker-images/${{ matrix.variant.name }}/entrypoint.sh

- name: Install qemu/docker
run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes

- name: Build aws-crt-${{ matrix.variant }} image
- name: Build aws-crt-${{ matrix.variant.name }} image
uses: whoan/docker-build-with-cache-action@v8
with:
registry: ${{ secrets.AWS_ECR_REPO }}
username: ${{ secrets.AWS_ACCESS_KEY_ID }}
password: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
image_name: aws-crt-${{ matrix.variant }}
image_name: aws-crt-${{ matrix.variant.name }}
image_tag: ${{ steps.tag.outputs.release_tag }}
context: .github/docker-images/${{ matrix.variant }}
build_extra_args: --compress=true

context: .github/docker-images/${{ matrix.variant.name }}
build_extra_args: --compress=true ${{ matrix.variant.extra-build-flag }}
- name: Login to docker repos
run: |
aws ecr get-login-password --region us-east-1 | docker login ${{ secrets.AWS_ECR_REPO }} -u AWS --password-stdin
- name: Create ECR repo if necessary
run: |
if ! aws --region us-east-1 ecr describe-repositories --repository-names aws-crt-${{ matrix.variant }} > /dev/null 2>&1; then \
aws --region us-east-1 ecr create-repository --repository-name aws-crt-${{ matrix.variant }}; \
if ! aws --region us-east-1 ecr describe-repositories --repository-names aws-crt-${{ matrix.variant.name }} > /dev/null 2>&1; then \
aws --region us-east-1 ecr create-repository --repository-name aws-crt-${{ matrix.variant.name }}; \
fi
- name: Tag/push release images as latest
run: |
export IMAGE_TAG=${{ steps.tag.outputs.release_tag }}
docker tag ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant }}:$IMAGE_TAG ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant }}:latest
docker push ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant }}:$IMAGE_TAG
docker push ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant }}:latest
docker tag ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant.name }}:$IMAGE_TAG ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant.name }}:latest
docker push ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant.name }}:$IMAGE_TAG
docker push ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant.name }}:latest
- name: Export aws-crt-${{ matrix.variant }} image to S3/releases
- name: Export aws-crt-${{ matrix.variant.name }} image to S3/releases
run: |
export IMAGE_TAG=${{ steps.tag.outputs.release_tag }}
docker save ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant }}:$IMAGE_TAG \
docker save ${{ secrets.AWS_ECR_REPO }}/aws-crt-${{ matrix.variant.name }}:$IMAGE_TAG \
| gzip \
| aws s3 cp - s3://${{env.AWS_S3_BUCKET}}/releases/$IMAGE_TAG/aws-crt-${{ matrix.variant }}.tar.gz
aws s3 cp s3://${{env.AWS_S3_BUCKET}}/releases/$IMAGE_TAG/aws-crt-${{ matrix.variant }}.tar.gz s3://${{env.AWS_S3_BUCKET}}/LATEST/aws-crt-${{ matrix.variant }}.tar.gz
| aws s3 cp - s3://${{env.AWS_S3_BUCKET}}/releases/$IMAGE_TAG/aws-crt-${{ matrix.variant.name }}.tar.gz
aws s3 cp s3://${{env.AWS_S3_BUCKET}}/releases/$IMAGE_TAG/aws-crt-${{ matrix.variant.name }}.tar.gz s3://${{env.AWS_S3_BUCKET}}/LATEST/aws-crt-${{ matrix.variant.name }}.tar.gz
upload-ci-script:
name: Upload container ci script
Expand Down

0 comments on commit fb42d94

Please sign in to comment.