-
Notifications
You must be signed in to change notification settings - Fork 240
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
Update dropgz to use azure-ipam release #1588
Conversation
dropgz/build/cni.Dockerfile
Outdated
WORKDIR /azure-ipam | ||
COPY ./azure-ipam . | ||
RUN CGO_ENABLED=0 go build -a -o bin/azure-ipam -trimpath -ldflags "-X main.version="$VERSION"" -gcflags="-dwarflocationlists=true" . | ||
RUN curl -LO https://github.com/Azure/azure-container-networking/releases/download/azure-ipam%2Fv0.0.2/azure-ipam-$OS-$ARCH-v0.0.2.tgz && tar -xvf azure-ipam-$OS-$ARCH-v0.0.2.tgz | ||
|
||
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.19 AS azure-vnet |
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.
Since we are not doing Go compiling, these probably don't need to be FROM
a Go base image anymore.
We could create an intermediate mariner image with tar:
FROM mcr.microsoft.com/cbl-mariner/base/core:2.0 as tar
tdnf install -y tar
then change the azure-ipam/azure-vnet images to
FROM tar AS azure-ipam
...
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.
while I was checking the docs for that, I noticed that it's possible to use external images directly without making them in to intermediate images...so we can remove line 1 entirely, and change the cilium copy line to:
COPY --from=mcr.microsoft.com/oss/cilium/cilium:1.12.1.1 /opt/cni/bin/cilium-cni pkg/embed/fs
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.
running into issues after creating the mariner image -- curl for azure-ipam/azure-vnet is now failing with:
curl: (60) SSL certificate problem: unable to get local issuer certificate
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.
probably need to install ca-certificates
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.
@camrynl lets also remove cilium image from dropgz since cilium cni going to be installed by cilium agent
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.
@camrynl are we using same dockerfile for e2e pipeline as well.? If so, this wouldn't test PR branch azure-ipam version right?
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.
@tamilmani1989 yes this is used in the e2e pipeline to make the image, and the tests are using the tagged version of dropgz and cns
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.
in that case we should use separate dockerfile for e2e pipeline so that it uses PR branch version(locally built version) instead of officially release version of azure-ipam or cns
Reason for Change:
cni.Dockerfile is currently building local versions of azure-ipam, updating to use the new release.
Issue Fixed:
Requirements:
Notes: