Sha256: b25f44c4e7b68e4cfdde02bf67445cd95591cd23dc25f2b7161e7afb363e3a47

Contents?: true

Size: 757 Bytes

Versions: 6

Compression:

Stored size: 757 Bytes

Contents

namespace :appsignal do
  task :deploy do
    env = fetch(:appsignal_env, fetch(:stage, fetch(:rails_env, fetch(:rack_env, 'production'))))
    user = ENV['USER'] || ENV['USERNAME']
    revision = fetch(:appsignal_revision, fetch(:current_revision))

    appsignal_config = Appsignal::Config.new(
      ENV['PWD'],
      env,
      fetch(:appsignal_config, {}),
      Logger.new(StringIO.new)
    )

    if appsignal_config && appsignal_config.active?
      marker_data = {
        :revision => revision,
        :user => user
      }

      marker = Appsignal::Marker.new(marker_data, appsignal_config)
      marker.transmit
    else
      puts 'Not notifying of deploy, config is not active'
    end
  end
end

after 'deploy:finished', 'appsignal:deploy'

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
appsignal-1.4.0.alpha.2 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-1.4.0.alpha.1 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-1.3.2 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-1.3.1 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-1.3.0 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-1.3.0.beta.3 lib/appsignal/integrations/capistrano/appsignal.cap