Sha256: d6d4c013d282c246ce46283dfc47c124314fa953623313ccfb838fbdf4dab596

Contents?: true

Size: 496 Bytes

Versions: 28

Compression:

Stored size: 496 Bytes

Contents

require_relative '../services_helper'

module Kontena::Cli::Services::Envs
  class ListCommand < Clamp::Command
    include Kontena::Cli::Common
    include Kontena::Cli::GridOptions
    include Kontena::Cli::Services::ServicesHelper

    parameter "NAME", "Service name"

    def execute
      require_api_url
      token = require_token
      service = client(token).get("services/#{parse_service_id(name)}")
      service["env"].sort.each do |env|
        puts env
      end
    end
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
kontena-cli-0.15.5 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.5.rc2 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.5.rc1 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.4 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.4.rc2 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.4.rc1 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.4.pre1 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.3 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.2 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.1 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.0 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.0.rc3 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.0.rc2 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.15.0.rc1 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.14.7 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.14.6 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.14.5 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.14.4 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.14.3 lib/kontena/cli/services/envs/list_command.rb
kontena-cli-0.14.2 lib/kontena/cli/services/envs/list_command.rb