[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: sysadmin: nginx: Add ^ to the start of several re
From: |
Christopher Baines |
Subject: |
branch master updated: sysadmin: nginx: Add ^ to the start of several regexes. |
Date: |
Tue, 03 Sep 2024 12:08:49 -0400 |
This is an automated email from the git hooks/post-receive script.
cbaines pushed a commit to branch master
in repository maintenance.
The following commit(s) were added to refs/heads/master by this push:
new 3de9f211 sysadmin: nginx: Add ^ to the start of several regexes.
3de9f211 is described below
commit 3de9f2119371038650045946ba6e7de6e90f68e5
Author: Christopher Baines <mail@cbaines.net>
AuthorDate: Tue Sep 3 14:58:01 2024 +0100
sysadmin: nginx: Add ^ to the start of several regexes.
As it looks like these should only match from the start of the path.
This fixes the /devel/manual issue.
* hydra/modules/sysadmin/nginx.scm (guix.gnu.org-redirect-locations,
guix.gnu.org-other-locations): Add ^ to the start of some regexes.
---
hydra/modules/sysadmin/nginx.scm | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/hydra/modules/sysadmin/nginx.scm b/hydra/modules/sysadmin/nginx.scm
index 8628222b..d1f67e09 100644
--- a/hydra/modules/sysadmin/nginx.scm
+++ b/hydra/modules/sysadmin/nginx.scm
@@ -76,10 +76,10 @@ synonymous IETF language tags that should be mapped to the
same $lang."
(define guix.gnu.org-redirect-locations
(list
(nginx-location-configuration
- (uri "~ /packages/.*")
+ (uri "~ ^/packages/.*")
(body (list "return 301 https://packages.guix.gnu.org;")))
(nginx-location-configuration
- (uri "~ /([^/]+)/packages/.*")
+ (uri "~ ^/([^/]+)/packages/.*")
(body (list "return 301 https://packages.guix.gnu.org;")))
;; Short URL for the installation script
@@ -698,17 +698,17 @@ synonymous IETF language tags that should be mapped to
the same $lang."
;; These rules take precedence over the '.pdf' and '.html' rules below.
(nginx-location-configuration
- (uri "~ /manual/devel(|/.*)$")
+ (uri "~ ^/manual/devel(|/.*)$")
(body (list "expires 4h;"
"gzip on;"
"alias /srv/guix-manual-devel$1;")))
(nginx-location-configuration
- (uri "~ /manual(|/.*)$")
+ (uri "~ ^/manual(|/.*)$")
(body (list "expires 1d;"
"gzip on;"
"alias /srv/guix-manual$1;")))
(nginx-location-configuration
- (uri "~ /cookbook(|/.*)$")
+ (uri "~ ^/cookbook(|/.*)$")
(body (list "expires 4h;"
"gzip on;"
"alias /srv/guix-cookbook$1;")))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: sysadmin: nginx: Add ^ to the start of several regexes.,
Christopher Baines <=