From 7c2bab0ee4f6864b834b664adfe65084db42eb46 Mon Sep 17 00:00:00 2001 From: dermil01 Date: Wed, 6 Dec 2023 16:59:48 +0000 Subject: [PATCH] Added AMD SEV-SNP build to the github workflow --- .github/workflows/main.yml | 47 ++++++++++++++++++++++++++++++++++---- 1 file changed, 42 insertions(+), 5 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c8c5cc56b..f5970f4fd 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -216,7 +216,7 @@ jobs: policy.json server.log - nitro: + sev: runs-on: ubuntu-latest needs: [check] outputs: @@ -233,10 +233,10 @@ jobs: - name: add the GITHUB_WORKSPACE into git config run: | git config --global --add safe.directory "$GITHUB_WORKSPACE" - - name: Running Nitro test script - id: nitro-build + - name: Running AMD-SEV test script + id: sev-build run: | - make -C /work/veracruz/workspaces nitro + make -C /work/veracruz/workspaces sev - name: Check modification to Cargo.lock id: check-diff run: | @@ -251,7 +251,44 @@ jobs: if: steps.check-diff.outputs.cargo-lock != '' uses: actions/upload-artifact@v3 with: - name: nitro + name: sev + path: workspaces/**/Cargo.lock + + runs-on: ubuntu-latest + needs: [check] + outputs: + output: ${{ steps.check-diff.outputs.cargo-lock }} + container: + image: ghcr.io/veracruz-project/veracruz/ci@sha256:dd434df33153bd8915859eb0f280270d2cdf07d6100ef4332bcd18c5e8525068 + volumes: + - ${{ github.workspace }}:/work/veracruz + steps: + - name: Check out the Veracruz repository + uses: actions/checkout@v3 + with: + submodules: recursive + - name: add the GITHUB_WORKSPACE into git config + run: | + git config --global --add safe.directory "$GITHUB_WORKSPACE" + - name: Running AMD SEV-SNP test script + id: sev-build + run: | + make -C /work/veracruz/workspaces sev + - name: Check modification to Cargo.lock + id: check-diff + run: | + file_changed=$(git diff --diff-filter=ACMUXTRD --name-only -- '**Cargo.lock' | tr '\n' ' ' | xargs) + echo "cargo-lock=$file_changed" >> $GITHUB_OUTPUT + if [ -n "$file_changed" ] ; then + echo "::warning::Cargo.lock files modified"; + echo "::warning::Cargo.lock change list: ${{ steps.check-diff.outputs.cargo-lock }}"; + fi + - name: Upload Cargo.lock files + id: upload-changed-cargo-lock + if: steps.check-diff.outputs.cargo-lock != '' + uses: actions/upload-artifact@v3 + with: + name: sev path: workspaces/**/Cargo.lock # tests that the docs/CLI_QUICKSTART.md is still up to date