fix sed and add whitespace

This commit is contained in:
driz 2024-01-03 15:49:22 -05:00 committed by GitHub
parent 4030be8278
commit ca6cd4b47e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 6 deletions

View File

@ -58,9 +58,6 @@ server {
# Remove X-Powered-By, which is an information leak
fastcgi_hide_header X-Powered-By;
# default nginx mime.types
include mime.types;
# Specify how to handle directories -- specifying `/index.php$request_uri`
# here as the fallback means that Nginx always exhibits the desired behaviour
# when a client requests a path that corresponds to a directory that exists
@ -171,4 +168,4 @@ server {
location ~ /\.ht {
deny all;
}
}
}

View File

@ -171,6 +171,6 @@ fi
#modify javascript mime type and add .mjs support
if [ -s /etc/nginx/mime.types ]; then
sed -i 's| js;|js mjs;|g' /etc/nginx/mime.types
sed -i 's|^application/javascript|text/javascript|g' /etc/nginx/mime.types
sed -i 's|\bjs;|js mjs;|g' /etc/nginx/mime.types
sed -i 's|\bapplication/javascript|text/javascript|g' /etc/nginx/mime.types
fi