parent
34ed31e3aa
commit
a6b8990f4b
1 changed files with 8 additions and 7 deletions
|
@ -56,19 +56,20 @@ def cd_list_environment():
|
||||||
|
|
||||||
|
|
||||||
def cd_synchronize():
|
def cd_synchronize():
|
||||||
sync_host = 'rwx.work'
|
host = 'rwx.work'
|
||||||
sync_source = 'out'
|
source = 'out'
|
||||||
sync_user = 'cd'
|
user = 'cd'
|
||||||
#
|
#
|
||||||
sync_root = f'/{sync_user}/{project.branch}/{project.name}'
|
root = os.sep.join([str(),
|
||||||
|
user, project.branch, projects.group, project.name])
|
||||||
#
|
#
|
||||||
sync_target = f'{sync_user}@{sync_host}:{sync_root}'
|
target = f'{user}@{host}:{root}'
|
||||||
ps.run('rsync',
|
ps.run('rsync',
|
||||||
'--archive',
|
'--archive',
|
||||||
'--delete-before',
|
'--delete-before',
|
||||||
'--verbose',
|
'--verbose',
|
||||||
f'{sync_source}/',
|
f'{source}/',
|
||||||
f'{sync_target}/',
|
f'{target}/',
|
||||||
'--dry-run',
|
'--dry-run',
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue