Commit graph

1549 commits

Author SHA1 Message Date
YunoHost Bot
7054f8a5bf Update from Weblate. (#340)
* Added translation using Weblate (Russian)
* [i18n] Translated using Weblate (Russian)

Currently translated at 2.4% (8 of 332 strings)
2017-08-07 18:23:53 +02:00
Alexandre Aubin
d6d4717bb2 [fix] Tests were broken from recent changes about m18n 2017-08-07 12:16:31 -04:00
Laurent Peuch
a441f37454 Migration framework (#195)
* [enh] list migrations
* [enh] first version of the migrate command
* [mod] add todo comment
* [mod] migrate command shouldn't return anything
* [mod] rename yunohost_migrations to data_migrations
* [mod] better regex
* [enh] had base class for migration
* [fix] inverted condition
* [enh] save last runned migration
* [enh] add migrations state command
* [mod] add todo comments
* [mod] error handling
* [mod] DRY
* [doc] more comment
* [enh] handle exceptions on migration
* [mod] error handling
* [mod] DRY
* [enh] error handling
* [mod] this is done earlier
* [doc] docstring
* [enh] handle fail to load migration case
* [doc] add TODO Comment
* [fix] typos, thx ju
* [enh] add a migration to remove archivemount (as an example)
* [fix] check_call is boring
* [enh] support forward/backward migrations
* [mod] I don't need auth
* [fix] apt is expecting input...
* [mod] save it as int
* [mod] add some logging
* [doc] update todo
* [fix] I also need to run backward latest runed migration
* [enh] add target cli argument
* [enh] fake migration
* [enh] uniformly convert to int at the same place
* [fix] we need to filename now
* [enh] validate input
* [enh] handle 0 special case
* [mod] rename fake to skip
* [mod] s/runed/run/g
* [doc] anglich typo in comments
* [mod] more explicit error message
* [mod] more typo
* [doc] put comment in the right place
* [mod] typo
* [fix] forgot to cape migrations by target
* [fix] typo
* [mod] uses moulinette helpers
* [enh] launch migrations during package upgrade
* [mod] remove unused import
* [mod] sort translation keys
* [enh] i18n
* [fix] missing __init__.py in data_migrations
* [mod] move to a subcategory
* Typo / caps / consistency
* [fix] forgot that migrations is now in tools, in postinst
* Skip migrations during postinstall
* Remove archivemount example migration
It relied on apt-get, which can't be used during 'postinst' debian scripts because we're already inside a apt
* Add migration for cert group from 'metronome' to 'ssl-cert'
2017-08-07 15:55:18 +02:00
e-lie
36770b0eda [fix] No default backup method (redmine 968) (#339) 2017-08-07 15:30:25 +02:00
opi
535f36b1c1 [fix] Properly catch Invalid manifest json with ValueError. (#324)
* [fix] Properly catch Invalid manifest json with ValueError.
* [fix] display detailed error in every case for invalid manifest
2017-08-07 15:29:53 +02:00
Laurent Peuch
3235f5f3fe [mod] autopep8 2017-08-07 06:58:29 +02:00
Alexandre Aubin
88a6c3d83a Missing parenthesis in helper :| 2017-08-06 02:37:17 +02:00
Laurent Peuch
99292e32d1 Merge pull request #336 from YunoHost/unglobify_some_globals
[mod] explicitely import previously globals magic variables
2017-08-05 12:24:50 +02:00
anmol26s
7d5779fcab [enh] Check that user is legitimate to use an email adress when sending mail (#330) 2017-08-05 12:11:53 +02:00
Maniack Crudelis
f4fabe1edb Fix syntax error: unexpected end of file (#337) 2017-08-02 18:44:32 +02:00
Maniack Crudelis
8f173543bb Fix syntax error: unexpected end of file (#338) 2017-08-02 18:44:16 +02:00
Alexandre Aubin
3a777ccbc7 [microdecision] Renaming ynh_backup_after_failed_upgrade to ynh_restore_upgradebackup 2017-07-28 14:22:04 -04:00
Maniack Crudelis
a006868cbe New helpers ynh_add_systemd_config and ynh_remove_systemd_config (#287)
* New helpers ynh_add_systemd_config and ynh_remove_systemd_config
Standard file for systemd service.
* ynh_subsistute_char was renamed ynh_replace_string
* Upgrade helpers
* Add some description of which keywords are replaced by which variable
2017-07-28 19:21:22 +02:00
Maniack Crudelis
80242a8edc New helpers ynh_add_nginx_config and ynh_remove_nginx_config (#285)
* New helpers ynh_add_nginx_config and ynh_remove_nginx_config
Standard configuration of nginx
Use local files stored in conf/, so it's still possible to use a specific config
* ynh_substitute_char was renamed ynh_replace_string
* ynh_compare_checksum_config -> ynh_backup_if_checksum_is_different
* Upgrade helpers
* Add some description of which keywords are replaced by which variable
2017-07-28 19:11:28 +02:00
Maniack Crudelis
bf45cd7c4b New helpers ynh_backup_after_failed_upgrade and ynh_backup_before_upg… (#289)
* New helpers ynh_backup_after_failed_upgrade and ynh_backup_before_upgrade
Create a backup at the beginning of upgrade script.
Then, if the upgrade script failed, remove the app and restore it.
The backup is kept, to provide a way to restore if the upgrade is finally a bad thing.
* Implement @JimboJoe's comments
* Indentation
* --ignore-hooks -> --ignore-system
2017-07-28 18:53:43 +02:00
Alexandre Aubin
59c918bbfa Merge branch 'testing' into unstable 2017-07-26 11:58:22 -04:00
Alexandre Aubin
91bfd5e266 Update changelog for 2.6.5 release 2017-07-26 11:57:12 -04:00
Alexandre Aubin
2c67d062c6 [fix] Do not crash if archivemount is not there (#325) 2017-07-26 11:55:02 -04:00
Laurent Peuch
46cb9637b2 [fix] missing m18n import 2017-07-26 05:43:08 +02:00
Laurent Peuch
baf0d098f5 [mod] explicitely import previously globals magic variables 2017-07-25 21:32:20 +02:00
Alexandre Aubin
a513d0ecbe [enh] Check that url is available and normalize path before app install (#304) 2017-07-24 20:11:58 +02:00
Maniack Crudelis
390835e96a [fix] Logrotate append (#328)
* [fix] Logrotate append
* Typo fix by JimboJoe
2017-07-24 02:50:48 +02:00
Alexandre Aubin
3afbf0f7b9 [fix] Depreciation warning for --hooks was always shown (#333) 2017-07-23 01:56:05 +02:00
Laurent Peuch
c5098cd90e Merge pull request #308 from YunoHost/test_m18n_keys_usage
[enh] Add a script to test m18n keys usage
2017-07-23 01:53:48 +02:00
Alexandre Aubin
84153f6390 [mod] Microdecision to go with Moulinette#141 2017-07-21 13:23:32 -04:00
Alexandre Aubin
c96d5f90ec Don't verify SSL during changeurl tests :/ (#332) 2017-07-21 00:45:05 +02:00
Alexandre Aubin
89189ed52f [fix] Refactor DNS conf management for domains (#299)
* Add an helper that build a dict describing the dns conf
* Synchronize the dyndns dns conf with the one from domain.py
* [mod] try to make code more lisible
* [mod] try to make code a bit more lisible
* [mod/fix] try to simplify and clean the code (and remove what looks like a debug return)
* [fix] First delete records, then add the new records
2017-07-21 00:28:37 +02:00
JimboJoe
baf1d44c1f Run change_url scripts as root as a matter of homogeneity (#329) 2017-07-17 20:39:39 +02:00
Laurent Peuch
f3a247442f Merge pull request #321 from YunoHost/helper_autopurge
[enh] New helper autopurge
2017-07-17 03:47:22 +02:00
ljf (zamentur)
20f4a39bf0 [fix] Errors in backup custom methods (#326) 2017-07-13 19:36:31 +02:00
YunoHost Bot
7be85b2e62 Update from Weblate. (#327)
* [i18n] Translated using Weblate (Spanish)
Currently translated at 97.9% (281 of 287 strings)
* [i18n] Translated using Weblate (German)
Currently translated at 96.8% (278 of 287 strings)
* [i18n] Translated using Weblate (French)
Currently translated at 100.0% (301 of 301 strings)
* [i18n] Translated using Weblate (French)
Currently translated at 100.0% (332 of 332 strings)
* [i18n] Translated using Weblate (German)
Currently translated at 83.4% (277 of 332 strings)
* [i18n] Translated using Weblate (German)
Currently translated at 87.6% (291 of 332 strings)
* [i18n] Translated using Weblate (German)
Currently translated at 87.6% (291 of 332 strings)
* [i18n] Translated using Weblate (French)
Currently translated at 95.3% (287 of 301 strings)
2017-07-10 18:24:53 +02:00
Maniack Crudelis
9782f05887 New helpers ynh_add_fpm_config and ynh_remove_fpm_config (#284)
* New helpers ynh_add_fpm_config and ynh_remove_fpm_config
Standard configuration of php-fpm.
Use local files stored in conf/, so it's still possible to use a specific config
* ynh_substitute_char was renamed to ynh_replace_string
* Update checksum command and quiet the second secure_remove
* Fix helpers name
2017-07-10 17:48:32 +02:00
Alexandre Aubin
f0c9e697fe [fix] Do not crash if archivemount is not there (#325) 2017-07-10 17:45:34 +02:00
ljf
9bbdaac58b Update changelog for 2.6.4 release 2017-06-21 17:34:41 -04:00
YunoHost Bot
a8eac8ac42 Update from Weblate. (#323)
* [i18n] Translated using Weblate (Spanish)
* [i18n] Translated using Weblate (German)
* [i18n] Translated using Weblate (French)
2017-06-21 21:32:18 +02:00
Alexandre Aubin
d9761aad7b [fix] Move archivemount to suggested dependency (#322) 2017-06-21 21:04:25 +02:00
Maniack Crudelis
3320aee86e [enh] New helper autopurge
Add an autoremove with purge.
Some deb packages, like transmission let a lot of shit behind itself.
In case of remove then install, transmission doesn't work anymore.
2017-06-17 19:22:10 +02:00
Maniack Crudelis
a01f7ffd2b [Fix] Forgot an asterisk in logrotate helper (#320) 2017-06-13 22:18:48 +02:00
Maniack Crudelis
edcabddb63 [enh] Do not change the db_pwd (#319)
* [enh] Do not change the db_pwd
For restore script, do not change the password.
Keep the primary password and recreate a new database with it.
* A small comment ;)
Thanks, opi, sometimes I forget that's not so obvious.
And I don't want to someone has to search through internet to understand a helper.
2017-06-12 17:03:40 +02:00
Alexandre Aubin
6042e71003 [fix] Don't attempt to change hostname in LXC (#301)
* Don't attempt to change hostname in LXC
* Detect any kind of container, not just lxc
2017-06-12 16:58:22 +02:00
Maniack Crudelis
de3a0b4f69 [fix] ynh_install_app_dependencies uses grep instead of python (#313)
Proposition to discuss
2017-06-09 00:46:36 +02:00
opi
5e4cce3f1f [fix] Do not break if disk is not a dict (fixes #redmine-919) (#315) 2017-06-07 11:53:45 +02:00
Alexandre Aubin
a687b85025 Update changelog for 2.6.3 release 2017-06-02 09:58:18 -04:00
YunoHost Bot
8948694610 Update from Weblate. (#318)
* [i18n] Translated using Weblate (Spanish)
Currently translated at 97.9% (281 of 287 strings)

* [i18n] Translated using Weblate (German)
Currently translated at 96.8% (278 of 287 strings)

* [i18n] Translated using Weblate (French)
Currently translated at 95.3% (287 of 301 strings)

* [i18n] Translated using Weblate (French)
Currently translated at 100.0% (301 of 301 strings)
2017-06-02 14:55:06 +02:00
ljf (zamentur)
d3eeb4bbc7 [enh] Refactor backup management to pave the way to borg (#275)
* [enh] Use a csv to list file to backup
* [enh] Use csv python module
* [wip] Backup refactoring
* [wip] Backup class refactoring
* [enh] Add archivemount dependencies
* [wip] Restore refactoring
* [fix] Some error in this refactoring
* [fix] Missing backup key translation
* [fix] Bad YNH_CWD in hook backup
* [fix] App backup part was broken
* [fix] Restore operation was broken
* [fix] No compressed backup
* [fix] Don't commit backup path into csv if app backup fail
* [fix] Default backup collect_dir should be in tmp subdir
* [enh] Simplify a copy code
* [enh] Build backup info from properties
* [enh] Improve comments presentation
* Adding first tests for backup/restore
* Adding more backup/restore app test scenario
* [enh] Separate BackupMethods in distinct class
* Adding test of restoring a wordpress archive from 2.4
* [fix] Be able to delete backup link too
* [fix] Bad internationalization key
* [fix] Edge case with empty mysql pwd restore
* [fix] Unset var in restore
* [fix] Edge case with empty mysql pwd restore
* Adding test for backup crash handling
* Cleaning tests + checking tmp dir is empty
* [fix] Missing tmp in backup path
* [fix] Error on reading backup csv
* Adding test of failed restore
* Adding tests when not enough space available
* Simplifying tests using markers
* [fix] ynh backup/restore helpers with only one arg
* [fix] Unmount subdir with python
* [enh] Improve backup size management
* [fix] None object in backup
* [enh] Remove dead code
* [fix] Missing locales
* [enh] Adapat test about needed space
* [fix] Pass some test
* [enh] Remove dead code
* [enh] Pass all test
* [enh] Adding test that backups contains what's expected
* Fix typo in tests
* [fix] Bad documentation
* [enh] Add comment
* [enh] Use len in place of implicit {} == False
* [enh] Add comment
* [enh] Add comment
* [enh] Refactoring on _collect_app_files
* Adding skeleton for remaining tests to write
* [enh] Use a csv to list file to backup
* [enh] Use csv python module
* [wip] Backup refactoring
* [wip] Backup class refactoring
* [enh] Add archivemount dependencies
* [wip] Restore refactoring
* [fix] Some error in this refactoring
* [fix] Missing backup key translation
* [fix] Bad YNH_CWD in hook backup
* [fix] App backup part was broken
* [fix] Restore operation was broken
* [fix] No compressed backup
* [fix] Don't commit backup path into csv if app backup fail
* [fix] Default backup collect_dir should be in tmp subdir
* [enh] Simplify a copy code
* [enh] Build backup info from properties
* [enh] Improve comments presentation
* Adding first tests for backup/restore
* Adding more backup/restore app test scenario
* [enh] Separate BackupMethods in distinct class
* Adding test of restoring a wordpress archive from 2.4
* [fix] Be able to delete backup link too
* [fix] Bad internationalization key
* [fix] Edge case with empty mysql pwd restore
* [fix] Unset var in restore
* [fix] Edge case with empty mysql pwd restore
* Adding test for backup crash handling
* Cleaning tests + checking tmp dir is empty
* [fix] Missing tmp in backup path
* [fix] Error on reading backup csv
* Adding test of failed restore
* Adding tests when not enough space available
* Simplifying tests using markers
* [fix] ynh backup/restore helpers with only one arg
* [fix] Unmount subdir with python
* [enh] Improve backup size management
* [fix] None object in backup
* [enh] Remove dead code
* [fix] Missing locales
* [enh] Adapat test about needed space
* [fix] Pass some test
* [enh] Remove dead code
* [enh] Pass all test
* [enh] Adding test that backups contains what's expected
* Fix typo in tests
* [fix] Bad documentation
* Adding skeleton for remaining tests to write
* [enh] Add comment
* [enh] Use len in place of implicit {} == False
* [enh] Add comment
* [enh] Add comment
* [enh] Refactoring on _collect_app_files
* [fix] Replay e1a507 deleted by rebase
* [fix] ynh_restore helper
* Renaming 'hooks' terminology to 'system' where it makes sense
* Propagating new --system/--ignore-system to actionmap
* Adding more tests + clarifying some functions and messages
* Factorize out the definition and validation of backup/restore targets
* Add missing key
* Use list comprehension instead of dirty loops
* [enh] Add docstring in BackupManager
* [enh] Add docstring on BackupMethod(s)
* [fix] Remove deadcode
* [fix] Remove debug message
* [enh] Add comments on RestoreManager
* [enh] Add comments on backup constants
* Adding a proper report/result for each backup target
* Skipping tests not implemented yet
* Fixing little mistake from merging
* [fix] Support different fs or archivemount error
* [enh] Backup helpers readability
* [fix] Copy backup method
* [fix] Deprecated warning always displayed
* [enh] Retrieve info.json file inside tar.gz
* Trying to reorganize methods with sections for readability
* [enh] Support archivemount failure
* [fix] Missing env var for system part restore helpers
* Clarifying disk usage / free space computation
* [enh] Refactoring around backup set_targets()
* Clarifying structure of backup_create and backup_restore
* Move RestoreManager between BackupManager and BackupMethods
* [fix] Missing locales
* [fix] System part restore if archivemount failure
* [enh] Extract all conf instead of specific code
* [fix] Other output directory (compressed archive)
* [enh] Add test for uncompressed backup
* [fix] Compressed backup in an existing output directory
* [fix] Return size for retro-compatibility
* [fix] Mountpoint check aborting script when called with -eu
* [fix] Avoid failure test with set -eu
* [fix] locale strings missing/bad arguments
* Check free space before mount
* [fix] ynh_restore_helpers with existing archive path
* Adding skeletons for moar tests
* Fixing some weird bug in _get_archive_path
* Adding a regen-conf at the end of system restore
* Adding tests of system restore from 2.4
* Have a class dedicated to target management
* Cleaning tests
* Misc formatting
* More meaningful variable names inside app restore
* [fix] can't call source ../settings/scripts/_common.sh in app backup
* [fix] ynh_install_app_dependencies is not compatible with readonly mount
* [fix] Remove temporary file
2017-06-02 13:41:16 +02:00
Alexandre Aubin
2de7e3301b [fix] Typo in applist migration (#317) 2017-06-01 18:14:39 +02:00
Jean-Baptiste
64ab4a82b3 [fix] Yypos in en.json (#314)
* serialzed => serialized
* typo close global_settings_key_doesnt_exists
* serialized/serialize & setings/settings
2017-05-31 17:06:40 +02:00
Alexandre Aubin
7102bf1b0e [fix] Missing change from metronome to ssl-cert (#316) 2017-05-31 16:09:39 +02:00
opi
6371ab4a57 [enh] Increase message size. #914 (#307) 2017-05-24 08:42:16 +02:00
Alexandre Aubin
7af130d81b Allow regen-conf to manage new files already when they're already present on the system (#311) 2017-05-22 15:24:47 +02:00