View definition

func New(p ConfigProvider, cfgs ...*Config) *EC2

Defined in github.com/aws/aws-sdk-go/service/ec2/service.go

Description

New creates a new instance of the EC2 client with a session. If additional configuration is needed for the client instance use the optional aws.Config parameter to add your extra config.

Example:

// Create a EC2 client from just a session.
svc := ec2.New(mySession)

// Create a EC2 client with additional configuration
svc := ec2.New(mySession, aws.NewConfig().WithRegion("us-west-2"))

New is referenced in 172 repositories

github.com/crewjam/swarm-aws github.com/dtan4/ec2c github.com/jgkim/packer

...