-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Issue with https #612
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
Comments
In your case, you'll want to instruct your browser to trust the self-signed certificate that ships with
In some cases, you may need to create a separate self-signed SSL certificate instead. There are lots of posts on the web about how to do this and for how to get some/most browsers to trust the certificate. To make webpack dev server config aware of the certificate, I'm using something similar to the config here: // config/webpack/local-ssl.js
const { resolve } = require('path');
const { readFileSync } = require('fs');
module.exports = {
cert: readFileSync(resolve('path', 'to', 'localhost-self-signed.pem'), 'utf8')
}; // config/webpack/development.js
const { cert } = require('./local-ssl.js')
const https = { key: cert, cert: cert }
module.exports = merge(sharedConfig, {
// ...
devServer: {
// ...
https: https,
},
//... I may open a PR to add this to the README, but in the meantime, I hope that's helpful. |
thanks @rossta 🍰 |
Uh oh!
There was an error while loading. Please reload this page.
ps. sorry for my english.
I have site that work over https. I add changes to webpacker to work with ssl.
development.js
But its raise error in browser. Its download applictions js over http? Why so?
Mixed Content: The page at 'https://localhost:3000/' was loaded over HTTPS, but requested an insecure script 'http://localhost:8080/packs/application.js'. This request has been blocked; the content must be served over HTTPS.
server puma.
The text was updated successfully, but these errors were encountered: