Documentation ¶
Index ¶
- func CheckPublicSubnet(subnetId string, routeTables []ec2.RouteTable) (bool, error)
- func WriteProfilesSubnets(profileSubnets ProfilesSubnets) error
- func WriteProfilesVpcs(profileVpcs ProfilesVpcs) error
- type AccountSubnets
- type AccountVpcs
- type ProfilesSubnets
- type ProfilesVpcs
- type RegionSubnets
- type RegionVpcs
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckPublicSubnet ¶
func CheckPublicSubnet(subnetId string, routeTables []ec2.RouteTable) (bool, error)
CheckPublicSubnet will check whether the route table associated with a subnet is actually public or not returns true if public, false if not TODO this is not the best check relying on the name. Need to add a route check on the route table for an IGW
func WriteProfilesSubnets ¶
func WriteProfilesSubnets(profileSubnets ProfilesSubnets) error
func WriteProfilesVpcs ¶
func WriteProfilesVpcs(profileVpcs ProfilesVpcs) error
Types ¶
type AccountSubnets ¶
type AccountSubnets []RegionSubnets
func GetAccountSubnets ¶
func GetAccountSubnets(account utils.AccountInfo) (AccountSubnets, error)
GetAccountSubnets will take a profile and go through all regions to get all instances in the account
type AccountVpcs ¶
type AccountVpcs []RegionVpcs
func GetAccountVpcs ¶
func GetAccountVpcs(account utils.AccountInfo) (AccountVpcs, error)
GetAccountVpcs will take a profile and go through all regions to get all instances in the account
type ProfilesSubnets ¶
type ProfilesSubnets []AccountSubnets
func GetProfilesSubnets ¶
func GetProfilesSubnets(accounts []utils.AccountInfo) (ProfilesSubnets, error)
GetProfilesSubnets will return all the subnets in all accounts of a given filename with a list of profiles in it
type ProfilesVpcs ¶
type ProfilesVpcs []AccountVpcs
func GetProfilesVpcs ¶
func GetProfilesVpcs(accounts []utils.AccountInfo) (ProfilesVpcs, error)
GetProfilesVpcs will return all the vpcs/subnets in all accounts of a given filename with a list of profiles in it
type RegionSubnets ¶
type RegionSubnets struct { AccountId string Region string Profile string Subnets []ec2.Subnet RouteTables []ec2.RouteTable }
func GetRegionSubnets ¶
func GetRegionSubnets(sess *session.Session) (*RegionSubnets, error)
GetRegionSubnets will take a session and pull all subnets and subnets based on the region of the session
type RegionVpcs ¶
type RegionVpcs struct { AccountId string Region string Profile string Vpcs []ec2.Vpc Subnets []ec2.Subnet }
func GetRegionVpcs ¶
func GetRegionVpcs(sess *session.Session, arn string) (*RegionVpcs, error)
GetRegionVpcs will take a session and pull all vpcs and subnets based on the region of the session