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

made necessary changes to handle OS/Arch while importing an image #606

Merged
merged 1 commit into from
Jun 8, 2021

Conversation

cdoern
Copy link
Contributor

@cdoern cdoern commented Jun 7, 2021

Signed-off-by: cdoern cbdoer23@g.holycross.edu

Making necessary changes in order to reference a platform as described in this issue on podman. This PR modifies the ImportOptions struct to handle OS/Arch and added two lines so that the config reads in these new parameters. Will open up a new PR on podman to handle parsing of OS/Arch here.

This is stemming from implementation of the platform parameter in the docker-compatabile API of podman. As seen in image_routes.go the docker engine handles platform with both fromSrc and fromImage. In order to mirror this, certain structs on this end must be modified.

@rhatdan
Copy link
Member

rhatdan commented Jun 7, 2021

/approve
LGTM
@vrothberg PTAL

@openshift-ci openshift-ci bot added the approved label Jun 7, 2021
@@ -23,6 +23,9 @@ type ImportOptions struct {
CommitMessage string
// Tag the imported image with this value.
Tag string
// Pref Platform for the image
OS string
Arch string
Copy link
Member

Choose a reason for hiding this comment

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

Please add comments to both fields. This way the comments will show up in doc generators and IDEs.

`// Overwrite OS/Arch of imported image.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

will do, thanks

Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

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

Just a mini nit.

Signed-off-by: cdoern <cbdoer23@g.holycross.edu>
@cdoern cdoern force-pushed the imgPlatformFeature branch from 1f00040 to ed87b61 Compare June 8, 2021 12:52
@cdoern cdoern requested a review from vrothberg June 8, 2021 13:15
Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 8, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cdoern, rhatdan, vrothberg

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@vrothberg
Copy link
Member

/lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants