inertia: github.com/ubclaunchpad/inertia/provision Index | Files

package provision

import "github.com/ubclaunchpad/inertia/provision"

Package provision contains Inertia's VPS instance provisioning API

Index

Package Files

doc.go ec2.go

type EC2CreateInstanceOptions Uses

type EC2CreateInstanceOptions struct {
    Name        string
    ProjectName string
    Ports       []int64
    DaemonPort  int64

    ImageID      string
    InstanceType string
    Region       string
}

EC2CreateInstanceOptions defines parameters with which to create an EC2 instance

type EC2Provisioner Uses

type EC2Provisioner struct {
    // contains filtered or unexported fields
}

EC2Provisioner creates Amazon EC2 instances

func NewEC2Provisioner Uses

func NewEC2Provisioner(user, keyID, key string, out ...io.Writer) (*EC2Provisioner, error)

NewEC2Provisioner creates a client to interact with Amazon EC2 using the given credentials

func NewEC2ProvisionerFromEnv Uses

func NewEC2ProvisionerFromEnv(user string, out ...io.Writer) (*EC2Provisioner, error)

NewEC2ProvisionerFromEnv creates a client to interact with Amazon EC2 using credentials from environment

func NewEC2ProvisionerFromProfile Uses

func NewEC2ProvisionerFromProfile(user, profile, path string, out ...io.Writer) (*EC2Provisioner, error)

NewEC2ProvisionerFromProfile creates a client to interact with Amazon EC2 using credentials for user (optional) from given profile file

func (*EC2Provisioner) CreateInstance Uses

func (p *EC2Provisioner) CreateInstance(opts EC2CreateInstanceOptions) (*cfg.Remote, error)

CreateInstance creates an EC2 instance with given properties

func (*EC2Provisioner) GetUser Uses

func (p *EC2Provisioner) GetUser() string

GetUser returns the user attached to given credentials

func (*EC2Provisioner) ListImageOptions Uses

func (p *EC2Provisioner) ListImageOptions(region string) ([]string, error)

ListImageOptions lists available Amazon images for your given region

func (*EC2Provisioner) WithRegion Uses

func (p *EC2Provisioner) WithRegion(region string)

WithRegion assigns a region to the client

Package provision imports 18 packages (graph) and is imported by 2 packages. Updated 2020-09-06. Refresh now. Tools for package owners.