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

kind: fix antrea-ubuntu image in build/yamls #4147

Closed

Conversation

ajita-asthana
Copy link

This PR fixes the docker image for antrea-ubuntu in build/yamls/antrea.yml for automatic deployment using kind, i.e
the previous image "projects.registry.vmware.com/antrea/antrea-ubuntu:latest" is now changed to "antrea/antrea-ubuntu:latest"

Additionally, the docs are updated to reflect the new image.

Signed-off-by: Ajeeta Asthana ajita.asthana@gmail.com

Signed-off-by: Ajeeta Asthana <ajita.asthana@gmail.com>
@tnqn
Copy link
Member

tnqn commented Aug 24, 2022

hi @ajita-asthana, thanks for your PR. Did you meet issue with "projects.registry.vmware.com/antrea/antrea-ubuntu:latest"? Using that registry instead of dockerhub is to avoid pull rate limiting of the latter since dockerhub changed its rate limiting policy in 2020, more details can be found in #1617 and #1555.

@ajita-asthana
Copy link
Author

hi @ajita-asthana, thanks for your PR. Did you meet issue with "projects.registry.vmware.com/antrea/antrea-ubuntu:latest"? Using that registry instead of dockerhub is to avoid pull rate limiting of the latter since dockerhub changed its rate limiting policy in 2020, more details can be found in #1617 and #1555.

Hi @tnqn, thanks for the info. Switching to the VMWare registry to avoid rate limiting makes sense from a ci point of view. However, the docs don't reflect this to new users and they face image not found errors. Can I just update the docs to reflect this information and suggest the use of the docker hub image for local development? WDYT?

@tnqn
Copy link
Member

tnqn commented Aug 26, 2022

cc @antoninbas

Hi @tnqn, thanks for the info. Switching to the VMWare registry to avoid rate limiting makes sense from a ci point of view. However, the docs don't reflect this to new users and they face image not found errors. Can I just update the docs to reflect this information and suggest the use of the docker hub image for local development? WDYT?

Sorry, I'm still trying to understand how image not found is caused. "projects.registry.vmware.com/antrea" is a mirror of "docker.io/antrea", every image that you can pull from the latter can be pulled from the former as well. For local development, if you use make or make build to build the image, it will create tags for both docker hub and VMWare registry like the following, so using any of them is fine. But using the docker hub image would mean user have to update the image in the installation manifest to remove the registry prefix, I'm not sure I understand why it would be preferred. But I may miss the docs that doesn't reflect this information, could you point them out? If they do confuse users, you are welcome to correct them. Thanks,

# make
===> Building Antrea bins and antrea/antrea-ubuntu Docker image <===
docker build --pull -t antrea/antrea-ubuntu:v1.9.0-dev-7afa4fbbd -f build/images/Dockerfile.build.ubuntu --build-arg OVS_VERSION=2.17.0 --build-arg GO_VERSION=1.19 .
Sending build context to Docker daemon  670.2MB
Step 1/15 : ARG GO_VERSION
Step 2/15 : ARG OVS_VERSION
...
Step 15/15 : COPY --from=antrea-build /antrea/bin/* /usr/local/bin/
 ---> 58771599c93f
Successfully built 58771599c93f
Successfully tagged antrea/antrea-ubuntu:v1.9.0-dev-7afa4fbbd
docker tag antrea/antrea-ubuntu:v1.9.0-dev-7afa4fbbd antrea/antrea-ubuntu
docker tag antrea/antrea-ubuntu:v1.9.0-dev-7afa4fbbd projects.registry.vmware.com/antrea/antrea-ubuntu
docker tag antrea/antrea-ubuntu:v1.9.0-dev-7afa4fbbd projects.registry.vmware.com/antrea/antrea-ubuntu:v1.9.0-dev-7afa4fbbd

@antoninbas
Copy link
Contributor

@tnqn I don't know if this is the issue being brought up here, but in some cases doing a docker pull projects.registry.vmware.com/antrea/antrea-ubuntu:latest outside of the VMware network can fail. This is because the harbor registry uses a CDN for caching, which doesn't work well at all when tags are being re-used (in our case, we re-use the latest tag all the time). When you access the registry from the corporate network / VPN, you bypass the CDN and the image pull never fails.

Considering the above, it could make sense for images with the latest tag to use Dockerhub instead of harbor, and we could update the manifests to reflect that.
However, this issue does not affect release images, since in this case we always use an immutable tag. In other words, docker pull projects.registry.vmware.com/antrea/antrea-ubuntu:v1.8.0 should never fail.

@tnqn
Copy link
Member

tnqn commented Aug 29, 2022

@antoninbas thanks for the explanation. I didn't realize the default repo and tag didn't work for internet users. Now I remember someone raised the same issue. Then it seems making sense to make the image in main branch point to docker hub?

@ajita-asthana For the patch, I think the right way to update the image registry is updating this file: https://github.com/antrea-io/antrea/blob/main/build/charts/antrea/values.yaml#L3, then using make manifest to auto-generate all yaml files.

@antoninbas
Copy link
Contributor

@ajita-asthana let us know if you want to take a new stab at the patch

@codecov
Copy link

codecov bot commented Aug 29, 2022

Codecov Report

Merging #4147 (52bbe1d) into main (4504127) will increase coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #4147      +/-   ##
==========================================
+ Coverage   65.90%   65.94%   +0.04%     
==========================================
  Files         306      306              
  Lines       46663    46663              
==========================================
+ Hits        30752    30772      +20     
+ Misses      13496    13483      -13     
+ Partials     2415     2408       -7     
Flag Coverage Δ *Carryforward flag
integration-tests 35.07% <ø> (+0.02%) ⬆️
kind-e2e-tests 49.03% <ø> (ø) Carriedforward from 4504127
unit-tests 44.96% <ø> (+0.01%) ⬆️

*This pull request uses carry forward flags. Click here to find out more.

Impacted Files Coverage Δ
...lticluster/commonarea/resourceimport_controller.go 79.18% <0.00%> (-1.86%) ⬇️
pkg/ovs/openflow/ofctrl_bridge.go 75.92% <0.00%> (-0.20%) ⬇️
pkg/ipam/poolallocator/allocator.go 49.76% <0.00%> (+0.95%) ⬆️
pkg/agent/cniserver/ipam/antrea_ipam.go 75.75% <0.00%> (+1.73%) ⬆️
...trollers/multicluster/resourceexport_controller.go 80.05% <0.00%> (+4.91%) ⬆️

@antoninbas
Copy link
Contributor

Since we haven't heard back from @ajita-asthana, I'll take a stab at this

@antoninbas
Copy link
Contributor

Superseded by #4235

@antoninbas antoninbas closed this Sep 16, 2022
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

3 participants