Class: ZAWS::AWSCLI::Commands::EC2::CreateVPC
- Inherits:
-
Object
- Object
- ZAWS::AWSCLI::Commands::EC2::CreateVPC
- Defined in:
- lib/zaws/external/awscli/commands/ec2/create_vpc.rb
Instance Method Summary collapse
- #execute(region, view, cidr, textout = nil, verbose = nil, profile = nil) ⇒ Object
-
#initialize(shellout, awscli) ⇒ CreateVPC
constructor
A new instance of CreateVPC.
Constructor Details
#initialize(shellout, awscli) ⇒ CreateVPC
Returns a new instance of CreateVPC.
7 8 9 10 |
# File 'lib/zaws/external/awscli/commands/ec2/create_vpc.rb', line 7 def initialize(shellout, awscli) @shellout=shellout @awscli=awscli end |
Instance Method Details
#execute(region, view, cidr, textout = nil, verbose = nil, profile = nil) ⇒ Object
12 13 14 15 |
# File 'lib/zaws/external/awscli/commands/ec2/create_vpc.rb', line 12 def execute(region, view, cidr, textout=nil, verbose=nil,profile=nil) comline="aws --output #{view} --region #{region} ec2 create-vpc --cidr-block #{cidr}" @awscli.data_ec2.vpc.load(comline, @shellout.cli(comline, verbose), textout) end |