Skip to content

Commit

Permalink
Merge pull request #14 from valiantlynx/working
Browse files Browse the repository at this point in the history
-d svelte-rich-text.{{ domain }}
  • Loading branch information
valiantlynx authored Mar 21, 2024
2 parents c4ec0b5 + 10ce3e1 commit 3f927f7
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ services:
command: >
certonly --webroot -w /var/www/certbot --force-renewal --email valiantlynxz@gmail.com
{% for domain in cloudflare_zone_ids.keys() %}
-d {{ domain }} -d www.{{ domain }}
-d svelte-rich-text.{{ domain }}
{% endfor %}
--agree-tos --non-interactive
networks:
Expand Down
2 changes: 1 addition & 1 deletion ansible/roles/docker_deploy/templates/nginx/http.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ http {
# Configuration for astromanga.com
server {
listen 80;
server_name server_name {% for domain in cloudflare_zone_ids.keys() %}{{ domain }} www.{{ domain }} {% endfor %};
server_name server_name {% for domain in cloudflare_zone_ids.keys() %}svelte-rich-text.{{ domain }} {% endfor %};

location / {
proxy_pass http://svelte-rich-text:3000;
Expand Down
8 changes: 4 additions & 4 deletions ansible/roles/docker_deploy/templates/nginx/https.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,18 @@ http {
# Always redirect HTTP to HTTPS
server {
listen 80;
server_name server_name {% for domain in cloudflare_zone_ids.keys() %}{{ domain }} www.{{ domain }} {% endfor %};
server_name server_name {% for domain in cloudflare_zone_ids.keys() %}svelte-rich-text.{{ domain }} {% endfor %};
return 301 https://$host$request_uri;
}
# Configuration for astromanga.com
server {
listen 443 ssl http2;
server_name server_name {% for domain in cloudflare_zone_ids.keys() %}{{ domain }} www.{{ domain }} {% endfor %};
server_name server_name {% for domain in cloudflare_zone_ids.keys() %}svelte-rich-text.{{ domain }} {% endfor %};

# Use the first domain in the list for SSL certificate paths
{% set primary_domain = cloudflare_zone_ids.keys() | list | first %}
ssl_certificate /etc/letsencrypt/live/{{ primary_domain }}/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/{{ primary_domain }}/privkey.pem;
ssl_certificate /etc/letsencrypt/live/svelte-rich-text.{{ primary_domain }}/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/svelte-rich-text.{{ primary_domain }}/privkey.pem;
# include /etc/letsencrypt/options-ssl-nginx.conf; # Recommended SSL settings
# ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # DH parameters

Expand Down

0 comments on commit 3f927f7

Please sign in to comment.