Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
Commit0ec79effffe412e21af18813f04800f008ade98b (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2020-06-12 15:28:11 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2020-06-12 15:28:11 +0300
Files3181d176f682b4dcc37f1ce39d65eeb5c47a2d21
syndamia.com-0ec79effffe412e21af18813f04800f008ade98b.tar
syndamia.com-0ec79effffe412e21af18813f04800f008ade98b.tar.gz
syndamia.com-0ec79effffe412e21af18813f04800f008ade98b.zip
Parent9685f8dbcc61120e0cf7719e9198a4f37223aaba (diff)
Updated nginx configuration file (to reflect the one on the server)
1 files changed, 10 insertions, 1 deletions
-rw-r--r--syndamiadotcom11
diff --git a/syndamiadotcom b/syndamiadotcom
index 1520330..10a20ca 100644
--- a/syndamiadotcom
+++ b/syndamiadotcom
@@ -1,10 +1,13 @@
# NGINX configuration file for the website
server {
- listen 80;
+ listen 443 ssl;
root /var/www/syndamiadotcom/website;
index index.html;
server_name www.syndamia.com;
+ ssl_certificate /etc/letsencrypt/live/www.syndamia.com/fullchain.pem;
+ ssl_certificate_key /etc/letsencrypt/live/www.syndamia.com/privkey.pem;
+
# This removes .html extension from url (https://stackoverflow.com/a/38238001/12036073)
location / {
if ($request_uri ~ ^/(.*)\.html$) {
@@ -13,3 +16,9 @@ server {
try_files $uri $uri.html $uri/ =404;
}
}
+
+server {
+ listen 80;
+ server_name www.syndamia.com;
+ return 301 https://$server_name$request_uri;
+}