Skip to content

Commit

Permalink
Merge pull request #10575 from nextcloud/fix/nginx-serving-static-mjs
Browse files Browse the repository at this point in the history
fix(admin_manual): Add module js (`mjs`) as static resource to nginx config
  • Loading branch information
susnux authored Jun 7, 2023
2 parents bfa985e + 6622bdb commit e0f0722
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion admin_manual/installation/nginx-root.conf.sample
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,8 @@ server {
fastcgi_max_temp_file_size 0;
}

location ~ \.(?:css|js|svg|gif|png|jpg|ico|wasm|tflite|map)$ {
# Serve static files
location ~ \.(?:css|js|mjs|svg|gif|png|jpg|ico|wasm|tflite|map)$ {
try_files $uri /index.php$request_uri;
add_header Cache-Control "public, max-age=15778463, $asset_immutable";
access_log off; # Optional: Don't log access to assets
Expand Down
3 changes: 2 additions & 1 deletion admin_manual/installation/nginx-subdir.conf.sample
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,8 @@ server {
fastcgi_max_temp_file_size 0;
}

location ~ \.(?:css|js|svg|gif|png|jpg|ico|wasm|tflite|map)$ {
# Serve static files
location ~ \.(?:css|js|mjs|svg|gif|png|jpg|ico|wasm|tflite|map)$ {
try_files $uri /nextcloud/index.php$request_uri;
add_header Cache-Control "public, max-age=15778463, $asset_immutable";
access_log off; # Optional: Don't log access to assets
Expand Down

0 comments on commit e0f0722

Please sign in to comment.