From ec1eb227ba75a80f17ba11a9a4b5d854f81d0c01 Mon Sep 17 00:00:00 2001 From: cskh Date: Tue, 24 May 2022 00:07:38 -0400 Subject: [PATCH] Verify binary artifacts --- .github/workflows/build.yml | 41 ++++++++++++++++++++++++++++++++----- 1 file changed, 36 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b0695fec04..1b73c2b9b6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,6 +6,7 @@ on: branches: # Push events on the main branch - main + - CTIA-8-verify-builds-v2 env: PKG_NAME: consul @@ -69,11 +70,11 @@ jobs: - {go: "1.18.1", goos: "linux", goarch: "amd64"} - {go: "1.18.1", goos: "linux", goarch: "arm"} - {go: "1.18.1", goos: "linux", goarch: "arm64"} - - {go: "1.18.1", goos: "freebsd", goarch: "386"} - - {go: "1.18.1", goos: "freebsd", goarch: "amd64"} - - {go: "1.18.1", goos: "windows", goarch: "386"} - - {go: "1.18.1", goos: "windows", goarch: "amd64"} - - {go: "1.18.1", goos: "solaris", goarch: "amd64"} + # - {go: "1.18.1", goos: "freebsd", goarch: "386"} + # - {go: "1.18.1", goos: "freebsd", goarch: "amd64"} + # - {go: "1.18.1", goos: "windows", goarch: "386"} + # - {go: "1.18.1", goos: "windows", goarch: "amd64"} + # - {go: "1.18.1", goos: "solaris", goarch: "amd64"} fail-fast: true name: Go ${{ matrix.go }} ${{ matrix.goos }} ${{ matrix.goarch }} build @@ -232,6 +233,25 @@ jobs: steps: - uses: actions/checkout@v2 + - name: Download binary + uses: actions/download-artifact@v2 + with: + name: ${{ env.PKG_NAME }}_${{env.version}}_linux_${{ matrix.arch }}.zip + - name: Run consul binary on amd64 + run: | + ls -lt + unzip ${{ env.PKG_NAME }}_${{env.version}}_linux_${{ matrix.arch }}.zip + ls -lt + ./consul version + if: ${{ matrix.arch == 'amd64' }} + # - name: Run consul binary on arm64 + # run: | + # ls -lt + # unzip ${{ env.PKG_NAME }}_${{env.version}}_linux_${{ matrix.arch }}.zip + # ls -lt + # ls -lt ./dist + # ./consul/consul version + # if: ${{ matrix.arch == 'arm64' }} - name: Docker Build (Action) uses: hashicorp/actions-docker-build@v1 with: @@ -244,3 +264,14 @@ jobs: dev_tags: | docker.io/hashicorppreview/${{ env.repo }}:${{ env.version }}-dev docker.io/hashicorppreview/${{ env.repo }}:${{ env.version }}-${{ github.sha }} + - name: Download binary + uses: actions/download-artifact@v2 + with: + name: ${{ env.PKG_NAME }}_${{env.version}}_linux_${{ matrix.arch }}.zip + path: consul + - name: Run consul binary on amd64 + run: consul version + if: ${{ matrix.arch == 'amd64' }} + - name: Run consul binary on arm64 + run: consul version + if: ${{ matrix.arch == 'arm64' }} \ No newline at end of file