Sha256: 4db85c3d00bc53871f71ebd20e00f04c6fae7bf06f7e1b86f941ac6383ad5b9c

Contents?: true

Size: 494 Bytes

Versions: 77

Compression:

Stored size: 494 Bytes

Contents

module Kontena
  module Callbacks
    class CreateInitialGridAfterDeploy < Kontena::Callback

      matches_commands 'master create'

      def after
        extend Kontena::Cli::Common

        return unless command.exit_code == 0
        return unless config.current_master
        return unless config.current_master.name == command.result[:name]

        cmd = %w(grid create --silent test)
        Retriable.retriable do
          Kontena.run!(cmd)
        end
      end
    end
  end
end

Version data entries

77 entries across 77 versions & 2 rubygems

Version Path
krates-1.7.11 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.10 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.9 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.8 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.7 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.6 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.5 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.4 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.3 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.2 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.1 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.7.0 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.9 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.8 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.7 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.6 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.5 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.4 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.3 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb
krates-1.6.2 lib/kontena/callbacks/master/deploy/55_create_initial_grid_after_deploy.rb