-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Suggestions how to implement this with DDEV? #79
Comments
It looks like your host value isn't quite right. You'll want that to be |
Unfortunately, when using 0.0.0.0 as the host value, I get some puzzling CORS errors...
I know, CORS isn't actually an issue with this plugin and if it's requested, I will close the issue and try and figure it out myself. I'd be super glad for some assistance though. I have a working, yet very hacky and not so elegant solution for now. Would be amazing to get this working though! |
Different domain is blocked by cors of browser. You can use some browser extension to disable checking cors |
I'm experiencing a similar issue. I can't access my server remotely because when I set Currently, the file To address this, your server: {
host: '0.0.0.0', // Listen on all network interfaces
https: {
key: fs.readFileSync(process.env.SSL_LOCAL_PK), // Path to SSL key
cert: fs.readFileSync(process.env.SSL_LOCAL_CERT), // Path to SSL cert
},
// port: 5173, // Required if strictPort is true
origin: 'https://example.com', // Dev server URL (the fixed plugin will auto-append the port if missing)
hmr: {
protocol: 'wss', // HMR uses wss protocol
host: 'example.com', // Dev server host (without protocol)
// port: 5173 // Must match the server port if specified
},
// strictPort: true, // Enforce a specific port or throw an error if it's taken
},
I don't know much about DDEV, but I personally use Valet Linux Plus, which simplifies creating self-signed certificates. |
Heyup!
Thanks for the plugin! Since I am working with ddev/ddev as my development environment, I was wondering if you have any suggestions to get it working there. I've tried to follow the instructions of this blogpost, sadly with no luck. Here's a reproduction repo: https://github.com/timothyoesch/ddev-vite-for-wp
Thanks for your help!
The text was updated successfully, but these errors were encountered: