Documentation ¶
Index ¶
- Constants
- type APILoadBalancerBuilder
- type AutoscalingGroupModelBuilder
- type ExternalAccessModelBuilder
- type FirewallModelBuilder
- type GCEModelContext
- func (b *GCEModelContext) AddFirewallRulesTasks(c *fi.ModelBuilderContext, name string, rule *gcetasks.FirewallRule)
- func (c *GCEModelContext) GCETagForRole(role kops.InstanceGroupRole) string
- func (c *GCEModelContext) LinkToNetwork() (*gcetasks.Network, error)
- func (c *GCEModelContext) LinkToServiceAccount(ig *kops.InstanceGroup) *gcetasks.ServiceAccount
- func (c *GCEModelContext) LinkToSubnet(subnet *kops.ClusterSubnetSpec) *gcetasks.Subnet
- func (c *GCEModelContext) LinkToTargetPool(id string) *gcetasks.TargetPool
- func (c *GCEModelContext) NameForBackendService(id string) string
- func (c *GCEModelContext) NameForFirewallRule(id string) string
- func (c *GCEModelContext) NameForForwardingRule(id string) string
- func (c *GCEModelContext) NameForHealthCheck(id string) string
- func (c *GCEModelContext) NameForHealthcheck(id string) string
- func (c *GCEModelContext) NameForIPAddress(id string) string
- func (c *GCEModelContext) NameForIPAliasRange(key string) string
- func (c *GCEModelContext) NameForPoolHealthcheck(id string) string
- func (c *GCEModelContext) NameForRouter(id string) string
- func (c *GCEModelContext) NameForTargetPool(id string) string
- func (c *GCEModelContext) NetworkingIsGCERoutes() bool
- func (c *GCEModelContext) NetworkingIsIPAlias() bool
- func (c *GCEModelContext) SafeClusterName() string
- func (c *GCEModelContext) SafeObjectName(name string) string
- func (c *GCEModelContext) SafeSuffixedObjectName(name string) string
- func (c *GCEModelContext) SafeTruncatedClusterName() string
- type NetworkModelBuilder
- type ServiceAccountsBuilder
- type StorageAclBuilder
Constants ¶
const (
DefaultVolumeType = "pd-standard"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APILoadBalancerBuilder ¶
type APILoadBalancerBuilder struct { *GCEModelContext Lifecycle fi.Lifecycle }
APILoadBalancerBuilder builds a LoadBalancer for accessing the API
func (*APILoadBalancerBuilder) Build ¶
func (b *APILoadBalancerBuilder) Build(c *fi.ModelBuilderContext) error
type AutoscalingGroupModelBuilder ¶
type AutoscalingGroupModelBuilder struct { *GCEModelContext BootstrapScriptBuilder *model.BootstrapScriptBuilder Lifecycle fi.Lifecycle }
TODO: rework these parts to be more GCE native. ie: Managed Instance Groups > ASGs AutoscalingGroupModelBuilder configures AutoscalingGroup objects
func (*AutoscalingGroupModelBuilder) Build ¶
func (b *AutoscalingGroupModelBuilder) Build(c *fi.ModelBuilderContext) error
type ExternalAccessModelBuilder ¶
type ExternalAccessModelBuilder struct { *GCEModelContext Lifecycle fi.Lifecycle }
ExternalAccessModelBuilder configures security group rules for external access (SSHAccess, KubernetesAPIAccess)
func (*ExternalAccessModelBuilder) Build ¶
func (b *ExternalAccessModelBuilder) Build(c *fi.ModelBuilderContext) error
type FirewallModelBuilder ¶
type FirewallModelBuilder struct { *GCEModelContext Lifecycle fi.Lifecycle }
FirewallModelBuilder configures firewall network objects
func (*FirewallModelBuilder) Build ¶
func (b *FirewallModelBuilder) Build(c *fi.ModelBuilderContext) error
type GCEModelContext ¶
type GCEModelContext struct { ProjectID string *model.KopsModelContext }
func (*GCEModelContext) AddFirewallRulesTasks ¶ added in v1.21.3
func (b *GCEModelContext) AddFirewallRulesTasks(c *fi.ModelBuilderContext, name string, rule *gcetasks.FirewallRule)
AddFirewallRulesTasks creates and adds ipv4 and ipv6 gcetasks.FirewallRule Tasks. GCE does not allow us to mix ipv4 and ipv6 in the same firewall rule, so we must create separate rules. Furthermore, an empty SourceRange with empty SourceTags is interpreted as allow-everything, but we intend for it to block everything; so we can Disabled to achieve the desired blocking.
func (*GCEModelContext) GCETagForRole ¶
func (c *GCEModelContext) GCETagForRole(role kops.InstanceGroupRole) string
GCETagForRole returns the (network) tag for GCE instances in the given instance group role.
func (*GCEModelContext) LinkToNetwork ¶
func (c *GCEModelContext) LinkToNetwork() (*gcetasks.Network, error)
LinkToNetwork returns the GCE Network object the cluster is located in
func (*GCEModelContext) LinkToServiceAccount ¶ added in v1.24.0
func (c *GCEModelContext) LinkToServiceAccount(ig *kops.InstanceGroup) *gcetasks.ServiceAccount
LinkToServiceAccount returns a link to the GCE ServiceAccount object for VMs in the given role
func (*GCEModelContext) LinkToSubnet ¶ added in v1.23.0
func (c *GCEModelContext) LinkToSubnet(subnet *kops.ClusterSubnetSpec) *gcetasks.Subnet
LinkToSubnet returns a link to the GCE subnet object
func (*GCEModelContext) LinkToTargetPool ¶
func (c *GCEModelContext) LinkToTargetPool(id string) *gcetasks.TargetPool
func (*GCEModelContext) NameForBackendService ¶ added in v1.24.0
func (c *GCEModelContext) NameForBackendService(id string) string
func (*GCEModelContext) NameForFirewallRule ¶
func (c *GCEModelContext) NameForFirewallRule(id string) string
func (*GCEModelContext) NameForForwardingRule ¶
func (c *GCEModelContext) NameForForwardingRule(id string) string
func (*GCEModelContext) NameForHealthCheck ¶ added in v1.24.0
func (c *GCEModelContext) NameForHealthCheck(id string) string
func (*GCEModelContext) NameForHealthcheck ¶ added in v1.24.0
func (c *GCEModelContext) NameForHealthcheck(id string) string
func (*GCEModelContext) NameForIPAddress ¶
func (c *GCEModelContext) NameForIPAddress(id string) string
func (*GCEModelContext) NameForIPAliasRange ¶ added in v1.15.1
func (c *GCEModelContext) NameForIPAliasRange(key string) string
NameForIPAliasRange returns the name for the secondary IP range attached to a subnet
func (*GCEModelContext) NameForPoolHealthcheck ¶ added in v1.24.0
func (c *GCEModelContext) NameForPoolHealthcheck(id string) string
func (*GCEModelContext) NameForRouter ¶ added in v1.24.0
func (c *GCEModelContext) NameForRouter(id string) string
func (*GCEModelContext) NameForTargetPool ¶
func (c *GCEModelContext) NameForTargetPool(id string) string
func (*GCEModelContext) NetworkingIsGCERoutes ¶ added in v1.23.0
func (c *GCEModelContext) NetworkingIsGCERoutes() bool
func (*GCEModelContext) NetworkingIsIPAlias ¶ added in v1.23.0
func (c *GCEModelContext) NetworkingIsIPAlias() bool
func (*GCEModelContext) SafeClusterName ¶ added in v1.23.0
func (c *GCEModelContext) SafeClusterName() string
SafeClusterName returns the cluster name escaped for use as a GCE resource name
func (*GCEModelContext) SafeObjectName ¶
func (c *GCEModelContext) SafeObjectName(name string) string
SafeObjectName returns the object name and cluster name escaped for GCE
func (*GCEModelContext) SafeSuffixedObjectName ¶ added in v1.24.0
func (c *GCEModelContext) SafeSuffixedObjectName(name string) string
SafeSuffixedObjectName returns the object name and cluster name escaped for GCE, limited to 63 chars
func (*GCEModelContext) SafeTruncatedClusterName ¶ added in v1.24.2
func (c *GCEModelContext) SafeTruncatedClusterName() string
SafeClusterName returns the cluster name escaped and truncated for use as a GCE resource name
type NetworkModelBuilder ¶
type NetworkModelBuilder struct { *GCEModelContext Lifecycle fi.Lifecycle }
NetworkModelBuilder configures network objects
func (*NetworkModelBuilder) Build ¶
func (b *NetworkModelBuilder) Build(c *fi.ModelBuilderContext) error
type ServiceAccountsBuilder ¶ added in v1.24.0
type ServiceAccountsBuilder struct { *GCEModelContext Lifecycle fi.Lifecycle }
ServiceAccountsBuilder configures service accounts and grants project permissions
func (*ServiceAccountsBuilder) Build ¶ added in v1.24.0
func (b *ServiceAccountsBuilder) Build(c *fi.ModelBuilderContext) error
type StorageAclBuilder ¶
type StorageAclBuilder struct { *GCEModelContext Cloud gce.GCECloud Lifecycle fi.Lifecycle }
StorageAclBuilder configures storage acls
func (*StorageAclBuilder) Build ¶
func (b *StorageAclBuilder) Build(c *fi.ModelBuilderContext) error