File tree Expand file tree Collapse file tree 1 file changed +12
-7
lines changed Expand file tree Collapse file tree 1 file changed +12
-7
lines changed Original file line number Diff line number Diff line change @@ -96,18 +96,23 @@ def rsync_exclude
9696## Tiggers
9797def triggers(config, mount, hostName, hostDirectory)
9898 if mount == 'rsync'
99+ rsync_back = false;
99100 config.trigger.after :up, :reload, :provision do |trigger|
101+ # Run rsync back
102+ trigger.ruby do |env,machine|
103+ if !File.exist?("#{ hostDirectory } /app/etc/di.xml");
104+ rsync_back = true;
105+ end
106+ end
100107 # Add post-up message
101108 trigger.info = config.vm.post_up_message
102- trigger.info+= '>>> Do not close this terminal: open new one for ssh login
103- ---------------------------------------------------------'
104- # Run rsync-auto
105- if !File.file?("#{ hostDirectory } /app/etc/di.xml")
106- trigger.info+= "\r \n rsync-back and rsync auto triggered..."
107- trigger.info+="\r \n Duration: ~5min. Once installation is complete please run 'vagrant reload'"
109+ trigger.info+= '---------------------------------------------------------'
110+ if rsync_back;
111+ trigger.warn = "\r \n Rsync-back duration: ~10min. Once rsync-back is complete, run 'vagrant reload'"
108112 trigger.run = {inline: "vagrant rsync-back #{ hostName } "}
109113 else
110- trigger.info+= "\r \n rsync-auto is running..."
114+ # Run rsync auto
115+ trigger.warn = "\r \n Rsync-auto is running... Do not close this terminal."
111116 trigger.run = {inline: "vagrant rsync-auto --rsync-chown #{ hostName } "}
112117 end
113118 end
You can’t perform that action at this time.
0 commit comments