* Extend confd test case to test for env var propagation
* Env vars set in conf.d files are expected to propagate
* Lock needs to be acquired when instantiating script
* Hoist control for exiting script a level up
* Do not accidentally nil out errors
* Log when running schedule
* Remove duplicate log line
* Warn on cron schedule that will never run
* Move cron scheduling inside application
* Make envvar a fallback and check for errors
* Panic significantly less
* propagate error out of runBackup
* Add structured logging
* FIx error propagation to exit
* Enable the new scheduler by default
* Review fixes
* Added docs and better error propagation
* Query for labeled services as well
* Try scaling down services
* Scale services back up
* Use progress tool from Docker CLI
* In test, label both services
* Clean up error and log messages
* Document scale-up/down approach in docs
* Downgrade Docker CLI to match client
* Document services stats
* Do not rely on PreviousSpec for storing desired replica count
* Log warnings from Docker when updating services
* Check whether container and service labels collide
* Document script behavior on label collision
* Add additional check if all containers have been removed
* Scale services concurrently
* Move docker interaction code into own file
* Factor out code for service updating
* Time out after five minutes of not reaching desired container count
* Inline handling of in-swarm container level restart
* Timer is more suitable for timeout race
* Timeout when scaling down services should be configurable
* Choose better filename
* Reflect changes in naming
* Rename and deprecate BACKUP_STOP_CONTAINER_LABEL
* Improve logging
* Further simplify logging
* Fix lint warnings and std lib deprecations
* Replace deprecated std lib with maintained drop-in replacement fork
Backwartds compatible with original package and suggested by std lib due to security and stability issues.
* OAuth2 is now a direct dependency due to Dropbox
* Undo change
* Revert "Replace deprecated std lib with maintained drop-in replacement fork"
This reverts commit 2887bd409f.
* Update channel handling
* Add linter for PRs
* Rename CI, fetch all issues, add govet
* Refactor label command mechanism to be more flexible
* Run all steps wrapped in labeled commands
* Rename methods to be in line with lifecycle
* Deprecate exec-pre and exec-post labels
* Add documentation
* Use type alias for lifecycle phases
* Fix bad imports
* Fix command lookup for deprecated labels
* Use more generic naming for lifecycle phase
* Fail on erroneous post command
* Update documentation
* Retry on lock being unavailable
* Refactor locking to return plain error
* Collect LockedTime in stats
* Add test case
* Add documentation for LOCK_TIMEOUT
* Log in case lock needs to be awaited
* Release resources created for awaiting lock
* Add option to run pre commands on arbitrary container
* Correctly handle quoted args in commands
* Provide defaults for test version arg
* Allow filtering of target containers
* Add documentation on exec commands
* Use mysqldump in exec test
* Add mysqldump section to recipes
* Also run commands test in swarm mode
* Use name instead of id
* Add syntax highlighting
* Add missing license headers
* Split code into multiple files
* Deduplicate logic for pruning backups against different storages
* Only parse templates when notifications are enabled
* Use better description
* add studio-b12/gowebdav to be able to upload to webdav server
* make sure all env variables are present for webdav upload
* implement file upload to WebDav server
directory defaults to the base directory
* docs: add the new feature to the documentation
* if no WebDav env variable are given throw no error
* docs: use more elegant english :D
Co-authored-by: Frederik Ring <frederik.ring@gmail.com>
* docs: use official spelling of "WebDAV"
* perf: golang likes to return early instead of having an else block
* use WEBDAV_PATH instead of WEBDAV_DIRECTORY
* use split_words for more convenience
like shown here: https://github.com/kelseyhightower/envconfig#struct-tag-support
* simplify
* feat: add pruning of files in WebDAV remote
Based on / Inspired by the minio/S3 implementation of pruning remote files.
* remove logging from the development
* test: first try implementing tests
Sandly I have to use the remote pipeline -- local wont work for me.
* test: adapt used volume names
* test: specify image only once!
* test: minio AND webdav data should be present
* test: backups on WebDAV remote are laying in the root directory
* test: the webdav server stores date in /var/lib/dav
* trying with data subfolder
* test: 1 container was added so the number raised from 3 to 4
* webdav subfolder is "data" not "backup"
* fix: password AND username must be defined
not password OR username
* improve logging
* feat: if the given path on the server isnt preset it will be created
* test: add creation of new folder for webdav to tests
Co-authored-by: Frederik Ring <frederik.ring@gmail.com>
* create a snapshot before creating tar archive
* safeguard snapshot removal and make snapshot optional
* fix typo, make sure remove snapshot failure triggers failure hook
Co-authored-by: Schwannden Kuo <schwannden@mobagel.com>
Previously, symlinks would be included in the set of candidates, but would
be skipped when pruning. This could lead to a wrong number of candidates
being printed in the log messages.