Files
Echoion/.gitea/workflows/ci.yml
T
faumaray f78004e822
Container CI / release-build (push) Successful in 16m22s
Nightly release / publish-nightly (push) Successful in 16m6s
Release: use independent component repositories
2026-07-28 21:24:30 +03:00

111 lines
4.4 KiB
YAML

name: Container CI
on:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
jobs:
release-build:
runs-on: ubuntu-24.04
steps:
- name: Verify the Docker-capable Gitea runner
shell: bash
run: |
set -euo pipefail
test "$(uname -s)" = Linux
command -v docker
docker version
docker info
- name: Check out source
uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
with:
fetch-depth: 0
ssh-key: ${{ secrets.RELEASE_CHECKOUT_SSH_KEY }}
ssh-user: gitea
ssh-known-hosts: >-
git.faumaray.ru ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCzZEz9JLrzk6oLiloSbueAN28vYL58Y/dTHBgRuBMMib9IJ1aDJShhr3kwC9sfOT0AzK0uwcMAqCAIkwJwttde8dIg0Mee0cmB/1JkoqFF4X3MUGD1r3nk8SSZNhIiPqo16hDF9Hf3FkovztIlBVntkyP9Iy9hYfP818Tiq3yRXROGdHjR7IfY4jR2QGfGrd/RtvPGExVqusxidy141240A8aRAwMFUqFdEvmXWjizrtCUqcrL/k1GEh0yJzbCdNOVUI6OuWd8tPluSBvmmeoNpKnCSl4Mkg36HObbOyrsme0asZqjcj0od65WYWApMPN0pUqhNu2CP83Nfor2VFwkdPRwe7cAZ0OD/8wyT6Hz5q1wWgf82y4tYDoDRYsd8JU86eebkJ07T5nCrEeC4Sj+qT4S5xv/kECAhxyP4QGnunORnY2fYsdNGzpPvbMN7gHe9UcIcQdOIgV3wrR1qpMVNcd8AEC2A3TRv/jzMCHSjmGGpgiy1Db2CZAjp5+PcjNmjvoPNN0NiA9X4rIVSeTfflWnDRmeNRJeZa73StjpU17EcAf97COUQPGWJQDgpJqINSpYU50fuaLBfzKnIRuiHjKQmyKe/zgRSmulnYFYM3AJfn8Ykg2VvkUQGvCt1+fqYiUa1iVFuwPP3ZigYF1mOZRpPnos5kaNmlB01q2sZw==
persist-credentials: false
- name: Read locked component repositories
id: components
shell: bash
run: |
set -euo pipefail
python3 - "$GITHUB_OUTPUT" <<'PY'
import json
import pathlib
import sys
lock = json.loads(pathlib.Path("components.lock.json").read_text())
with pathlib.Path(sys.argv[1]).open("a") as output:
for component, key in (
("EchoionApi", "api"),
("EchoionCore", "core"),
("EchoionDesktop", "desktop"),
):
entry = lock["components"][component]
print(f"{key}_repository={entry['repository']}", file=output)
print(f"{key}_revision={entry['revision']}", file=output)
PY
- name: Check out EchoionApi
uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
with:
repository: ${{ steps.components.outputs.api_repository }}
ref: ${{ steps.components.outputs.api_revision }}
path: EchoionApi
fetch-depth: 1
token: ${{ secrets.RELEASE_BOT_TOKEN }}
persist-credentials: false
- name: Check out EchoionCore
uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
with:
repository: ${{ steps.components.outputs.core_repository }}
ref: ${{ steps.components.outputs.core_revision }}
path: EchoionCore
fetch-depth: 1
token: ${{ secrets.RELEASE_BOT_TOKEN }}
persist-credentials: false
- name: Check out EchoionDesktop
uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
with:
repository: ${{ steps.components.outputs.desktop_repository }}
ref: ${{ steps.components.outputs.desktop_revision }}
path: EchoionDesktop
fetch-depth: 1
token: ${{ secrets.RELEASE_BOT_TOKEN }}
persist-credentials: false
- name: Build, test, and package without starting Echoion
env:
CI_VERSION: 0.0.0-ci.${{ gitea.run_number }}.${{ gitea.run_attempt }}
run: |
set -eu
scripts/release.sh --version "$CI_VERSION"
- name: Test release control-plane scripts
shell: bash
run: |
set -eu
bash scripts/tests/test-gitea-tag-verification.sh
. scripts/lib/docker-daemon-path.sh
docker_workspace=$(docker_daemon_path "$PWD")
docker run --rm --network none \
--volume "$docker_workspace:/workspace:ro" \
--workdir /workspace \
echoion-release-builder:gcc-16.1.0 \
python3 scripts/tests/test_aggregate_update_feed.py
docker run --rm --network none \
--volume "$docker_workspace:/workspace:ro" \
--workdir /workspace \
echoion-release-builder:gcc-16.1.0 \
python3 scripts/tests/test_gitea_release.py