diff --git a/README.md b/README.md
index 562b821..c0b2857 100644
--- a/README.md
+++ b/README.md
@@ -26,6 +26,10 @@ FreeScout is the super lightweight and powerful free open source help desk and s
![Screenshot of FreeScout](./doc/screenshots/screenshot.png)
+## :red_circle: Antifeatures
+
+- **Not totally free upstream**: The packaged app is under an overall free licence, but with clauses that restrict its use.
+
## Documentation and resources
* Official app website:
diff --git a/README_fr.md b/README_fr.md
index 3919cc0..724bad5 100644
--- a/README_fr.md
+++ b/README_fr.md
@@ -26,6 +26,10 @@ FreeScout est un service d'assistance open source gratuit ultra léger et puissa
![Capture d’écran de FreeScout](./doc/screenshots/screenshot.png)
+## :red_circle: Fonctions indésirables
+
+- **Not totally free upstream**: The packaged app is under an overall free licence, but with clauses that restrict its use.
+
## Documentations et ressources
* Site officiel de l’app :
diff --git a/conf/nginx.conf b/conf/nginx.conf
index 17a4329..21f8325 100644
--- a/conf/nginx.conf
+++ b/conf/nginx.conf
@@ -31,7 +31,7 @@ location __PATH__/ {
location ~* ^/(?:css|js)/.*\.(?:css|js)$ {
expires 2d;
access_log off;
- add_header Cache-Control "public, must-revalidate";
+ more_set_headers "Cache-Control: public, must-revalidate";
}
# The list should be in sync with /storage/app/public/uploads/.htaccess and /config/app.php
diff --git a/manifest.toml b/manifest.toml
index 241f585..6b0f3b9 100644
--- a/manifest.toml
+++ b/manifest.toml
@@ -62,7 +62,7 @@ ram.runtime = "50M"
main.url = "/"
[resources.apt]
- packages = "php8.2-mysql, php8.2-mbstring, php8.2-xml, php8.2-imap, php8.2-zip, php8.2-gd, php8.2-curl, php8.2-intl"
+ packages = "mariadb-server, php8.2-mysql, php8.2-mbstring, php8.2-xml, php8.2-imap, php8.2-zip, php8.2-gd, php8.2-curl, php8.2-intl"
[resources.database]
type = "mysql"
diff --git a/scripts/backup b/scripts/backup
index c72155a..35afc88 100755
--- a/scripts/backup
+++ b/scripts/backup
@@ -39,7 +39,6 @@ ynh_backup --src_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
ynh_backup --src_path="/etc/cron.d/$app"
-
#=================================================
# BACKUP THE MYSQL DATABASE
#=================================================
diff --git a/scripts/change_url b/scripts/change_url
index 4ba8cf7..a264702 100644
--- a/scripts/change_url
+++ b/scripts/change_url
@@ -16,6 +16,13 @@ ynh_script_progression --message="Updating NGINX web server configuration..." --
ynh_change_url_nginx_config
+#=================================================
+# ADD A CONFIGURATION
+#=================================================
+ynh_script_progression --message="Adding a configuration file..." --weight=1
+
+ynh_replace_string --match_string="APP_URL=https://*" --replace_string="APP_URL=https://$new_domain" --target_file=$install_dir/.env
+
#=================================================
# END OF SCRIPT
#=================================================
diff --git a/scripts/install b/scripts/install
index 77e2305..bb8db37 100755
--- a/scripts/install
+++ b/scripts/install
@@ -24,7 +24,9 @@ ynh_script_progression --message="Setting up source files..." --weight=1
# Download, check integrity, uncompress and patch the source from manifest.toml
ynh_setup_source --dest_dir="$install_dir"
+chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
+
usermod -g www-data $app
find $install_dir -type f -exec chmod 664 {} \;
find $install_dir -type d -exec chmod 775 {} \;
diff --git a/scripts/restore b/scripts/restore
index 787e19b..4619525 100755
--- a/scripts/restore
+++ b/scripts/restore
@@ -17,6 +17,7 @@ ynh_script_progression --message="Restoring the app main directory..." --weight=
ynh_restore_file --origin_path="$install_dir"
+chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
#=================================================
diff --git a/scripts/upgrade b/scripts/upgrade
index d55b8d7..ffd974b 100755
--- a/scripts/upgrade
+++ b/scripts/upgrade
@@ -26,10 +26,13 @@ if [ "$upgrade_type" == "UPGRADE_APP" ]
then
ynh_script_progression --message="Upgrading source files..." --weight=1
+ ynh_secure_remove --file="/$install_dir/vendor"
+
# Download, check integrity, uncompress and patch the source from manifest.toml
- ynh_setup_source --dest_dir="$install_dir" --keep='.env'
+ ynh_setup_source --dest_dir="$install_dir" #--keep='.env'
fi
+chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
#=================================================
@@ -46,12 +49,12 @@ ynh_add_nginx_config
#=================================================
# UPDATE A CONFIG FILE
#=================================================
-ynh_script_progression --message="Updating a configuration file..." --weight=1
+#ynh_script_progression --message="Updating a configuration file..." --weight=1
-ynh_add_config --template=".env.example" --destination="$install_dir/.env"
+#ynh_add_config --template=".env.example" --destination="$install_dir/.env"
-chmod 400 "$install_dir/.env"
-chown $app:$app "$install_dir/.env"
+#chmod 400 "$install_dir/.env"
+#chown $app:$app "$install_dir/.env"
#=================================================
# FINAL FREESCOUT INSTALL
@@ -59,11 +62,8 @@ chown $app:$app "$install_dir/.env"
ynh_script_progression --message="Install $app" --weight=5
pushd $install_dir
- php$phpversion artisan key:generate --no-interaction --force
php$phpversion artisan freescout:clear-cache
- php$phpversion artisan storage:link
php$phpversion artisan migrate --no-interaction --force
- php$phpversion artisan freescout:create-user --role=admin --firstName="$firstname" --lastName="$lastname" --email="$email" --password="$password" --no-interaction
popd
#=================================================