From e577c02eb3943c447bf8747754feafc87703f9ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B5=D0=B9=20=D0=A1=D0=B0?= =?UTF-8?q?=D0=B1=D0=B8=D0=BB=D0=B8=D0=BD?= Date: Thu, 16 Jul 2026 10:24:06 +0300 Subject: [PATCH] =?UTF-8?q?fix(ci):=20=D0=BE=D0=B1=D1=85=D0=BE=D0=B4=20?= =?UTF-8?q?=D0=BF=D0=B0=D0=B4=D0=B5=D0=BD=D0=B8=D1=8F=20playwright=20--wit?= =?UTF-8?q?h-deps=20=D0=BD=D0=B0=20WSL=20runner.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit На act_runner apt падает на half-configured openssh-server без systemd; fallback устанавливает только Chromium, если системные libs уже есть. Co-authored-by: Cursor --- .gitea/workflows/ci.yml | 2 +- .gitea/workflows/e2e-ift.yml | 2 +- scripts/install-playwright-chromium.sh | 12 ++++++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 scripts/install-playwright-chromium.sh diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 91b4252..a1c1e0b 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -48,7 +48,7 @@ jobs: - run: npm run build - name: Install Playwright browser - run: npx playwright install --with-deps chromium + run: bash scripts/install-playwright-chromium.sh - name: E2E mock suite run: npm run test:e2e diff --git a/.gitea/workflows/e2e-ift.yml b/.gitea/workflows/e2e-ift.yml index 8f694b2..118d400 100644 --- a/.gitea/workflows/e2e-ift.yml +++ b/.gitea/workflows/e2e-ift.yml @@ -33,7 +33,7 @@ jobs: - run: npm ci - name: Install Playwright browser - run: npx playwright install --with-deps chromium + run: bash scripts/install-playwright-chromium.sh - name: Load smoke credentials from IFT .env env: diff --git a/scripts/install-playwright-chromium.sh b/scripts/install-playwright-chromium.sh new file mode 100644 index 0000000..e89d121 --- /dev/null +++ b/scripts/install-playwright-chromium.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash +# Install Playwright Chromium for CI on self-hosted act_runner/WSL. +# --with-deps runs apt and can fail when openssh-server dpkg is half-configured +# (systemctl unavailable in WSL job container). +set -euo pipefail + +if npx playwright install --with-deps chromium; then + exit 0 +fi + +echo "::warning::playwright --with-deps failed; installing browser binary only (system libs expected on runner)" +npx playwright install chromium