diff --git a/README.md b/README.md
index de53d65..12cd853 100644
--- a/README.md
+++ b/README.md
@@ -16,7 +16,6 @@ It shall NOT be edited by hand.
## Overview
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
@@ -25,7 +24,7 @@ A greatly enhanced fork of Misskey with better UI/UX, security, features, and mo
-**Shipped version:** 13.1.4.1~ynh1
+**Shipped version:** 14.0.0rc3~ynh1
**Demo:**
diff --git a/README_es.md b/README_es.md
index 104c12f..9aeec4e 100644
--- a/README_es.md
+++ b/README_es.md
@@ -16,7 +16,6 @@ No se debe editar a mano.
## Descripción general
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
@@ -25,7 +24,7 @@ A greatly enhanced fork of Misskey with better UI/UX, security, features, and mo
-**Versión actual:** 13.1.4.1~ynh1
+**Versión actual:** 14.0.0rc3~ynh1
**Demo:**
diff --git a/README_eu.md b/README_eu.md
index 7017fe9..610fa65 100644
--- a/README_eu.md
+++ b/README_eu.md
@@ -16,7 +16,6 @@ EZ editatu eskuz.
## Aurreikuspena
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
@@ -25,7 +24,7 @@ A greatly enhanced fork of Misskey with better UI/UX, security, features, and mo
-**Paketatutako bertsioa:** 13.1.4.1~ynh1
+**Paketatutako bertsioa:** 14.0.0rc3~ynh1
**Demoa:**
diff --git a/README_fr.md b/README_fr.md
index a2b604e..b13c3e3 100644
--- a/README_fr.md
+++ b/README_fr.md
@@ -23,7 +23,7 @@ Un fork grandement amélioré de Misskey avec une meilleure UI/UX, sécurité, f
Calckey ajoute de nombreux changements de qualité de vie et des corrections de bogues pour les utilisateurs et les administrateurs d'instance.
-**Version incluse :** 13.1.4.1~ynh1
+**Version incluse :** 14.0.0rc3~ynh1
**Démo :**
diff --git a/README_gl.md b/README_gl.md
index 8901e51..2bbd72c 100644
--- a/README_gl.md
+++ b/README_gl.md
@@ -16,7 +16,6 @@ NON debe editarse manualmente.
## Vista xeral
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
@@ -25,7 +24,7 @@ A greatly enhanced fork of Misskey with better UI/UX, security, features, and mo
-**Versión proporcionada:** 13.1.4.1~ynh1
+**Versión proporcionada:** 14.0.0rc3~ynh1
**Demo:**
diff --git a/README_id.md b/README_id.md
index 5ca9d6e..3cd6654 100644
--- a/README_id.md
+++ b/README_id.md
@@ -16,7 +16,6 @@ Ini TIDAK boleh diedit dengan tangan.
## Ringkasan
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
@@ -25,7 +24,7 @@ A greatly enhanced fork of Misskey with better UI/UX, security, features, and mo
-**Versi terkirim:** 13.1.4.1~ynh1
+**Versi terkirim:** 14.0.0rc3~ynh1
**Demo:**
diff --git a/README_zh_Hans.md b/README_zh_Hans.md
index 6ccf22b..f8712e6 100644
--- a/README_zh_Hans.md
+++ b/README_zh_Hans.md
@@ -16,7 +16,6 @@
## 概况
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
@@ -25,7 +24,7 @@ A greatly enhanced fork of Misskey with better UI/UX, security, features, and mo
-**分发版本:** 13.1.4.1~ynh1
+**分发版本:** 14.0.0rc3~ynh1
**演示:**
diff --git a/conf/nginx.conf b/conf/nginx.conf
index b62c14a..32ad407 100644
--- a/conf/nginx.conf
+++ b/conf/nginx.conf
@@ -1,7 +1,6 @@
#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
location __PATH__/ {
-
proxy_pass http://127.0.0.1:__PORT__;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md
index 77f8b46..484bcf7 100644
--- a/doc/DESCRIPTION.md
+++ b/doc/DESCRIPTION.md
@@ -1,4 +1,3 @@
-
A greatly enhanced fork of Misskey with better UI/UX, security, features, and more! https://i.calckey.cloud/
diff --git a/manifest.toml b/manifest.toml
index 4b8f167..6ef7440 100644
--- a/manifest.toml
+++ b/manifest.toml
@@ -3,9 +3,9 @@ packaging_format = 2
id = "calckey"
name = "Calckey"
description.en = "Fork of Misskey with better UI/UX, security, features"
-description.fr = "Un fork de Misskey avec une meilleure interface utilisateur, la sécurité, les fonctionnalités"
+description.fr = "Fork de Misskey avec une meilleure interface utilisateur, la sécurité, les fonctionnalités"
-version = "13.1.4.1~ynh1"
+version = "14.0.0rc3~ynh1"
maintainers = ["oufmilo"]
@@ -42,8 +42,8 @@ ram.runtime = "2G"
[resources]
[resources.sources.main]
- url = "https://git.joinfirefish.org/firefish/firefish/-/archive/v13.1.4.1/firefish-v13.1.4.1.tar.gz"
- sha256 = "658965f878fb0f5b22a6f29b5c63723f052a64f6b9bd8d9a3da93849231e3e62"
+ url = "https://git.joinfirefish.org/firefish/firefish/-/archive/v14.0.0-rc3/firefish-v14.0.0-rc3.tar.gz"
+ sha256 = "628c455a3f7bb5203ff98f3130c75ca168384379ddec20905b98b5e8c97ce285"
[resources.system_user]
@@ -56,7 +56,7 @@ ram.runtime = "2G"
main.default = 3020
[resources.apt]
- packages = "ffmpeg, postgresql, build-essential, redis-server"
+ packages = "ffmpeg, postgresql, build-essential, redis-server, curl"
[resources.database]
type = "postgresql"
diff --git a/scripts/backup b/scripts/backup
index 38dffda..3d820fa 100755
--- a/scripts/backup
+++ b/scripts/backup
@@ -10,7 +10,6 @@
source ../settings/scripts/_common.sh
source /usr/share/yunohost/helpers
-
#=================================================
# DECLARE DATA AND CONF FILES TO BACKUP
#=================================================
diff --git a/scripts/install b/scripts/install
index 999aec2..14110bf 100644
--- a/scripts/install
+++ b/scripts/install
@@ -9,10 +9,14 @@
source _common.sh
source /usr/share/yunohost/helpers
+# Configure redis
+redis_db=$(ynh_redis_get_free_db)
+ynh_app_setting_set --app="$app" --key=redis_db --value="$redis_db"
+
#=================================================
# INSTALL DEPENDENCIES
#=================================================
-ynh_script_progression --message="Installing dependencies... This might take some time." --weight=3
+ynh_script_progression --message="Installing Node..." --weight=3
ynh_install_nodejs --nodejs_version=$NODEJS_VERSION
@@ -24,30 +28,17 @@ ynh_script_progression --message="Setting up source files..." --weight=3
# Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$install_dir"
+chmod 750 "$install_dir"
+chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
-#=================================================
-# NGINX CONFIGURATION
-#=================================================
-ynh_script_progression --message="Configuring NGINX web server..." --weight=3
-
-# Create a dedicated NGINX config
-ynh_add_nginx_config
-
#=================================================
# ADD A CONFIGURATION
#=================================================
ynh_script_progression --message="Adding a configuration file..." --weight=1
-# Configure redis
-redis_db=$(ynh_redis_get_free_db)
-ynh_app_setting_set --app="$app" --key=redis_db --value="$redis_db"
+ynh_add_config --template="default.yml" --destination="$install_dir/.config/default.yml"
-ynh_add_config --template="../conf/default.yml" --destination="$install_dir/.config/default.yml"
-
-chmod 750 "$install_dir"
-chmod -R o-rwx "$install_dir"
-chown -R $app:www-data "$install_dir"
chmod 400 "$install_dir/.config/default.yml"
chown $app:$app "$install_dir/.config/default.yml"
@@ -57,12 +48,13 @@ chown $app:$app "$install_dir/.config/default.yml"
ynh_script_progression --message="Building app... This will take some time." --weight=15
pushd "$install_dir"
+ curl https://sh.rustup.rs -sSf | ynh_exec_warn_less ynh_exec_as $app sh -s -- -y
+ export PATH="$install_dir/.cargo/bin:$PATH"
ynh_use_nodejs
- corepack enable
- corepack prepare pnpm@latest --activate
- ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm install
- 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 run init
+ ynh_exec_warn_less env $ynh_node_load_PATH corepack enable && COREPACK_ENABLE_DOWNLOAD_PROMPT=0 corepack prepare pnpm@latest --activate
+ ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH corepack pnpm install
+ ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH NODE_ENV=production corepack pnpm build
+ ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH corepack pnpm run init
popd
#=================================================
@@ -70,23 +62,15 @@ popd
#=================================================
ynh_script_progression --message="Configuring a systemd service..." --weight=1
-env_path="$PATH"
+# Create a dedicated NGINX config
+ynh_add_nginx_config
+
# Create a dedicated systemd config
ynh_add_systemd_config
-#=================================================
-# SETUP LOGROTATE
-#=================================================
-ynh_script_progression --message="Configuring log rotation..." --weight=1
-
# Use logrotate to manage application logfile(s)
ynh_use_logrotate
-#=================================================
-# INTEGRATE SERVICE IN YUNOHOST
-#=================================================
-ynh_script_progression --message="Integrating service in YunoHost..." --weight=1
-
yunohost service add $app --description="A interplanetary blogging platform" --log="/var/log/$app/$app.log"
#=================================================
@@ -97,7 +81,6 @@ ynh_script_progression --message="Starting a systemd service..." --weight=1
# Start a systemd service
ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="All workers started"
-
#=================================================
# END OF SCRIPT
#=================================================
diff --git a/scripts/restore b/scripts/restore
index 381754c..081c792 100644
--- a/scripts/restore
+++ b/scripts/restore
@@ -10,15 +10,6 @@
source ../settings/scripts/_common.sh
source /usr/share/yunohost/helpers
-#=================================================
-# RESTORE THE APP MAIN DIR
-#=================================================
-ynh_script_progression --message="Restoring the app main directory..." --weight=1
-
-ynh_restore_file --origin_path="$install_dir"
-
-#=================================================
-# SPECIFIC RESTORATION
#=================================================
# REINSTALL DEPENDENCIES
#=================================================
@@ -28,42 +19,15 @@ ynh_script_progression --message="Reinstalling dependencies..." --weight=5
ynh_install_nodejs --nodejs_version=$NODEJS_VERSION
#=================================================
-# ADD A CONFIGURATION
+# RESTORE THE APP MAIN DIR
#=================================================
-ynh_script_progression --message="Adding a configuration file..." --weight=1
+ynh_script_progression --message="Restoring the app main directory..." --weight=1
-# Configure redis
-redis_db=$(ynh_redis_get_free_db)
-ynh_app_setting_set --app="$app" --key=redis_db --value="$redis_db"
-
-ynh_add_config --template="../conf/default.yml" --destination="$install_dir/.config/default.yml"
+ynh_restore_file --origin_path="$install_dir"
chmod 750 "$install_dir"
chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
-chmod 400 "$install_dir/.config/default.yml"
-chown $app:$app "$install_dir/.config/default.yml"
-
-#=================================================
-# REINSTALL PNPM
-#=================================================
-ynh_script_progression --message="Reinstalling pnpm..." --weight=1
-
-# Define and install pnpm
-pushd "$install_dir"
- ynh_use_nodejs
- corepack enable
- corepack prepare pnpm@latest --activate
- ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm install
- ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH NODE_ENV=production pnpm build
-popd
-
-#=================================================
-# RESTORE THE NGINX CONFIGURATION
-#=================================================
-ynh_script_progression --message="Restoring the NGINX web server configuration..."
-
-ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
#=================================================
# RESTORE THE POSTGRESQL DATABASE
@@ -72,34 +36,18 @@ ynh_script_progression --message="Restoring the PostgreSQL database..." --weight
ynh_psql_execute_file_as_root --file="./db.sql" --database=$db_name
-#=================================================
-# SECURE FILES AND DIRECTORIES
-#=================================================
-
-# Set permissions to app files
-chmod -R o-rwx "$install_dir"
-chown -R $app:www-data "$install_dir"
-
#=================================================
# RESTORE SYSTEMD
#=================================================
ynh_script_progression --message="Restoring the systemd configuration..." --weight=1
+ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
+
ynh_restore_file --origin_path="/etc/systemd/system/$app.service"
systemctl enable $app.service --quiet
-#=================================================
-# RESTORE THE LOGROTATE CONFIGURATION
-#=================================================
-ynh_script_progression --message="Restoring the logrotate configuration..." --weight=1
-
ynh_restore_file --origin_path="/etc/logrotate.d/$app"
-#=================================================
-# INTEGRATE SERVICE IN YUNOHOST
-#=================================================
-ynh_script_progression --message="Integrating service in YunoHost..." --weight=1
-
yunohost service add $app --description="A interplanetary blogging platform" --log="/var/log/$app/$app.log"
#=================================================
@@ -109,13 +57,6 @@ ynh_script_progression --message="Starting a systemd service..." --weight=1
ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --line_match="All workers started"
-#=================================================
-# GENERIC FINALIZATION
-#=================================================
-# RELOAD NGINX
-#=================================================
-ynh_script_progression --message="Reloading NGINX web server..." --weight=1
-
ynh_systemd_action --service_name=nginx --action=reload
#=================================================
diff --git a/scripts/upgrade b/scripts/upgrade
index 7430039..28b1a5a 100644
--- a/scripts/upgrade
+++ b/scripts/upgrade
@@ -9,18 +9,11 @@
source _common.sh
source /usr/share/yunohost/helpers
-#=================================================
-# CHECK VERSION
-#=================================================
-ynh_script_progression --message="Checking version..."
-
-upgrade_type=$(ynh_check_app_version_changed)
-
#=================================================
# ENSURE DOWNWARD COMPATIBILITY
#=================================================
-if ynh_compare_current_package_version --comparison lt --version 12.105.0~ynh1
+if ynh_compare_current_package_version --comparison lt --version 13.0.5~ynh1
then
ynh_die --message="Sorry, this version is not upgradable to the latest version :("
fi
@@ -31,7 +24,7 @@ fi
ynh_script_progression --message="Stopping a systemd service..." --weight=1
# Stop service before backup, to not loose message in case of failed upgrade and restore
-ynh_systemd_action --service_name=$app --action="stop" --log_path=systemd
+ynh_systemd_action --service_name=$app --action="stop" --log_path=systemd
#=================================================
# STANDARD UPGRADE STEPS
@@ -55,14 +48,10 @@ fi
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================
+ynh_script_progression --message="Upgrading source files..."
-if [ "$upgrade_type" == "UPGRADE_APP" ]
-then
- ynh_script_progression --message="Upgrading source files..."
-
- # Download, check integrity, uncompress and patch the source from app.src
- ynh_setup_source --dest_dir="$install_dir" --keep=".config/default.yml"
-fi
+# Download, check integrity, uncompress and patch the source from app.src
+ynh_setup_source --dest_dir="$install_dir" --keep=".config/default.yml"
chmod 750 "$install_dir"
chmod -R o-rwx "$install_dir"
@@ -79,26 +68,20 @@ ynh_install_nodejs --nodejs_version=$NODEJS_VERSION
ynh_script_progression --message="Removing old version dependency..."
ynh_secure_remove --file="$install_dir/.yarn"
-#=================================================
-# NGINX CONFIGURATION
-#=================================================
-ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=1
-
-# Create a dedicated NGINX config
-ynh_add_nginx_config
-
#=================================================
# BUILD APP
#=================================================
-ynh_script_progression --message="Building app..."
+ynh_script_progression --message="Installing rust and building app…"
pushd "$install_dir"
- corepack enable
- corepack prepare pnpm@latest --activate
- 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
- ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH NODE_ENV=production pnpm run build
- ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm run migrate
+ curl https://sh.rustup.rs -sSf | ynh_exec_warn_less ynh_exec_as $app sh -s -- -y
+ export PATH="$install_dir/.cargo/bin:$PATH"
+ ynh_use_nodejs
+ ynh_exec_warn_less env $ynh_node_load_PATH corepack enable && COREPACK_ENABLE_DOWNLOAD_PROMPT=0 corepack prepare pnpm@latest --activate
+ 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
+ ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH NODE_ENV=production pnpm run build
+ ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH pnpm run migrate
popd
#=================================================
@@ -106,24 +89,15 @@ popd
#=================================================
ynh_script_progression --message="Upgrading systemd configuration..." --weight=1
+# Create a dedicated NGINX config
+ynh_add_nginx_config
+
# Create a dedicated systemd config
ynh_add_systemd_config
-#=================================================
-# GENERIC FINALIZATION
-#=================================================
-# SETUP LOGROTATE
-#=================================================
-ynh_script_progression --message="Upgrading logrotate configuration..." --weight=1
-
# Use logrotate to manage app-specific logfile(s)
ynh_use_logrotate --non-append
-#=================================================
-# INTEGRATE SERVICE IN YUNOHOST
-#=================================================
-ynh_script_progression --message="Integrating service in YunoHost..." --weight=1
-
yunohost service add $app --description="A interplanetary blogging platform" --log="/var/log/$app/$app.log"
#=================================================
@@ -133,7 +107,6 @@ ynh_script_progression --message="Starting a systemd service..." --weight=1
ynh_systemd_action --service_name=$app --action="start" --log_path=systemd
-
#=================================================
# END OF SCRIPT
#=================================================
diff --git a/tests.toml b/tests.toml
index 71e7a74..4299b9c 100644
--- a/tests.toml
+++ b/tests.toml
@@ -14,4 +14,4 @@ test_format = 1.0
# Commits to test upgrade from
# -------------------------------
- test_upgrade_from.89f4f52.name = "Upgrade from 13.0.5"
+ test_upgrade_from.89f4f52.name = "13.1.4.1"