|
|
@ -0,0 +1,10 @@ |
|
|
|
#!/bin/bash |
|
|
|
CAPTAIN_SERVER=cap.server |
|
|
|
CAPTAIN_DESTINATION_S3_SERVICE=site-files |
|
|
|
CAPTAIN_SOURCE_WORDPRESS_SERVICE=site |
|
|
|
BUCKET=media |
|
|
|
|
|
|
|
SRC="/var/lib/docker/volumes/captain--${CAPTAIN_SOURCE_WORDPRESS_SERVICE}-wp-data/_data/wp-content/uploads/" |
|
|
|
DESTINATION="/var/lib/docker/volumes/captain--${CAPTAIN_DESTINATION_S3_SERVICE}-db-data/_data/${BUCKET}/" |
|
|
|
|
|
|
|
ssh root@$CAPTAIN_SERVER "rsync -a --info=progress2 ${SRC} ${DESTINATION}" |