소스 검색

Merge pull request 'upgrade_script' (#31) from upgrade_script into main

Reviewed-on: https://codeberg.org/ChriChri/flohmarkt_ynh/pulls/31
Chris Vogel 1 년 전
부모
커밋
bf1ef25714
5개의 변경된 파일8개의 추가작업 그리고 7개의 파일을 삭제
  1. 0 1
      conf/flohmarkt.conf
  2. 1 1
      conf/systemd.service
  3. 3 3
      manifest.toml
  4. 2 2
      scripts/restore
  5. 2 0
      tests.toml

+ 0 - 1
conf/flohmarkt.conf

@@ -11,7 +11,6 @@ Server = http://__APP__:__PASSWORD_COUCHDB_FLOHMARKT__@127.0.0.1:__PORT_COUCHDB_
 [SMTP]
 Server = 127.0.0.1
 Port = 587
-# die From Adresse sollte in app_senders_login_maps landen...
 From = __MAIL_USER__@__MAIL_DOMAIN__
 User = __APP__
 Password = __MAIL_PWD__

+ 1 - 1
conf/systemd.service

@@ -8,7 +8,7 @@ User=__APP__
 Group=__APP__
 WorkingDirectory=__INSTALL_DIR__/__APP__
 Environment="VENV_DIR=__INSTALL_DIR__/venv/"
-ExecStart=__INSTALL_DIR__/venv/bin/uvicorn --host 127.0.0.1 --port __PORT__ --reload flohmarkt:app
+ExecStart=__INSTALL_DIR__/venv/bin/uvicorn --host 127.0.0.1 --port __PORT__ --reload flohmarkt.web:start
 StandardOutput=append:/var/log/__APP__/__APP__.log
 StandardError=inherit
 

+ 3 - 3
manifest.toml

@@ -6,7 +6,7 @@ id = "flohmarkt"
 name = "flohmarkt"
 description.en = "A decentral federated small ads platform"
 
-version = "0.0~ynh2"
+version = "0.0~ynh3"
 
 maintainers = ["Chris Vogel"]
 
@@ -109,8 +109,8 @@ ram.runtime = "100M"
     # This will pre-fetch the asset which can then be deployed during the install/upgrade scripts with :
     #    ynh_setup_source --dest_dir="$install_dir"
     # You can also define other assets than "main" and add --source_id="foobar" in the previous command
-    url = "https://codeberg.org/flohmarkt/flohmarkt/archive/0edd928adb76d72ecad2f768f25a8cc89f0c2eb1.tar.gz"
-    sha256 = "68978e04077d12c54f1b574c6da11c368c9da37f453e6768520deac88ea21855"
+    url = "https://codeberg.org/flohmarkt/flohmarkt/archive/4a3f243d090549c66ffece46222b0f1cc358e91e.tar.gz"
+    sha256 = "d59bb3bbbaf7c98d9f8bae46d9a2b2ccc407d674f51140a3d868a6afdf862e73"
 
     # These infos are used by https://github.com/YunoHost/apps/blob/master/tools/autoupdate_app_sources/autoupdate_app_sources.py
     # to auto-update the previous asset urls and sha256sum + manifest version

+ 2 - 2
scripts/restore

@@ -58,9 +58,9 @@ mkdir -p $data_dir
 ynh_script_progression --message="Restoring log directory and logfiles..." --weight=1
 ynh_restore_file --origin_path="/var/log/$app" --not_mandatory
 mkdir -p -m755 "/var/log/$app"
-touch "/var/log/$app/$app"
+touch "/var/log/$app/$app.log"
 # logfile contains possibly the secret setup URL
-chmod 640 "/var/log/$app/$app"
+chmod 640 "/var/log/$app/$app.log"
 
 # RESTORE FAIL2BAN CONFIGURATION
 ynh_script_progression --message="Restoring the Fail2Ban configuration..." --weight=2

+ 2 - 0
tests.toml

@@ -7,3 +7,5 @@ test_format = 1.0
     args.password_couchdb_admin = "TestPasswordCouchDBadmin"
     args.password_couchdb_flohmarkt = "TestPasswordCouchDBflohmarkt"
 
+    test_upgrade_from.9df93bc48e.name = "Upgrade from ynh2"
+