How to run a secure shieldsio server locally #7138
-
I don't know if it is even possible to do this easily and I haven't found any documentation about how one can run shieldsio in a secure (HTTPS) way locally. I've followed this description and I've successfully deployed a working server, but it listens only on HTTP. I thought that maybe I need only some small reconfiguration and it will work securely, so what I did is to modify config/production.yaml
The steps what I used to generate the secrets are (self-signed certificate for the sake of ease): openssl genrsa -out https.key
openssl req -new -key https.key -out csr.pem
openssl x509 -req -days 9999 -in csr.pem -signkey https.key -out https.crt
rm csr.pem After rebuilding the docker image and deploying it again the server starts to listen but after the first HTTP GET I'm getting an error:
and the client side curl command returns with:
Does anyone tried to achieve the same thing and had success with it? Maybe I'm missing something obvious, I'm not too familiar with nodejs. I appreciate any help. Thanks, SilverTux |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
the That being said, you might find it easier to just stick something like nginx or haproxy in front of your badge server and let them handle ssl termination |
Beta Was this translation helpful? Give feedback.
the
ssl
block needs to go under thepublic
key, and based on the indentation it looks like that might not be the case given how pedantic yaml is about whitespace.That being said, you might find it easier to just stick something like nginx or haproxy in front of your badge server and let them handle ssl termination