Sha256: fce6bea451c65c52022bdf78f927131258a2c2e1af47ebb83b2165a092c2b433

Contents?: true

Size: 815 Bytes

Versions: 34

Compression:

Stored size: 815 Bytes

Contents

# -*- coding: utf-8 -*-
require "magellan/cli/resources"

module Magellan
  module Cli
    module Resources

      class TransactionRouter < Base
        self.resource_key = "functions~transaction_router"
        self.resource_dependency = {"stage" => Stage.parameter_name}

        desc "create NAME", I18n.t(:create, scope: [:resources, :common, :cmd], resource_name: resource_name)
        def create(name)
          s = load_selection!(Stage::VERSION_PARAMETER_NAME)
          params = {
            self.class.parameter_name => {
              "stage_version_id" => s["id"],
              "name" => name,
              # "instance_base_name" => name,
            }
          }
          post_json("/admin/#{self.resource_key}/new.json", params)
          select(name)
        end

      end

    end
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
magellan-cli-0.9.1 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.9.0 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.8.3 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.8.2 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.8.1 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.8.0 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.11 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.10 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.9 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.8 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.7 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.6 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.5 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.4 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.3 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.2 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.1 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.7.0 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.6.5 lib/magellan/cli/resources/transaction_router.rb
magellan-cli-0.6.4 lib/magellan/cli/resources/transaction_router.rb