Skip to content

Commit

Permalink
nixos/nextcloud: fix several php endpoints
Browse files Browse the repository at this point in the history
  • Loading branch information
Mic92 committed Oct 26, 2020
1 parent 753f5ee commit b7a2a5f
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions nixos/modules/services/web-apps/nextcloud.nix
Expand Up @@ -549,9 +549,7 @@ in {
};
"/" = {
priority = 900;
extraConfig = if major < 20
then "rewrite ^ /index.php;"
else "try_files $uri $uri/ /index.php$request_uri;";
extraConfig = "rewrite ^ /index.php;";
};
"~ ^/store-apps" = {
priority = 201;
Expand All @@ -575,7 +573,7 @@ in {
"~ ^/(?:\\.|autotest|occ|issue|indie|db_|console)".extraConfig = ''
return 404;
'';
${if major < 20 then "~ ^\\/(?:index|remote|public|cron|core\\/ajax\\/update|status|ocs\\/v[12]|updater\\/.+|oc[ms]-provider\\/.+|.+\\/richdocumentscode\\/proxy)\\.php(?:$|\\/)" else "~ \\.php(?:$|/)"} = {
"~ ^\\/(?:index|remote|public|cron|core\\/ajax\\/update|status|ocs\\/v[12]|updater\\/.+|oc[ms]-provider\\/.+|.+\\/richdocumentscode\\/proxy)\\.php(?:$|\\/)" = {
priority = 500;
extraConfig = ''
include ${config.services.nginx.package}/conf/fastcgi.conf;
Expand Down

0 comments on commit b7a2a5f

Please sign in to comment.