File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change 166
166
forceSSL = lib . mkIf cfg . recommendedDefaults true ;
167
167
locations = {
168
168
"= /admin" . return = "307 /admin/" ;
169
- "^~ /admin/" = {
169
+ "/admin/" = {
170
170
alias = "${ cfga . package } /" ;
171
+ priority = 500 ;
171
172
tryFiles = "$uri $uri/ /index.html" ;
172
173
} ;
173
- "~ ^/admin/.*\. (?:css|js|jpg|jpeg|gif|png|svg|ico|woff|woff2|ttf|eot|webp)$" . extraConfig = /* nginx */ ''
174
- expires 30d;
175
- more_set_headers "Cache-Control: public";
176
- '' ;
174
+ "~ ^/admin/.*\\ .(?:css|js|jpg|jpeg|gif|png|svg|ico|woff|woff2|ttf|eot|webp)$" = {
175
+ priority = 400 ;
176
+ root = cfga . package ;
177
+ extraConfig = /* nginx */ ''
178
+ rewrite ^/admin/(.*)$ /$1 break;
179
+ expires 30d;
180
+ more_set_headers "Cache-Control: public";
181
+ '' ;
182
+ } ;
177
183
} ;
178
184
} ;
179
185
} )
You can’t perform that action at this time.
0 commit comments