mirror of
https://github.com/YunoHost-Apps/prettynoemiecms_ynh.git
synced 2024-09-03 20:06:36 +02:00
commit
2676934eee
3 changed files with 17 additions and 4 deletions
|
@ -2,7 +2,7 @@
|
|||
location __PATH__/ {
|
||||
|
||||
# Path to source
|
||||
root __FINALPATH__/ ;
|
||||
alias __FINALPATH__/ ;
|
||||
|
||||
# Force usage of https
|
||||
if ($scheme = http) {
|
||||
|
@ -14,7 +14,14 @@ location __PATH__/ {
|
|||
# Common parameter to increase upload size limit in conjunction with dedicated php-fpm file
|
||||
client_max_body_size 50M;
|
||||
|
||||
try_files $uri $uri/ /index.php?$query_string;
|
||||
location __PATH__/yunohost {
|
||||
try_files $uri $uri/ index.php;
|
||||
}
|
||||
|
||||
location __PATH__/ {
|
||||
try_files $uri $uri/ @prettynoemiecms;
|
||||
}
|
||||
|
||||
location ~ [^/]\.php(/|$) {
|
||||
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
|
||||
fastcgi_pass unix:/var/run/php/php7.0-fpm-__NAME__.sock;
|
||||
|
@ -31,6 +38,6 @@ location __PATH__/ {
|
|||
include conf.d/yunohost_panel.conf.inc;
|
||||
}
|
||||
|
||||
location __PATH__/medias/ {
|
||||
alias __FINALPATH__/sites/$host/medias/;
|
||||
location @prettynoemiecms {
|
||||
rewrite /(.*)$ __PATH__/index.php?/$1 last;
|
||||
}
|
||||
|
|
|
@ -146,6 +146,9 @@ ynh_app_setting_delete --app=$app --key=skipped_uris
|
|||
# Calculate and store the config file checksum into the app settings
|
||||
ynh_store_file_checksum --file="$final_path/sites/$domain/config.json"
|
||||
|
||||
# Fix a bug where images can't be uploaded
|
||||
ynh_replace_string --match_string="isMediaPathModified = true" --replace_string="" --target_file="$final_path/app/config/config.ini"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
|
|
|
@ -130,6 +130,9 @@ ynh_backup_if_checksum_is_different --file="$final_path/sites/$domain/config.jso
|
|||
# Recalculate and store the checksum of the file for the next upgrade.
|
||||
ynh_store_file_checksum --file="$final_path/sites/$domain/config.json"
|
||||
|
||||
# Fix a bug where images can't be uploaded
|
||||
ynh_replace_string --match_string="isMediaPathModified = true" --replace_string="" --target_file="$final_path/app/config/config.ini"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue