mirror of
https://github.com/YunoHost-Apps/distbin_ynh.git
synced 2024-09-03 18:26:10 +02:00
Change installation steps
This commit is contained in:
parent
dffe065991
commit
d326e36dea
2 changed files with 4 additions and 5 deletions
|
@ -8,7 +8,7 @@ User=__APP__
|
||||||
Group=__APP__
|
Group=__APP__
|
||||||
EnvironmentFile=__FINALPATH__/.env
|
EnvironmentFile=__FINALPATH__/.env
|
||||||
WorkingDirectory=__FINALPATH__/
|
WorkingDirectory=__FINALPATH__/
|
||||||
ExecStart=/bin/sh -c '__FINALPATH__/node_modules/.bin/ts-node --project __FINALPATH__/tsconfig.json __FINALPATH__/bin/server.ts >> /var/log/__APP__/__APP__.log 2>&1'
|
ExecStart=/bin/sh -c 'npm start >> /var/log/__APP__/__APP__.log 2>&1'
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|
|
@ -16,6 +16,7 @@ source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
ynh_clean_setup () {
|
ynh_clean_setup () {
|
||||||
### Remove this function if there's nothing to clean before calling the remove script.
|
### Remove this function if there's nothing to clean before calling the remove script.
|
||||||
|
read -p "Press any key..."
|
||||||
ynh_clean_check_starting
|
ynh_clean_check_starting
|
||||||
}
|
}
|
||||||
# Exit if an error occurs during the execution of the script
|
# Exit if an error occurs during the execution of the script
|
||||||
|
@ -186,10 +187,8 @@ mkdir -p "$final_path/db"
|
||||||
chown -R "$app":"$app" "$final_path"
|
chown -R "$app":"$app" "$final_path"
|
||||||
pushd $final_path
|
pushd $final_path
|
||||||
ynh_use_nodejs
|
ynh_use_nodejs
|
||||||
sudo -u $app env PATH=$nodejs_path npm add hoek@^4.2.1 --save --production
|
sudo -u $app env PATH=$nodejs_path npm install --ignore-scripts
|
||||||
sudo -u $app env PATH=$nodejs_path npm install ts-node
|
sudo -u $app env PATH=$nodejs_path npm run build
|
||||||
sudo -u $app env PATH=$nodejs_path npm install --production
|
|
||||||
sudo -u $app env PATH=$nodejs_path npm audit fix
|
|
||||||
popd
|
popd
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Reference in a new issue