Saved servers, sectioned settings (owner reference), theme choice, video details; release gates and token-safe publisher; root cargo config with static Windows CRT
ci / linux-arm64-cross (push) Successful in 2m15s
ci / linux-x64 (push) Failing after 3m7s

This commit is contained in:
omar committed 2026-10-24 04:02:04 +03:00
1 parent 24266469bf
commit 05d38d8094
30 files changed
+1062 -171

No files matched your search

+49 -22
View File
@@ -12,6 +12,10 @@ on:
permissions:
contents: read
defaults:
run:
shell: bash
jobs:
linux-x64:
runs-on: ubuntu-latest
@@ -23,8 +27,12 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Version gate (tag = package.json = core/Cargo.toml)
run: node scripts/check-version.mjs
- name: System packages (container only)
run: |
set -euo pipefail
apt-get update
apt-get install -y --no-install-recommends build-essential cmake curl ca-certificates git \
xvfb xauth libnss3 libatk1.0-0 libatk-bridge2.0-0 libcups2 libdrm2 libgbm1 libgtk-3-0 \
@@ -32,17 +40,20 @@ jobs:
- name: Rust toolchain
run: |
set -euo pipefail
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain stable
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
- name: Tests
run: |
set -euo pipefail
npm ci
npm test
cargo test --manifest-path core/Cargo.toml --locked
- name: Core release build and checks
run: |
set -euo pipefail
cargo build --manifest-path core/Cargo.toml --release --locked
node scripts/binary-arch.mjs core/target/release/teamspeach-core --expect linux-x64
node scripts/core-smoke.mjs core/target/release/teamspeach-core
@@ -55,11 +66,16 @@ jobs:
- name: Package
run: node scripts/dist.mjs --os linux --arch x64
- name: Package report
- name: Package report (ELF layout of every packaged binary incl. the AppImage runtime)
run: |
ldd --version | head -n1 > dist/build-info-linux-x64.txt
node scripts/elf-pagesize.mjs dist/linux-unpacked --page 4096 --json dist/elf-report-linux-x64.json >> dist/build-info-linux-x64.txt
sha256sum dist/*.AppImage dist/*.tar.gz >> dist/build-info-linux-x64.txt
set -euo pipefail
report=dist/build-info-linux-x64.txt
ldd --version | head -n1 > "$report"
git rev-parse HEAD >> "$report"
node scripts/elf-pagesize.mjs dist/linux-unpacked dist/TeamsPeach-*.AppImage --page 4096 --json dist/elf-report-linux-x64.json > elf.txt
cat elf.txt >> "$report"
sha256sum dist/*.AppImage dist/*.tar.gz >> "$report"
cat "$report"
- uses: actions/upload-artifact@v3
with:
@@ -85,19 +101,25 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Version gate (tag = package.json = core/Cargo.toml)
run: node scripts/check-version.mjs
- name: Cross toolchain and user-mode emulator (container only, no binfmt)
run: |
set -euo pipefail
apt-get update
apt-get install -y --no-install-recommends build-essential cmake curl ca-certificates git \
gcc-aarch64-linux-gnu g++-aarch64-linux-gnu libc6-dev-arm64-cross qemu-user
- name: Rust toolchain
run: |
set -euo pipefail
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain stable --target aarch64-unknown-linux-gnu
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
- name: Core cross build and checks
run: |
set -euo pipefail
cargo build --manifest-path core/Cargo.toml --release --locked --target aarch64-unknown-linux-gnu
node scripts/binary-arch.mjs core/target/aarch64-unknown-linux-gnu/release/teamspeach-core --expect linux-arm64
node scripts/elf-pagesize.mjs core/target/aarch64-unknown-linux-gnu/release/teamspeach-core --page 16384
@@ -105,14 +127,20 @@ jobs:
- name: Package
run: |
set -euo pipefail
npm ci
node scripts/dist.mjs --os linux --arch arm64
- name: 16 KiB page check of every ELF in the package (Asahi)
- name: 16 KiB page check of every packaged ELF incl. the AppImage runtime (Asahi)
run: |
echo "glibc of build sysroot: $(dpkg-query -W -f='${Version}' libc6-dev-arm64-cross)" > dist/build-info-linux-arm64.txt
node scripts/elf-pagesize.mjs dist/linux-arm64-unpacked --page 16384 --json dist/elf-report-linux-arm64.json | tee -a dist/build-info-linux-arm64.txt
sha256sum dist/*.AppImage dist/*.tar.gz >> dist/build-info-linux-arm64.txt
set -euo pipefail
report=dist/build-info-linux-arm64.txt
echo "glibc of build sysroot: $(dpkg-query -W -f='${Version}' libc6-dev-arm64-cross)" > "$report"
git rev-parse HEAD >> "$report"
node scripts/elf-pagesize.mjs dist/linux-arm64-unpacked dist/TeamsPeach-*-arm64.AppImage --page 16384 --json dist/elf-report-linux-arm64.json > elf.txt
cat elf.txt >> "$report"
sha256sum dist/*.AppImage dist/*.tar.gz >> "$report"
cat "$report"
- uses: actions/upload-artifact@v3
with:
@@ -133,26 +161,25 @@ jobs:
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v3
with:
path: artifacts
- name: Create release and upload packages
- name: Publish release (draft → upload all → publish)
env:
TOKEN: ${{ secrets.GITEA_TOKEN }}
API: ${{ github.server_url }}/api/v1/repos/${{ github.repository }}
TAG: ${{ github.ref_name }}
run: |
set -eu
body="Linux x64 и Linux ARM64 (aarch64) собраны в CI: тесты, офлайн-проверка ядра, проверка страниц 16 КиБ для ARM64 (см. build-info-*.txt). ARM64 проверен только статически и под qemu, не на Apple Silicon. Пакеты не подписаны. Сборка Windows x64 прикладывается отдельно с пометкой local."
id=$(node -e '
const [api, tag, token, body] = process.argv.slice(1);
fetch(`${api}/releases`, { method: "POST", headers: { Authorization: `token ${token}`, "Content-Type": "application/json" },
body: JSON.stringify({ tag_name: tag, name: `TeamsPeach ${tag}`, body, prerelease: true }) })
.then(async (r) => { const j = await r.json(); if (!r.ok) { console.error(r.status, JSON.stringify(j)); process.exit(1); } console.log(j.id); });
' "$API" "$TAG" "$TOKEN" "$body")
for f in artifacts/*/*; do
name=$(basename "$f")
curl --fail -sS -X POST -H "Authorization: token $TOKEN" -F "attachment=@$f" "$API/releases/$id/assets?name=$name" > /dev/null
echo "uploaded $name"
done
set -euo pipefail
node scripts/check-version.mjs
cat > notes.md <<'EOF'
Linux x64 и Linux ARM64 (aarch64) собраны в CI: тесты, офлайн-проверка ядра, проверка выравнивания ELF
(для ARM64 — страницы 16 КиБ, включая загрузчик AppImage), см. build-info-*.txt.
ARM64 проверен статически и под qemu, не на Apple Silicon. Пакеты не подписаны.
Сборка Windows x64 собирается на машине разработчика из того же коммита и прикладывается отдельно
с пометкой local.
EOF
node scripts/publish-release.mjs artifacts notes.md