- Add Next.js app structure with base configs, linting, and formatting - Implement LiveKit Meet page, types, and utility functions - Add Docker, Compose, and deployment scripts for backend and token server - Provide E2E and smoke test scaffolding with Puppeteer and Playwright helpers - Include CSS modules and global styles for UI - Add postMessage and studio integration utilities - Update package.json with dependencies and scripts for development and testing
19 lines
805 B
JavaScript
19 lines
805 B
JavaScript
const puppeteer = require('puppeteer-core');
|
|
(async () => {
|
|
const ws = process.env.BROWSERLESS_WS || `wss://browserless.bfzqqk.easypanel.host?token=${process.env.BROWSERLESS_TOKEN}`;
|
|
console.log('Trying connect to', ws);
|
|
try {
|
|
const browser = await puppeteer.connect({ browserWSEndpoint: ws, defaultViewport: { width: 800, height: 600 } });
|
|
console.log('Connected OK to browserless');
|
|
const page = await browser.newPage();
|
|
await page.goto(process.env.BROADCAST_URL || 'http://localhost:5175', { waitUntil: 'networkidle2', timeout: 20000 });
|
|
console.log('Page loaded:', await page.title(), page.url());
|
|
await browser.disconnect();
|
|
process.exit(0);
|
|
} catch (err) {
|
|
console.error('Connect failed:', err && err.stack ? err.stack : err);
|
|
process.exit(2);
|
|
}
|
|
})();
|
|
|