parent
34ed31e3aa
commit
a6b8990f4b
1 changed files with 8 additions and 7 deletions
|
@ -56,19 +56,20 @@ def cd_list_environment():
|
|||
|
||||
|
||||
def cd_synchronize():
|
||||
sync_host = 'rwx.work'
|
||||
sync_source = 'out'
|
||||
sync_user = 'cd'
|
||||
host = 'rwx.work'
|
||||
source = 'out'
|
||||
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',
|
||||
'--archive',
|
||||
'--delete-before',
|
||||
'--verbose',
|
||||
f'{sync_source}/',
|
||||
f'{sync_target}/',
|
||||
f'{source}/',
|
||||
f'{target}/',
|
||||
'--dry-run',
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue