Skip to content

Commit

Permalink
[gha] fall back to default image
Browse files Browse the repository at this point in the history
Use base image for CI to work around GHA image pulling issue.
These additional changes are needed to make that work:
- disable mount point
- manual install golang due to old debian mirror
- increase job timeout for the added time in toolchain prep
- upgrade to ubuntu-20.04
- bump serdes-reflection and serdes-generate

Closes: #9536
  • Loading branch information
sausagee authored and bors-libra committed Oct 28, 2021
1 parent b208105 commit 90a11f6
Show file tree
Hide file tree
Showing 7 changed files with 114 additions and 110 deletions.
10 changes: 10 additions & 0 deletions .github/actions/build-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,16 @@ runs:
mv /Users/runner/work/diem/diem /opt/git/diem
ln -s /opt/git/diem /Users/runner/work/diem/diem
cd /opt/git/diem
else
# FIXME delete after GHA image pull outage; this temporarily sets up
# the work dir that the rest of the workflow depends on.
if [[ ! -d /opt/git/diem ]]; then
sudo mkdir -p /opt/git && sudo mkdir -p /opt/cargo
sudo chmod -R g+rw /opt/
mv /home/runner/work/diem/diem /opt/git/diem
ln -s /opt/git/diem /home/runner/work/diem/diem
cd /opt/git/diem
fi
fi
# prepare move lang prover tooling.
Expand Down
3 changes: 2 additions & 1 deletion .github/actions/build-teardown/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ runs:
using: "composite"
steps:
- name: Check for changed and untracked files
run: ./scripts/changed-files.sh
run: |
./scripts/changed-files.sh
shell: bash
- name: Clean target directory
run: |
Expand Down
36 changes: 18 additions & 18 deletions .github/workflows/ci-post-land.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ env:

jobs:
prepare:
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
outputs:
changes-target-branch: ${{ steps.changes.outputs.changes-target-branch }}
changes-base-git-rev: ${{ steps.changes.outputs.changes-base-git-rev }}
Expand Down Expand Up @@ -59,11 +59,11 @@ jobs:
if: ${{ needs.prepare.outputs.rust-changes == 'true' }}
environment:
name: Sccache
runs-on: ubuntu-latest-xl
container:
image: diem/build_environment:${{ needs.prepare.outputs.changes-target-branch }}
volumes:
- "${{github.workspace}}:/opt/git/diem"
runs-on: ubuntu-20.04-xl
#container:
#image: diem/build_environment:${{ needs.prepare.outputs.changes-target-branch }}
#volumes:
# - "${{github.workspace}}:/opt/git/diem"
steps:
- uses: actions/[email protected]
with:
Expand All @@ -90,14 +90,14 @@ jobs:
# update this report to differentiate branches.
unit-test-allure-report:
name: Unit Test Reports
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
if: ${{ github.ref == 'refs/heads/main' }}
environment:
name: Sccache
container:
image: diem/build_environment:main
volumes:
- "${{github.workspace}}:/opt/git/diem"
#container:
#image: diem/build_environment:main
#volumes:
# - "${{github.workspace}}:/opt/git/diem"
steps:
- uses: actions/[email protected]
with:
Expand Down Expand Up @@ -125,7 +125,7 @@ jobs:

build_ci_base_docker_image:
needs: prepare
runs-on: ubuntu-latest-xl
runs-on: ubuntu-20.04-xl
if: ${{ needs.prepare.outputs.base-image-changes == 'true' || github.event_name == 'create' }}
continue-on-error: false
env:
Expand Down Expand Up @@ -238,7 +238,7 @@ jobs:
build-release-images:
needs: prepare
runs-on: ubuntu-latest-xl
runs-on: ubuntu-20.04-xl
continue-on-error: false
env:
TAG: github-1
Expand Down Expand Up @@ -330,11 +330,11 @@ jobs:
rustdoc:
needs: prepare
if: ${{ needs.prepare.outputs.changes-target-branch == 'main' && needs.prepare.outputs.rust-changes == 'true'}}
runs-on: ubuntu-latest
container:
image: diem/build_environment:${{ needs.prepare.outputs.changes-target-branch }}
volumes:
- "${{github.workspace}}:/opt/git/diem"
runs-on: ubuntu-20.04
#container:
#image: diem/build_environment:${{ needs.prepare.outputs.changes-target-branch }}
#volumes:
# - "${{github.workspace}}:/opt/git/diem"
steps:
- name: Checkout repository
uses: actions/[email protected]
Expand Down
Loading

0 comments on commit 90a11f6

Please sign in to comment.