build_unstable #16
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build_unstable | |
on: | |
schedule: | |
- cron: '0 0 * * *' # every midnight | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build_amd64: | |
runs-on: ubuntu-20.04 | |
env: | |
PUSH_TOKEN: ${{ secrets.PUSH_TOKEN }} | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: 'recursive' | |
- name: Checkout CI scripts | |
uses: actions/checkout@v3 | |
with: | |
repository: ctu-mrs/ci_scripts | |
ref: master | |
path: .ci_scripts | |
token: ${{ secrets.PUSH_TOKEN }} | |
- name: Build | |
run: | | |
mkdir -p /tmp/artifacts | |
.ci/build.sh unstable | |
- name: Deploy | |
run: .ci_scripts/package_build/push_to_ppa.sh unstable /tmp/artifacts | |
build_arm64: | |
runs-on: ubuntu-20.04 | |
name: Build on ${{ matrix.arch }} | |
strategy: | |
matrix: | |
include: | |
- arch: aarch64 | |
distro: ubuntu20.04 | |
env: | |
PUSH_TOKEN: ${{ secrets.PUSH_TOKEN }} | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: 'recursive' | |
- name: Checkout CI scripts | |
uses: actions/checkout@v3 | |
with: | |
repository: ctu-mrs/ci_scripts | |
ref: master | |
path: .ci_scripts | |
token: ${{ secrets.PUSH_TOKEN }} | |
- uses: uraimo/run-on-arch-action@v2 | |
name: Build artifact | |
id: build | |
with: | |
arch: ${{ matrix.arch }} | |
distro: ${{ matrix.distro }} | |
githubToken: ${{ github.token }} | |
install: | | |
apt-get update -y | |
apt-get install -y sudo git curl | |
echo 'debconf debconf/frontend select Noninteractive' | sudo debconf-set-selections | |
# Create an artifacts directory | |
setup: | | |
mkdir -p "/tmp/artifacts" | |
mkdir -p "/tmp/repository" | |
# Mount the artifacts directory as /artifacts in the container | |
dockerRunArgs: | | |
--volume "$PWD:/tmp/repository" | |
--volume "/tmp/artifacts:/tmp/artifacts" | |
# The shell to run commands with in the container | |
shell: /bin/sh | |
# Produce a binary artifact and place it in the mounted volume | |
run: | | |
/tmp/repository/.ci/build.sh unstable | |
- name: Deploy | |
run: .ci_scripts/package_build/push_to_ppa.sh unstable /tmp/artifacts |