Skip to content

Conversation

@giuseppe
Copy link
Member

@giuseppe giuseppe commented Nov 5, 2019

rebase of #4058

Signed-off-by: Jakub Filak [email protected]
Signed-off-by: Giuseppe Scrivano [email protected]

@openshift-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: giuseppe

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

The pull request process is described here

Details 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

@openshift-ci-robot openshift-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 5, 2019
@giuseppe giuseppe force-pushed the set-mac branch 2 times, most recently from 7bc500c to 88b88d9 Compare November 5, 2019 15:27
@openshift-ci-robot openshift-ci-robot added size/XL and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 5, 2019
@openshift-ci-robot openshift-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL labels Nov 5, 2019
@giuseppe giuseppe force-pushed the set-mac branch 2 times, most recently from b6d6bdf to ed27f2f Compare November 5, 2019 16:50
@giuseppe
Copy link
Member Author

giuseppe commented Nov 5, 2019

@rhatdan I've tried vendor-in-container that I copied from buildah but there is no difference

@giuseppe giuseppe force-pushed the set-mac branch 2 times, most recently from 74236df to e5ddfe5 Compare November 5, 2019 18:29
@openshift-ci-robot openshift-ci-robot added size/XL and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 5, 2019
@openshift-ci-robot openshift-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL labels Nov 5, 2019
@vrothberg
Copy link
Member

@rhatdan I've tried vendor-in-container that I copied from buildah but there is no difference

libpod did not migrate to using go 1.13 for the vendor checks yet. You can run the following command and commit the changes which should unblock this PR:

$ podman run --privileged --rm --env HOME=/root --env GOPROXY=https://proxy.golang.org -v `pwd`:/src -w /src golang:1.12 make vendor

@openshift-ci-robot openshift-ci-robot added size/XL and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 6, 2019
@giuseppe
Copy link
Member Author

giuseppe commented Nov 6, 2019

$ podman run --privileged --rm --env HOME=/root --env GOPROXY=https://proxy.golang.org -v pwd:/src -w /src golang:1.12 make vendor

thanks for the black magic! It did the trick. I've updated the patch that adds vendor-in-container

@giuseppe giuseppe force-pushed the set-mac branch 2 times, most recently from cc6a756 to e49488f Compare November 6, 2019 11:50
giuseppe and others added 4 commits November 6, 2019 16:22
Signed-off-by: Giuseppe Scrivano <[email protected]>
`go get github.com/cri-o/ocicni@deac903fd99b6c52d781c9f42b8db3af7dcfd00a`

I had to fix compilation errors in libpod/networking_linux.go

---

ocicni.Networks has changed from string to the structure NetAttachment
with the member Name (the former string value) and the member Ifname
(optional).

I don't think we can make use of Ifname here, so I just map the array of
structures to array of strings - e.g. dropping Ifname.

---

The function GetPodNetworkStatus no longer returns Result but it returns
the wrapper structure NetResult which contains the former Result plus
NetAttachment (Network name and Interface name).

Again, I don't think we can make use of that information here, so I
just added `.Result` to fix the build.

---

Issue: containers#1136

Signed-off-by: Jakub Filak <[email protected]>
I basically copied and adapted the statements for setting IP.

Closes containers#1136

Signed-off-by: Jakub Filak <[email protected]>
Signed-off-by: Giuseppe Scrivano <[email protected]>
$(GO) mod verify

vendor-in-container:
podman run --privileged --rm --env HOME=/root -v `pwd`:/src -w /src docker.io/library/golang:1.12 make vendor
Copy link
Member

Choose a reason for hiding this comment

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

We want to move everyone to golang 1.13.

@vrothberg Correct?

Copy link
Member Author

Choose a reason for hiding this comment

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

we need first to update the CI image, if I use golang:1.13 the vendor check fails

Copy link
Member

Choose a reason for hiding this comment

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

The CI is currently using 1.12 already which means we can't use 1.13 on our dev machines. The change here is not needed.

@giuseppe
Copy link
Member Author

giuseppe commented Nov 6, 2019

tests are passing

@giuseppe
Copy link
Member Author

giuseppe commented Nov 7, 2019

@rhatdan
Copy link
Member

rhatdan commented Nov 7, 2019

LGTM
Really need @mheon to review.
@filak-sap PTAL

IPBefore.WaitWithDefaultTimeout()
Expect(IPBefore.ExitCode()).To(Equal(0))

MACBefore := podmanTest.Podman([]string{"inspect", "-l", "--format={{.NetworkSettings.MacAddress}}"})
Copy link
Member

Choose a reason for hiding this comment

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

Can we get a non-checkpoint test? Set --mac-address ab:cd:ef:gh and verify that it's set in the container?

@mheon
Copy link
Member

mheon commented Nov 7, 2019

Code LGTM but I would like another test

Signed-off-by: Giuseppe Scrivano <[email protected]>
@openshift-ci-robot openshift-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL labels Nov 7, 2019
@giuseppe
Copy link
Member Author

giuseppe commented Nov 7, 2019

Code LGTM but I would like another test

test added

@mheon
Copy link
Member

mheon commented Nov 7, 2019

LGTM

@mheon
Copy link
Member

mheon commented Nov 7, 2019

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Nov 7, 2019
@openshift-merge-robot openshift-merge-robot merged commit d919961 into containers:master Nov 7, 2019
@rhatdan
Copy link
Member

rhatdan commented Nov 7, 2019

Awesome job @filak-sap and @giuseppe
Thanks for getting this done.

@filak-sap
Copy link
Contributor

Thank you @giuseppe ! BTW What did I do wrong?

@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 26, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 26, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants