fix: respect options

This commit is contained in:
cha0s 2024-02-17 07:02:03 -06:00
parent 86d088a98e
commit 87e9836cca

View File

@ -10,9 +10,9 @@ export function withWeb(task, options) {
opts: {
...optionsWithTask.opts,
env: {
...optionsWithTask.opts?.env,
FLECKS_ENV__flecks_web__port: '0',
FLECKS_ENV__flecks_web__devPort: '0',
...optionsWithTask.opts?.env,
},
},
});
@ -34,7 +34,8 @@ export function withWeb(task, options) {
socket,
});
}
const response = await connectPage(page, `http://${payload}`, optionsWithTask);
const {pagePath = '/'} = options;
const response = await connectPage(page, `http://${payload}${pagePath}`, optionsWithTask);
let taskError;
try {
await task({