freebsd #353
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: freebsd | |
on: | |
schedule: | |
- cron: '0 1 * * *' | |
workflow_dispatch: | |
jobs: | |
freebsd: | |
# Run for tarantool/tarantool repository only. | |
if: github.repository == 'tarantool/tarantool' | |
runs-on: freebsd-${{ matrix.freebsd-version }}-mcs | |
timeout-minutes: 60 | |
strategy: | |
fail-fast: false | |
matrix: | |
freebsd-version: [ 13, 14 ] | |
tarantool-branch: | |
- 'master' | |
- 'release/3.0' | |
- 'release/2.11' | |
- 'release/2.10' | |
steps: | |
- name: Prepare checkout | |
uses: tarantool/actions/prepare-checkout@master | |
- name: Sources checkout | |
uses: actions/checkout@v3.1.0 | |
with: | |
ref: ${{ matrix.tarantool-branch }} | |
fetch-depth: 0 | |
submodules: recursive | |
- uses: ./.github/actions/environment | |
- name: Install deps | |
uses: ./.github/actions/install-deps-freebsd | |
- name: Run testing | |
run: gmake -f .test.mk test-freebsd-release | |
- name: Send VK Teams message on failure | |
if: failure() | |
uses: ./.github/actions/report-job-status | |
with: | |
bot-token: ${{ secrets.VKTEAMS_BOT_TOKEN }} | |
# Specify the job name manually to avoid the issue with evaluating | |
# `join(matrix.*, ', ')` in ./.github/actions/report-job-status. | |
job-name: ${{ format( | |
'freebsd ({0}, {1})', | |
matrix.freebsd-version, | |
matrix.tarantool-branch) }} | |
- name: Calculate short name for Tarantool branch | |
if: failure() | |
run: > | |
echo "SHORT_BRANCH_NAME=$(basename ${{ matrix.tarantool-branch }})" >> | |
$GITHUB_ENV | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: ${{ format( | |
'freebsd-{0}-{1}', | |
matrix.freebsd-version, | |
env.SHORT_BRANCH_NAME) }} | |
retention-days: 21 | |
path: ${{ env.VARDIR }}/artifacts | |
- name: Upload artifacts to S3 | |
uses: ./.github/actions/s3-upload-artifact | |
if: ( success() || failure() ) && ( github.ref == 'refs/heads/master' || | |
startsWith(github.ref, 'refs/heads/release/') || | |
startsWith(github.ref, 'refs/tags/') ) | |
with: | |
# Unfortunately, `${{ github.job }} (${{ join(matrix.*, ', ') }})` is | |
# evaluated to `freebsd (Object)` and that's why the job name is made | |
# manually. Looks like the ChristopherHX/github-act-runner agent has | |
# a bug somewhere. | |
job-name: ${{ format( | |
'freebsd ({0}, {1})', | |
matrix.freebsd-version, | |
matrix.tarantool-branch) }} | |
access-key-id: ${{ secrets.MULTIVAC_S3_ACCESS_KEY_ID }} | |
secret-access-key: ${{ secrets.MULTIVAC_S3_SECRET_ACCESS_KEY }} | |
source: ${{ env.VARDIR }}/artifacts |