Documentation
¶
Overview ¶
Package profile provides functions accessing profiles in cu-sts config file.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Profile ¶
type Profile struct { Name string Account string `mapstructure:"account"` Role string `mapstructure:"role"` IDProvider string `mapstructure:"id_provider"` Duration int `mapstructure:"duration"` }
A Profile represents a single profile from the config file.
func New ¶
func New() Profile
New returns an "empty" Profile with defailt IDProvider and Duration values.
func NewFromConfig ¶
NewFromConfig returns a Profile with values set from default, config, or flags.
func (*Profile) Credentials ¶
func (p *Profile) Credentials(samlAssertion string) (*sts.Credentials, error)
Credentials requires a base-64 SAMLAssertion and returns AWS sts.Credentials using the Profile's role, idprovider, etc.
Click to show internal directories.
Click to hide internal directories.