Sha256: b8c4620458d1b3863c9f771fcf767605958ea994f72ffe12d04ad3be8884fc11
Contents?: true
Size: 677 Bytes
Versions: 77
Compression:
Stored size: 677 Bytes
Contents
module Kontena module Callbacks class ListAndSelectGrid < Kontena::Callback matches_commands 'master login' def after_load command.class_eval do option ['--skip-grid-auto-select'], :flag, 'Do not auto select grid' end end # Runs kontena grids list --use which will auto join the first available # grid def after extend Kontena::Cli::Common return if command.skip_grid_auto_select? return unless current_master return unless command.exit_code == 0 return unless current_master.grid.nil? Kontena.run(%w(grid list --use --verbose)) end end end end
Version data entries
77 entries across 77 versions & 2 rubygems