ci: rust job through the builder image, worker test stage and runtime start, nightly advisories, manual digest-tagged release-images workflow; CSP proof script

This commit is contained in:
bchanot committed 2026-10-13 00:01:26 +02:00
1 parent 3970cdca52
commit 4833fd29ef
7 files changed
+131 -1

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
import { chromium } from 'playwright-core'
const exe = process.env.CHROME
const browser = await chromium.launch({ executablePath: exe, headless: true })
for (const [name, port] of [['without wasm-unsafe-eval', 8091], ['with wasm-unsafe-eval', 8092]]) {
const page = await browser.newPage()
const logs = []
page.on('console', (m) => logs.push(`${m.type()}: ${m.text()}`))
page.on('pageerror', (e) => logs.push(`pageerror: ${e.message}`))
const resp = await page.goto(`http://127.0.0.1:${port}/`)
const csp = resp.headers()['content-security-policy']
await page.waitForFunction(() => document.title !== 'pending', null, { timeout: 10000 }).catch(() => {})
const wasmResp = await page.request.get(`http://127.0.0.1:${port}/pkg/faunosteo_wasm_bg.wasm`)
console.log(`== ${name}: title="${await page.title()}" csp-has-wasm-unsafe-eval=${csp.includes('wasm-unsafe-eval')} wasm-content-type=${wasmResp.headers()['content-type']}`)
for (const l of logs) console.log(' ' + l.slice(0, 220))
await page.close()
}
await browser.close()