Skip to content
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

Add path to self signed certificate for ssl.no-default server block. #177

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions sites-available/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,9 @@ example.com (handles traffic from both www.example.com and example.com)
foobar.com (as above)
test.foobar.com (handles traffic from both www.test.foobar.com and test.foobar.com)
```
The HTTPS no-default server config requires a valid certificate (self signed will suffice).
One can generate the certificate with:
```
sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/nginx/ssl/nginx.key -out /etc/nginx/ssl/nginx.crt

This comment was marked as abuse.

This comment was marked as abuse.

This comment was marked as abuse.

```

5 changes: 5 additions & 0 deletions sites-available/ssl.no-default
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,10 @@
server {
listen 443 ssl default_server;
include h5bp/directive-only/ssl.conf;

ssl_certificate /etc/nginx/ssl/nginx.crt;
ssl_certificate_key /etc/nginx/ssl/nginx.key;

return 444;
}