-
Notifications
You must be signed in to change notification settings - Fork 332
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
Conversation
api/platform/types.go
Outdated
@@ -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" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
location-based-image-prefix
8fd20f2
to
aa4345a
Compare
There was a problem hiding this 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()) |
There was a problem hiding this comment.
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, |
There was a problem hiding this comment.
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()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里是不是能进行收敛,直接用这个 p.getImagePrefix(c)
aa4345a
to
02233d8
Compare
What type of PR is this?
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.: