diff --git a/scripts/install b/scripts/install index 49bf50f..50004d6 100644 --- a/scripts/install +++ b/scripts/install @@ -125,14 +125,16 @@ sudo chown admin -R $install_log pushd $final_path ynh_use_nodejs -npm install >> $install_log 2>&1 -node osjs build +NODE_ENV=production npm install >> $install_log 2>&1 +NODE_ENV=production npm run build popd #================================================= -# Configure init script +# Set right on directory and configure init script #================================================= +sudo chown $app:$app $final_path -R +sudo chmod 755 $final_path -R systemctl daemon-reload systemctl enable "$app".service systemctl start "$app".service