Sha256: 7d181bbbe36e2e59690ca2f5e1614ea451ddb1d3743e9ca96b55980d4aeeda62
Contents?: true
Size: 887 Bytes
Versions: 102
Compression:
Stored size: 887 Bytes
Contents
require 'appsignal/integrations/capistrano/careful_logger' module Appsignal class Marker include Appsignal::CarefulLogger attr_reader :marker_data, :config, :logger ACTION = 'markers' def initialize(marker_data, config, logger) @marker_data = marker_data @config = config @logger = logger end def transmit transmitter = Transmitter.new(ACTION, config) logger.info("Notifying Appsignal of deploy with: revision: #{marker_data[:revision]}, user: #{marker_data[:user]}") result = transmitter.transmit(marker_data) if result == '200' logger.info('Appsignal has been notified of this deploy!') else raise "#{result} at #{transmitter.uri}" end rescue Exception => e carefully_log_error( "Something went wrong while trying to notify Appsignal: #{e}" ) end end end
Version data entries
102 entries across 102 versions & 1 rubygems