Difference between revisions of "Nginx"
From Organic Design wiki
m (→Self-signed SSL certificates) |
m (→Self-signed SSL certificates) |
||
Line 29: | Line 29: | ||
The relevant ''server'' section can now be updated in the nginx configuration, | The relevant ''server'' section can now be updated in the nginx configuration, | ||
− | {{code|<pre> | + | {{code|<pre>listen 80; |
listen 443 default ssl; | listen 443 default ssl; | ||
Revision as of 16:28, 29 August 2012
Self-signed SSL certificates
Nginx doesn't use the basic .pem files that can be used by Apache for self-signed certificates. We need to go through the following procedure to turn the pem into key and crt files.
First we need to create a private key. Note that this process will require a pass-phrase for the key - don't worry, we'll remove it later to make things easier,
Now we need to create a CSR (Certificate Signing Request):
Now we need to remove the pass-phrase otherwise it'll prevent the web-server from restarting without it being entered (you'll need to enter the pass-phrase to remove it though),
Now we can generate the actual certificate:
The relevant server section can now be updated in the nginx configuration,