summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Micay <daniel.micay@grapheneos.org>2023-12-25 10:55:05 -0500
committerDaniel Micay <daniel.micay@grapheneos.org>2023-12-25 10:56:27 -0500
commit6fbd66ddfa89fc80dd9df642ec79d5f086f083b3 (patch)
tree66f93c7b26ae9bf1c13e1939ce094885f8f2b446
parent02a97dd883b6d5f5195677bec944cf660b55eda6 (diff)
use 301 redirect with 1 day caching for Discord
There are scenarios where we may have to change the URL so the default 301 behavior is inappropriate but this will work fine.
-rw-r--r--nginx/nginx.conf4
1 files changed, 3 insertions, 1 deletions
diff --git a/nginx/nginx.conf b/nginx/nginx.conf
index 55a70d97..7f6ccae2 100644
--- a/nginx/nginx.conf
+++ b/nginx/nginx.conf
@@ -281,7 +281,9 @@ http {
}
location = "/discord" {
- return 302 https://discord.com/invite/grapheneos;
+ include snippets/security-headers.conf;
+ add_header Cache-Control "public, max-age=86400";
+ return 301 https://discord.com/invite/grapheneos;
}
location = /404 {