1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/misskey_ynh.git synced 2024-09-03 19:46:03 +02:00
This commit is contained in:
Éric Gaspar 2023-09-11 10:07:13 +02:00
parent 478f89bcbc
commit ae9c9af0e0
2 changed files with 13 additions and 8 deletions

View file

@ -53,9 +53,5 @@ ram.runtime = "50M"
[resources.apt]
packages ="ffmpeg, postgresql"
extras.yarn.repo = "deb https://dl.yarnpkg.com/debian/ stable main"
extras.yarn.key = "https://dl.yarnpkg.com/debian/pubkey.gpg"
extras.yarn.packages = "yarn"
[resources.database]
type = "postgresql"

View file

@ -23,6 +23,15 @@ ynh_script_progression --message="Stopping a systemd service..." --weight=1
# Stop bservice before backup, to not loose message in case of failed upgrade and restore
ynh_systemd_action --service_name=$app --action="stop" --log_path=systemd --line_match="Stopped"
#=================================================
# ENSURE DOWNWARD COMPATIBILITY
#=================================================
if ynh_compare_current_package_version --comparison lt --version 12.109.2~ynh1
then
ynh_die --message="Sorry, this version is not upgradable to the latest version :("
fi
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================
@ -60,10 +69,10 @@ ynh_script_progression --message="Building app..."
pushd "$install_dir"
ynh_use_nodejs
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH yarn cleanall
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH yarn install
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH NODE_ENV=production yarn build
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH yarn migrate
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm clean-all
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm install --frozen-lockfile
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH NODE_ENV=production pnpm build
ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm migrate
popd
#=================================================