Pass env vars and volumes from the backup container to the backup process container
This commit is contained in:
parent
58b3220a2e
commit
15c91d5970
|
@ -34,20 +34,20 @@ def main():
|
|||
# TODO: Errors when repo already exists
|
||||
restic.init_repo(config.repository)
|
||||
|
||||
print(containers.this_container.environment)
|
||||
|
||||
print("Starting backup container..")
|
||||
backup_runner.run(
|
||||
image=containers.this_container.image,
|
||||
command='restic-volume-backup start-backup-process',
|
||||
volumes={},
|
||||
enviroment={},
|
||||
volumes=containers.this_container.volumes,
|
||||
enviroment=containers.this_container.environment,
|
||||
labels={"restic-volume-backup.backup_process": 'True'},
|
||||
)
|
||||
|
||||
# Separate command to avoid spawning infinite containers :)
|
||||
elif args.action == 'start-backup-process':
|
||||
print("start-backup-process")
|
||||
import os
|
||||
print(os.environ)
|
||||
|
||||
|
||||
def parse_args():
|
||||
|
|
Loading…
Reference in New Issue