forked from coop-cloud/backup-bot-two
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 79cdec6705 | |||
| 2bc9400807 | |||
| 9b141a5185 | |||
| 6ff2312090 |
@@ -213,3 +213,15 @@ cd /usr/bin/
|
||||
python
|
||||
from backupbot import *
|
||||
```
|
||||
|
||||
### Versioning
|
||||
|
||||
- App version: changes to `backup.py` (build a new image)
|
||||
- Co-op Cloud package version: changes to recipe.
|
||||
|
||||
For example, starting with 1.0.0+2.0.0:
|
||||
"patch" change to recipe: 1.0.1+2.0.0
|
||||
"patch" change to backup.py: increment both, so 1.1.0+2.0.1
|
||||
because bumping the image version would result in a minor recipe release
|
||||
|
||||
https://git.coopcloud.tech/coop-cloud/backup-bot-two/issues/4
|
||||
|
||||
+5
-4
@@ -126,10 +126,11 @@ def restore(snapshot, target, noninteractive, volumes, container, no_commands):
|
||||
print(f"Snapshot to restore: \t{snapshot}")
|
||||
restore_app_versions = app_versions_from_tags(snapshots[0].get('tags'))
|
||||
print("Apps:")
|
||||
for app, version in restore_app_versions.items():
|
||||
print(f"\t{app} \t {version}")
|
||||
if apps_versions.get(app) != version:
|
||||
print(f"WARNING!!! The running app is deployed with version {apps_versions.get(app)}")
|
||||
for app, version in apps_versions.items():
|
||||
restore_version = restore_app_versions.get(app)
|
||||
print(f"\t{app} \t {restore_version}")
|
||||
if version != restore_version:
|
||||
print(f"WARNING!!! The running app is deployed with version {version}")
|
||||
print("The following volume paths will be restored:")
|
||||
for p in backup_paths:
|
||||
print(f'\t{p}')
|
||||
|
||||
+2
-2
@@ -2,7 +2,7 @@
|
||||
version: "3.8"
|
||||
services:
|
||||
app:
|
||||
image: git.coopcloud.tech/coop-cloud/backup-bot-two:2.2.0-beta
|
||||
image: git.coopcloud.tech/coop-cloud/backup-bot-two:2.2.1-beta
|
||||
volumes:
|
||||
- "/var/run/docker.sock:/var/run/docker.sock"
|
||||
- "/var/lib/docker/volumes/:/var/lib/docker/volumes/"
|
||||
@@ -16,7 +16,7 @@ services:
|
||||
- restic_password
|
||||
deploy:
|
||||
labels:
|
||||
- coop-cloud.${STACK_NAME}.version=2.1.0+2.2.0-beta
|
||||
- coop-cloud.${STACK_NAME}.version=2.2.0+2.2.1-beta
|
||||
- coop-cloud.${STACK_NAME}.timeout=${TIMEOUT:-300}
|
||||
- coop-cloud.backupbot.enabled=true
|
||||
#entrypoint: ['tail', '-f','/dev/null']
|
||||
|
||||
Reference in New Issue
Block a user