bridgezone

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 4, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsExecution

func IsExecution(err error) bool

IsExecution asserts executionError.

func IsInvalidConfig

func IsInvalidConfig(err error) bool

IsInvalidConfig asserts invalidConfigError.

func IsNotFound

func IsNotFound(err error) bool

IsNotFound asserts notFoundError.

Types

type Config

type Config struct {
	HostAWSConfig clientaws.Config
	HostRoute53   *route53.Route53
	K8sClient     kubernetes.Interface
	Logger        micrologger.Logger

	Route53Enabled bool
}

type Resource

type Resource struct {
	// contains filtered or unexported fields
}
cluster_id.k8s.installation.eu-central-1.aws.gigantic.io (byoc tenant account)
├── A api.cluster_id.k8s.installation.eu-central-1.aws.gigantic.io
└── A ingress.cluster_id.k8s.installation.eu-central-1.aws.gigantic.io

NOTE: In the code below k8s.installation.eu-central-1.aws.gigantic.io zone is called "intermediate" and cluster_id.k8s.installation.eu-central-1.aws.gigantic.io zone is called "final". This resource *only* ensures we have delegation from the intermediate zone to the final zone, but only if the intermediate zone exists.

After everything is fully migrated the DNS layout should look like:

installation.eu-central-1.aws.gigantic.io (control plane account)
├── NS k8s.installation.eu-central-1.aws.gigantic.io (default guest account)
└── NS cluster_id.k8s.installation.eu-central-1.aws.gigantic.io (byoc guest account)

k8s.installation.eu-central-1.aws.gigantic.io (default guest account)
└── NS cluster_id.k8s.installation.eu-central-1.aws.gigantic.io (byoc guest account)

cluster_id.k8s.installation.eu-central-1.aws.gigantic.io (byoc guest account)
├── A api.cluster_id.k8s.installation.eu-central-1.aws.gigantic.io
└── A ingress.cluster_id.k8s.installation.eu-central-1.aws.gigantic.io

At this point we should be fine with removing k8s.installation.eu-central-1.aws.gigantic.io NS record from installation.eu-central-1.aws.gigantic.io zone. Then after a couple of days when delegation propagates and DNS caches are refreshed we can delete k8s.installation.eu-central-1.aws.gigantic.io zone from the default guest account.

NOTE: To complete full migration we need to start reconciling "hostpost" CloudFormation stack. This stack is responsible for creating cluster_id.k8s.installation.eu-central-1.aws.gigantic.io delegation in the installation.eu-central-1.aws.gigantic.io. Till this happens this resource cannot be deleted.

See https://github.com/giantswarm/aws-operator/pull/1373.

func New

func New(config Config) (*Resource, error)

func (*Resource) EnsureCreated

func (r *Resource) EnsureCreated(ctx context.Context, obj interface{}) error

func (*Resource) EnsureDeleted

func (r *Resource) EnsureDeleted(ctx context.Context, obj interface{}) error

func (*Resource) Name

func (r *Resource) Name() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL