From 9fb1f8f9026c000c5b55fe733aeefded81d58d7a Mon Sep 17 00:00:00 2001 From: Jamil Bou Kheir Date: Thu, 22 Jul 2021 21:45:43 -0700 Subject: [PATCH] Upload artifacts properly --- .ci/build_packages.sh | 4 ++-- .github/workflows/ci.yml | 42 ++++++++++++++-------------------------- 2 files changed, 17 insertions(+), 29 deletions(-) diff --git a/.ci/build_packages.sh b/.ci/build_packages.sh index 54bc2747d..1ee32b95c 100755 --- a/.ci/build_packages.sh +++ b/.ci/build_packages.sh @@ -39,7 +39,7 @@ case $format in deb) pkg_dir="${MATRIX_IMAGE/:/_}_amd64" pkg_file="${pkg_dir}.deb" - image="ghcr.io/firezone/${pkg_dir}:latest" + image="ghcr.io/firezone/package-${MATRIX_IMAGE/:/_}:${GITHUB_SHA}" docker buildx build \ --pull \ @@ -61,7 +61,7 @@ case $format in version=0.2.0-1 pkg_dir="firezone-${version}.x86_64" pkg_file="${pkg_dir}.rpm" - image="ghcr.io/firezone/${MATRIX_IMAGE/:/_}_amd64:latest" + image="ghcr.io/firezone/package-${MATRIX_IMAGE/:/_}:${GITHUB_SHA}" docker buildx build \ --pull \ diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 379d2777f..863aa4848 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,14 +46,14 @@ jobs: sudo -E bash -c '.ci/install_runtimes.sh' - name: Install Dependencies run: .ci/install_dependencies.sh - # - uses: actions/cache@v2 - # with: - # path: | - # deps - # _build - # key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }} - # restore-keys: | - # ${{ runner.os }}-mix- + - uses: actions/cache@v2 + with: + path: | + deps + _build + key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }} + restore-keys: | + ${{ runner.os }}-mix- - name: Setup Database run: | mix ecto.create @@ -100,33 +100,21 @@ jobs: - uses: actions/upload-artifact@v2 with: - name: firezone_${{ matrix.os }}_${{ matrix.platform }} - path: _build/firezone_${{ matrix.os }}_*.* + name: firezone + path: | + _build/firezone*.rpm + _build/firezone*.deb functional-test: needs: build - runs-on: ubuntu-20.04 - strategy: - matrix: - os: - # - amazonlinux_2 - # - centos_7 - # - centos_8 - # - debian_10 - # - fedora_33 - # - fedora_34 - # - fedora_35 - # - ubuntu_18.04 - - ubuntu_20.04 - env: - MATRIX_OS: ${{ matrix.os }} - DEBIAN_FRONTEND: noninteractive + runs-on: macos-latest # macos supports Virtualbox / Vagrant steps: - uses: actions/checkout@v2 - uses: actions/download-artifact@v2 with: - name: firezone_${{ matrix.os }}_amd64.deb + name: firezone path: ./ + - run: ls -al - name: Test Install package run: .ci/functional_test.sh