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(installer): support containerd installation #1404

Merged
merged 2 commits into from
Jul 27, 2021
Merged

feat(installer): support containerd installation #1404

merged 2 commits into from
Jul 27, 2021

Conversation

Huimintai
Copy link
Contributor

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.:


@Huimintai Huimintai requested a review from choujimmy as a code owner July 8, 2021 13:34
}
return nil
}

// PushImage pushes an image.
func (d *Docker) PushImage(image string) error {
cmdString := fmt.Sprintf("docker push %s", image)
cmdString := fmt.Sprintf("ctr images push %s -u admin:admin -k", image)
Copy link
Contributor

Choose a reason for hiding this comment

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

Do not use admin:admin

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Change to use password and username.

if err != nil {
return err
}
localHosts.File = "/etc/hosts"
localHosts.File = "/app/hosts"
Copy link
Contributor

Choose a reason for hiding this comment

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

Why change /etc/hosts to /app/hosts?

@@ -1284,33 +1283,6 @@ func (t *TKE) setupLocalRegistry(ctx context.Context) error {
return nil
}

func (t *TKE) startLocalRegistry() error {
Copy link
Contributor

Choose a reason for hiding this comment

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

Where the images should be pushed to before tke-registry is installed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

tke-registry create by nerdctl because nerdctl can not create containers inside container.

@@ -2529,40 +2500,23 @@ func (t *TKE) pushImages(ctx context.Context) error {
}

// only push image
err = t.docker.PushImage(image)
err = t.docker.PushImage(image, t.Para.Config.Registry.TKERegistry.Username, string(t.Para.Config.Registry.TKERegistry.Password))
Copy link
Contributor

Choose a reason for hiding this comment

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

Why we need docker for pushing images?

@@ -76,7 +76,7 @@ var components = Components{
InfluxDB: containerregistry.Image{Name: "influxdb", Tag: "1.7.9"},
Thanos: containerregistry.Image{Name: "thanos", Tag: "v0.15.0"},

ProviderRes: containerregistry.Image{Name: "provider-res", Tag: "v1.20.4-2"},
ProviderRes: containerregistry.Image{Name: "provider-res", Tag: "v1.20.4-3"},
Copy link
Contributor

Choose a reason for hiding this comment

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

no one use v1.20.4-2, please reuse this version.

@leoryu leoryu merged commit 70dd906 into tkestack:master Jul 27, 2021
leoryu added a commit that referenced this pull request Aug 5, 2021
leoryu added a commit that referenced this pull request Aug 5, 2021
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.

None yet

2 participants