feat(ci): последовательный deploy IFT -> E2E -> stage -> E2E.
CI / test (push) Successful in 2m21s
CI / push-image (push) Successful in 4m7s
CI / ci-done (push) Successful in 0s

Stage деплоится только после полного UI-сьюта на IFT; после stage — E2E на stage (ift-ui/stage-ui + smoke).

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-07-16 11:31:22 +03:00
parent e577c02eb3
commit 840f06e68e
7 changed files with 152 additions and 52 deletions
+31 -14
View File
@@ -2,6 +2,13 @@ import { defineConfig, devices } from '@playwright/test';
const port = Number(process.env.E2E_PORT || 4173);
const baseURL = process.env.E2E_BASE_URL || `http://127.0.0.1:${port}`;
const iftBaseURL = process.env.E2E_IFT_BASE_URL || 'https://admin-ui.ift.eventhub.local';
const stageBaseURL = process.env.E2E_STAGE_BASE_URL || 'https://admin-ui.stage.eventhub.local';
const liveTarget = process.env.E2E_TARGET;
const liveChrome = {
...devices['Desktop Chrome'],
ignoreHTTPSErrors: true,
};
export default defineConfig({
testDir: './e2e/tests',
@@ -23,23 +30,33 @@ export default defineConfig({
use: { ...devices['Desktop Chrome'] },
testIgnore: /ift\//,
},
{
name: 'ift-ui',
use: { ...liveChrome, baseURL: iftBaseURL },
testIgnore: /ift\//,
},
{
name: 'ift-smoke',
use: {
...devices['Desktop Chrome'],
baseURL: process.env.E2E_IFT_BASE_URL || 'https://admin-ui.ift.eventhub.local',
ignoreHTTPSErrors: true,
},
use: { ...liveChrome, baseURL: iftBaseURL },
testMatch: /ift\//,
},
{
name: 'stage-ui',
use: { ...liveChrome, baseURL: stageBaseURL },
testIgnore: /ift\//,
},
{
name: 'stage-smoke',
use: { ...liveChrome, baseURL: stageBaseURL },
testMatch: /ift\//,
},
],
webServer:
process.env.E2E_TARGET === 'ift'
? undefined
: {
command: `npm run preview -- --host 127.0.0.1 --port ${port}`,
url: baseURL,
reuseExistingServer: !process.env.CI,
timeout: 120_000,
},
webServer: liveTarget
? undefined
: {
command: `npm run preview -- --host 127.0.0.1 --port ${port}`,
url: baseURL,
reuseExistingServer: !process.env.CI,
timeout: 120_000,
},
});