mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Improve comments of ynh_spawn_app_shell
This commit is contained in:
parent
db7ab2a98b
commit
f3faac87f8
1 changed files with 4 additions and 1 deletions
|
@ -166,12 +166,15 @@ ynh_spawn_app_shell() {
|
||||||
local service=$(ynh_app_setting_get --app=$app --key=service)
|
local service=$(ynh_app_setting_get --app=$app --key=service)
|
||||||
[ -z "$service" ] && service=$app;
|
[ -z "$service" ] && service=$app;
|
||||||
|
|
||||||
|
# Export HOME variable
|
||||||
|
export HOME=$install_dir;
|
||||||
|
|
||||||
# Load the Environment variables from the app's service
|
# Load the Environment variables from the app's service
|
||||||
local env_var=$(systemctl show $service.service -p "Environment" --value)
|
local env_var=$(systemctl show $service.service -p "Environment" --value)
|
||||||
[ -n "$env_var" ] && export $env_var;
|
[ -n "$env_var" ] && export $env_var;
|
||||||
export HOME=$install_dir;
|
|
||||||
|
|
||||||
# Force `php` to its intended version
|
# Force `php` to its intended version
|
||||||
|
# We use `eval`+`export` since `alias` is not propagated to subshells, even with `export`
|
||||||
local phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
|
local phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
|
||||||
if [ -n "$phpversion" ]
|
if [ -n "$phpversion" ]
|
||||||
then
|
then
|
||||||
|
|
Loading…
Add table
Reference in a new issue