Class: Chef::Deployment::Monitor::MarkerFileSink

Inherits:
Sink
  • Object
show all
Defined in:
lib/chef_deployment_monitor/sinks.rb

Instance Method Summary collapse

Instance Method Details

#receive(data) ⇒ Object

will modify the marker file last write data of marker file will be within 5 seconds of last deployement



15
16
17
18
19
# File 'lib/chef_deployment_monitor/sinks.rb', line 15

def receive(data)
  File.open(Monitor::Config[:marker_file], 'w+') do |f|
    f.write(data.to_json)
  end
end