diff --git a/conf/systemd.service b/conf/systemd.service index 70c3c85..d3aa0ca 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -10,7 +10,7 @@ WorkingDirectory=__FINALPATH__/ Environment="PATH=__ENV_PATH__" Environment="THELOUNGE_HOME=/home/yunohost.app/__APP__/" Environment="NODE_ENV=production" -ExecStart=/usr/bin/yarn start +ExecStart==__YNH_NODE__ start Restart=on-failure RestartSec=5 StartLimitInterval=60s diff --git a/scripts/install b/scripts/install index 952e92d..8d06483 100644 --- a/scripts/install +++ b/scripts/install @@ -65,7 +65,7 @@ ynh_script_progression --message="Installing dependencies..." --weight=7 ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version # Install Yarn -ynh_install_extra_app_dependencies --repo="deb https://dl.yarnpkg.com/debian/ stable main" --package="yarn" --key="https://dl.yarnpkg.com/debian/pubkey.gpg" +#ynh_install_extra_app_dependencies --repo="deb https://dl.yarnpkg.com/debian/ stable main" --package="yarn" --key="https://dl.yarnpkg.com/debian/pubkey.gpg" #================================================= # CREATE DEDICATED USER @@ -126,9 +126,7 @@ ynh_script_progression --message="Installing The Lounge..." --weight=10 pushd $final_path ynh_use_nodejs - NODE_ENV=production ynh_exec_warn_less yarn install - NODE_ENV=production yarn add webpack webpack-cli --dev - NODE_ENV=production ynh_exec_warn_less yarn build + $ynh_exec_as $app env $ynh_node_load_PATH ynh_npm install --global --unsafe-perm thelounge popd #=================================================