remove dup line of code #1086
Workflow file for this run
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
name: Build | |
on: | |
push: | |
branches: | |
- '*' | |
pull_request: | |
branches: | |
- '*' | |
env: | |
PACKAGE_NAME: aws-iot-device-client | |
ECR_BASE_REPO: aws-iot-device-client/aws-iot-device-client-base-images | |
jobs: | |
build-ubuntu: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE | |
- name: Archive ubuntu Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.ubuntu.x64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.ubuntu.x64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-amazonlinux: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-amazonlinux-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE | |
- name: Archive amazonlinux Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.amazonlinux.x64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.amazonlinux.x64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-rhel-ubi8: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubi8-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE | |
- name: Archive rhel-ubi8 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.rhel.x64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.rhel.x64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
gpp-compat: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
strategy: | |
matrix: | |
version: [ 5, 6, 7, 8, 11 ] | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compiler=g++-${{ matrix.version }} | |
clangpp-compat: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
strategy: | |
matrix: | |
version: [ 5.0, 6.0, 7, 8, 9, 11 ] | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compiler=clang-${{ matrix.version }} | |
build-armhf32: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=armhf_cross_mode | |
- name: Archive armhf32 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.armhf.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.armhf.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-mips32: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=mips_cross_mode | |
- name: Archive mips32 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.mips.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.mips.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-aarch64: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=aarch64_cross_mode | |
- name: Archive aarch64 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.aarch64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.aarch64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-ppc64: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=ppc64_cross_mode | |
- name: Archive aarch64 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.ppc64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.ppc64.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-ppc64le: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=ppc64le_cross_mode | |
- name: Archive aarch64 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.ppc64le.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
- name: Archive setup files | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "DC.linux.ppc64le.${{ env.PACKAGE_NAME }}.static" | |
path: | | |
./setup/ | |
build-st-ubuntu-18-x_86_64: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=st_component_mode | |
- name: Archive ST Ubuntu aarch64 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "ST.ubuntu.x64.${{ env.PACKAGE_NAME }}" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
build-st-ubuntu-18-aarch64: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=st_aarch64_cross_mode | |
- name: Archive ST Ubuntu aarch64 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "ST.ubuntu.aarch64.${{ env.PACKAGE_NAME }}" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} | |
build-st-ubuntu-18-armv7: | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push') || ((github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name != github.repository)) | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.ECR_USER_AWS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.ECR_USER_AWS_KEY_SECRET }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
run: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Build ${{ env.PACKAGE_NAME }} | |
run: | | |
export DOCKER_IMAGE=public.ecr.aws/${ECR_BASE_REPO}:x86_64-ubuntu-latest | |
docker pull $DOCKER_IMAGE | |
docker run --mount type=bind,source=$(pwd),target=/root/${{ env.PACKAGE_NAME }} --env GITHUB_REF $DOCKER_IMAGE --compile-mode=st_armhf_cross_mode | |
- name: Archive st armhf32 Build Artifact | |
uses: actions/upload-artifact@v2 | |
# Run for main branch only | |
if: github.ref == 'refs/heads/main' | |
with: | |
name: "ST.linux.armhf.${{ env.PACKAGE_NAME }}" | |
path: | | |
./build/${{ env.PACKAGE_NAME }} |