Sha256: 26f4b0423c3dd0d1a602d3051c36d67efca1dfaccf5a41691da2c917b8fa57ad

Contents?: true

Size: 781 Bytes

Versions: 10

Compression:

Stored size: 781 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 for environment: #{env}"
    end
  end
end

after "deploy:finished", "appsignal:deploy"

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
appsignal-2.3.3.beta.1 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.3.2 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.3.1 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.3.0 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.3.0.beta.3 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.3.0.beta.2 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.3.0.beta.1 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.2.1 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.2.0 lib/appsignal/integrations/capistrano/appsignal.cap
appsignal-2.2.0.beta.1 lib/appsignal/integrations/capistrano/appsignal.cap