diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8264dee..878820b 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,6 +12,8 @@ on: jobs: test: runs-on: ubuntu-22.04 + permissions: + packages: write steps: - name: Checkout code uses: actions/checkout@v2 @@ -82,3 +84,9 @@ jobs: cat test-suite.log cat tests/*.log cat tests/unit-tests/*.log + + - name: Push packages to buildcache and update index + if: ${{ !cancelled() }} + run: | + spack -e tests mirror set --push --oci-username ${{ github.actor }} --oci-password "${{ secrets.GITHUB_TOKEN }}" mochi-buildcache + spack -e tests buildcache push --base-image ubuntu:22.04 --unsigned --update-index mochi-buildcache diff --git a/tests/spack.yaml b/tests/spack.yaml index be9b2d9..eee8b4c 100644 --- a/tests/spack.yaml +++ b/tests/spack.yaml @@ -12,7 +12,7 @@ spack: - libtool - pkg-config - argobots - - mercury~boostsys ^libfabric fabrics=tcp,rxm + - mercury~checksum~boostsys ^libfabric fabrics=tcp,rxm concretizer: unify: true reuse: false @@ -26,3 +26,5 @@ spack: test_cache: ~/.spack-ci/test_cache install_tree: root: ~/.spack-ci/install + mirrors: + mochi-buildcache: oci://ghcr.io/mochi-hpc/mochi-spack-buildcache