Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(platform): support dynamic registry #2083

Merged
merged 1 commit into from
Sep 16, 2022

Conversation

leoryu
Copy link
Contributor

@leoryu leoryu commented Sep 16, 2022

What type of PR is this?

Uncomment only one /kind <> line, hit enter to put that in a new line, and remove leading whitespace from that line:

/kind api-change
/kind bug
/kind cleanup
/kind deprecation
/kind design
/kind documentation
/kind failing-test
/kind feature
/kind flake

What this PR does / why we need it:

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:


Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:


@leoryu leoryu requested a review from choujimmy as a code owner September 16, 2022 01:46
@@ -123,6 +123,8 @@ const (
AnywhereApplicationAnno = "tkestack.io/anywhere-application"
// AnywhereValidateAnno is exist, the cluster will always return validate result
AnywhereValidateAnno = "tkestack.io/anywhere-validate"
// AnywhereImagePrefixAnno is exist, the cluster will use it as k8s images prefix
AnywhereImagePrefixAnno = "tkestack.io/anywhere-image-prefix"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

location-based-image-prefix

@leoryu leoryu force-pushed the support-dynamic-registry branch from 8fd20f2 to aa4345a Compare September 16, 2022 02:29
Copy link
Collaborator

@wl-chen wl-chen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cc

@@ -84,7 +85,7 @@ func (p *Provider) EnsureRenewCerts(ctx context.Context, c *v1.Cluster) error {
}

func (p *Provider) EnsureAPIServerCert(ctx context.Context, c *v1.Cluster) error {
kubeadmConfig := p.getKubeadmInitConfig(c)
kubeadmConfig := p.GetKubeadmInitConfig(c, containerregistry.GetPrefix())
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里直接用的原来的repo吗?

@@ -184,7 +184,7 @@ func (p *Provider) getClusterConfiguration(c *v1.Cluster) *kubeadmv1beta2.Cluste
DNS: kubeadmv1beta2.DNS{
Type: kubeadmv1beta2.CoreDNS,
},
ImageRepository: containerregistry.GetPrefix(),
ImageRepository: repo,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里是不是能进行收敛,直接用这个 p.getImagePrefix(c)

args := map[string]string{
"pod-infra-container-image": images.Get().Pause.FullName(),
"pod-infra-container-image": path.Join(repo, images.Get().Pause.BaseName()),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里是不是能进行收敛,直接用这个 p.getImagePrefix(c)

@leoryu leoryu force-pushed the support-dynamic-registry branch from aa4345a to 02233d8 Compare September 16, 2022 06:26
@leoryu leoryu merged commit 625c032 into tkestack:master Sep 16, 2022
@leoryu leoryu deleted the support-dynamic-registry branch September 16, 2022 06:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants