Skip to content

Build Rust Dist Container #16

Build Rust Dist Container

Build Rust Dist Container #16

name: Build Rust Dist Container
permissions:
contents: read
on:
workflow_dispatch:
branches:
- dev-18
paths:
- .github/workflows/build-rust-dist-docker.yml
- 'docker/**'
jobs:
prepare-rust-dist:
if: github.repository_owner == 'seahorn'
runs-on: ubuntu-22.04
permissions:
packages: write
steps:
- name: Write Variables
id: vars
run: |
tag=`date +%s`
container_name="ghcr.io/$GITHUB_REPOSITORY_OWNER/seaurchin-llvm/buildpack-deps-seaurchin"
echo "container-name=buildpack-deps-seaurchin" >> $GITHUB_OUTPUT
echo "container-name-tag=$container_name:latest" >> $GITHUB_OUTPUT
- name: Checkout seaurchin
uses: actions/checkout@v4
- name: Download seaurchin-llvm
uses: dawidd6/action-download-artifact@v7
with:
repo: seahorn/seaurchin-llvm
workflow: build-seaurchin-llvm-assert-bin.yml
branch: dev-18
github_token: ${{secrets.GITHUB_TOKEN}}
path: seaurchin-llvm
- name: Display structure of downloaded seaurchin-llvm artefact
run: ls -laH
build-rust-dist-container:
needs: prepare-rust-dist
runs-on: ubuntu-22.04
permissions:
packages: write
if: github.repository_owner == 'seahorn'
steps:
- name: Build/test rust
run: |
sudo chown $USER:$USER /mnt/
RUSTFLAGS_NOT_BOOTSTRAP="-Cllvm-args=-debug-only=licm -Cllvm-args=-licm-uses-ownsem" /mnt/x.py --config=config.ci.toml install
# We need to create an archive of the build directory, because it has too
# many files to upload.
- name: Package Build and Source Directories
run: |
tar -c . | zstd -T0 -c > seaurchin-project.tar.zst
tar -C /mnt/ -c install/ | zstd -T0 -c > seaurchin-dist.tar.zst
- name: Upload seaurchin Source
uses: actions/upload-artifact@26f96dfa697d77e81fd5907df203aa23a56210a8 #v4.3.0
with:
name: seaurchin-source
path: seaurchin-project.tar.zst
retention-days: 2
- name: Upload seaurchin-install Dir
uses: actions/upload-artifact@26f96dfa697d77e81fd5907df203aa23a56210a8 #v4.3.0
with:
name: seaurchin-dist
path: seaurchin-dist.tar.zst
retention-days: 2