Created
June 10, 2018 11:50
-
-
Save ojhaujjwal/5de74ed06fa5bbace81468e8b73b02fc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "2" | |
services: | |
app-rsync: | |
volumes: | |
- appcode-rsync-sync:/var/www:nocopy # will be mounted on /var/www | |
# that the important thing | |
volumes: | |
appcode-rsync-sync: | |
external: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is our production compose file - not changed for docker-sync or similar | |
version: "2" | |
services: | |
app-rsync: | |
image: alpine | |
command: ['watch', '-n3', 'cat /var/www/index.html'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "2" | |
options: | |
verbose: true | |
syncs: | |
#IMPORTANT: ensure this name is unique and does not match your other application container name | |
appcode-rsync-sync: #tip: add -sync and you keep consistent names as a convention | |
src: './app/' | |
sync_host_ip: 'auto' | |
sync_host_port: 10872 | |
sync_strategy: 'rsync' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment