Sha256: c2d001e562d8a71e194e5ae6cff1e20e6967ff30e0b2926d340c3821111d26ac

Contents?: true

Size: 1.14 KB

Versions: 5

Compression:

Stored size: 1.14 KB

Contents

module Percheron
  module Commands
    class Console < Abstract

      parameter('STACK_NAME', 'stack name', required: true)

      def execute
        super
        require 'pry-byebug'
        pry
      end

      private

        def logs(unit_name, follow: false)
          stack.logs!(unit_name, follow: follow)
          nil
        end

        def shell(unit_name)
          stack.shell!(unit_name)
          nil
        end

        def purge(unit_names)
          stack.purge!(unit_names: [ *unit_names ])
          nil
        end

        def create(unit_names, start: false)
          stack.create!(unit_names: [ *unit_names ], start: start)
          nil
        end

        def recreate(unit_names, start: false)
          stack.create!(unit_names: [ *unit_names ], start: start)
          nil
        end

        def start(unit_names)
          stack.start!(unit_names: [ *unit_names ])
          nil
        end

        def stop(unit_names)
          stack.stop!(unit_names: [ *unit_names ])
          nil
        end

        def restart(unit_names)
          stack.restart!(unit_names: [ *unit_names ])
          nil
        end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
percheron-0.7.11 lib/percheron/commands/console.rb
percheron-0.7.10 lib/percheron/commands/console.rb
percheron-0.7.9 lib/percheron/commands/console.rb
percheron-0.7.8 lib/percheron/commands/console.rb
percheron-0.7.7 lib/percheron/commands/console.rb