Is there anyway to get the plasmo dev server working in a docker container? pnpm dev works on host

The server is all up and running using node:18-bullseye. However when i load unpacked into chrome it says that it cannot connect with the websockets running on ws://localhost:1815 and ws://localhost:1816.
function A(e) {
if (typeof globalThis.WebSocket > "u") return;
let t = new WebSocket(C());
return t.addEventListener("message", async function(o) {
let s = JSON.parse(o.data);
if (s.type === "update" && await e(s.assets), s.type === "error") for (let r of s.diagnostics.ansi){
let l = r.codeframe || r.stack;
f("[plasmo/parcel-runtime]: " + r.message + `
` + l + `
function A(e) {
if (typeof globalThis.WebSocket > "u") return;
let t = new WebSocket(C());
return t.addEventListener("message", async function(o) {
let s = JSON.parse(o.data);
if (s.type === "update" && await e(s.assets), s.type === "error") for (let r of s.diagnostics.ansi){
let l = r.codeframe || r.stack;
f("[plasmo/parcel-runtime]: " + r.message + `
` + l + `
I have attempted to - add host permissions to allow for all localhost connection in the manifest. - put the container network in host mode - changed ip address binding for the container around from 0.0.0.0 to 127.0.0.1 As mentioned when running on the host machine this connection is completely fine. Thanks!
1 Reply
Sam
Sam•2d ago
If you're running the extension built in Docker from the host machine you'll need to expose the port from within docker. and even then I'm not sure if you'll be able to connect to the Docker container VIA localhost.
Want results from more Discord servers?
Add your server