This repository has been archived by the owner on Mar 11, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-sync.yml
69 lines (52 loc) · 3.74 KB
/
docker-sync.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
options:
# optional, activate this if you need to debug something, default is false
# IMPORTANT: do not run stable with this, it creates a memory leak, turn of verbose when you are done testing
verbose: false
syncs:
# IMPORTANT: this name must be unique and should NOT match your real application container name!
buywithme-sync:
# enable terminal_notifier. On every sync sends a Terminal Notification regarding files being synced. ( Mac Only ).
# good thing in case you are developing and want to know exactly when your changes took effect.
# be aware in case of unison this only gives you a notification on the initial sync, not the syncs after changes.
notify_terminal: true
# which folder to watch / sync from - you can use tilde (~), it will get expanded. Be aware that the trailing slash makes a difference
# if you add them, only the inner parts of the folder gets synced, otherwise the parent folder will be synced as top-level folder
src: './'
# which destination on the sync-container. Since you will use volumes_from to mount this, this should match your code-deployment location in the real container
dest: '/var/www/html'
# when a port of a container is exposed, on which IP does it get exposed. Localhost for docker for mac, something else for docker-machine
sync_host_ip: '127.0.0.1'
# should be a unique port this sync instance uses on the host to offer the rsync service on
sync_host_port: 10871
# optional, a list of excludes for rsync - see rsync docs for details
#sync_excludes: ['Gemfile.lock', 'Gemfile', 'config.rb', '.sass-cache/', 'sass/', 'sass-cache/', 'composer.json' , 'bower.json', 'package.json', 'Gruntfile*', 'bower_components/', 'node_modules/', '.gitignore', '.git/', '*.coffee', '*.scss', '*.sass']
sync_excludes: ['var/cache/', '.idea/', '.git/']
# use this to change the exclude syntax.
# Path: you match the exact path ( nesting problem )
# Name: If a file or a folder does match this string ( solves nesting problem )
# Regex: Define a regular expression
# none: You can define a type for each sync exclude, so sync_excludes: ['Name .git', 'Path Gemlock']
#
# for more see http://www.cis.upenn.edu/~bcpierce/unison/download/releases/stable/unison-manual.html#pathspec
sync_excludes_type: 'Path'
# optional: use this to switch to rsync verbose mode
#sync_args: '-av --copy-links --hard-links'
sync_args: '-debug all'
# optional, a list of regular expressions to exclude from the fswatch - see fswatch docs for details
# optional, default can be either rsync or unison See Strategies in the wiki for explanation
sync_strategy: 'unison'
# optional, use this to map the files to a specific user on sync. Helps fixing permissions. You can use names and uids
#sync_user: 'root'
# this does not user groupmap but rather configures the server to map
# optional: usually if you map users you want to set the user id of your application container here
# sync_userid: '5000'
# optional, use this to map the files to a specific group on sync. Helps fixing permissions, You can use names and guids
#sync_group: 'root'
# optional: usually if you map groups you want to set the group id of your application container here
# this does not user groupmap but rather configures the server to map
# sync_groupid: '6000'
watch_excludes: ['.*/.git', '.*/node_modules', '.*/bower_components', '.*/sass-cache', '.*/.sass-cache', '.*/.sass-cache', '.coffee', '.scss', '.sass', '.gitignore']
# optional: use this to switch to fswatch verbose mode
watch_args: '-v'
# optional: default is fswatch, if set to disable, no watcher will be used and you would need to start the sync manually
watch_strategy: 'fswatch'