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

Build buildkit version of image-builder in ado #9581

Merged
merged 65 commits into from
Dec 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
7e16985
Update image building rules and add post-build job (#9461)
dekiel Dec 5, 2023
6ff0865
Allow admins to bypass branch protection in community-modules (#9437)
pbochynski Dec 5, 2023
c37fca1
Remove unused script from Istio reconciler testing (#9468)
Dec 6, 2023
c12d34d
Tag telemetry-manager image with module version and remove release jo…
shorim Dec 6, 2023
47ab59d
job_removed (#9471)
Cortey Dec 6, 2023
9973d73
gomod(deps): bump google.golang.org/api from 0.152.0 to 0.153.0 (#9474)
dependabot[bot] Dec 6, 2023
bc2bed7
actions(deps): bump actions/setup-go from 4 to 5 (#9476)
dependabot[bot] Dec 6, 2023
bc92b09
docker-rotate-sa(deps): bump golang (#9477)
dependabot[bot] Dec 6, 2023
2542da5
Bumping test-infra and testimages and test-infra-prod (#9479)
kyma-bot Dec 6, 2023
66405ff
move-gcs-bucket(deps): bump golang in /cmd/cloud-run/move-gcs-bucket …
dependabot[bot] Dec 6, 2023
89b8b0b
gomod(deps): bump github.com/spf13/viper from 1.17.0 to 1.18.0 (#9475)
dependabot[bot] Dec 6, 2023
94693f9
ginkgo(deps): bump golang in /prow/images/ginkgo (#9478)
dependabot[bot] Dec 6, 2023
e979616
Bumping test-infra and testimages and test-infra-prod (#9481)
kyma-bot Dec 6, 2023
a27040b
Bumping sec-scanners-config.yaml (#9458)
kyma-bot Dec 6, 2023
38dec65
Bumping test-infra and testimages and test-infra-prod (#9482)
kyma-bot Dec 6, 2023
acfab5a
Bump natsio images (#9469)
grischperl Dec 7, 2023
7459628
Remove the eventing manager template. (#9484)
friedrichwilken Dec 7, 2023
c5ff46d
Use semantic versioning for eventing manager (#9473)
the1bit Dec 7, 2023
8cc35f8
Adds a setting to ignore non-required tide contexts (#9485)
ameteiko Dec 7, 2023
a6fe7e8
fix run_if_changed (#9487)
mrCherry97 Dec 8, 2023
6e00005
chore: Remove cli related k3d pipelines that use kyma deploy (#9486)
lindnerby Dec 8, 2023
d9f4429
Ignore docker images based on regexp (#9488)
KacperMalachowski Dec 8, 2023
db483d5
Bumping sec-scanners-config.yaml (#9483)
kyma-bot Dec 8, 2023
1dd9587
add two missing required job (#9489)
ruanxin Dec 8, 2023
9b9d11a
allow post build job to run on release-* branches for eventing-manage…
friedrichwilken Dec 8, 2023
d2d58e9
docker-rotate-sa(deps): bump alpine (#9500)
dependabot[bot] Dec 8, 2023
1154d0f
gomod(deps): bump github.com/spf13/viper from 1.18.0 to 1.18.1 (#9501)
dependabot[bot] Dec 8, 2023
114206b
move-gcs-bucket(deps): bump alpine in /cmd/cloud-run/move-gcs-bucket …
dependabot[bot] Dec 8, 2023
b867b32
Bumping test-infra and testimages and test-infra-prod (#9503)
kyma-bot Dec 8, 2023
0a83216
Bumping sec-scanners-config.yaml (#9504)
kyma-bot Dec 8, 2023
a42b15a
Bumping Prow (#9506)
kyma-bot Dec 11, 2023
cea2c66
check for valid serverless CR URL (#9507)
tobiscr Dec 11, 2023
239ffe8
stop running the post manager build job on release branches (#9509)
friedrichwilken Dec 11, 2023
211043f
removed jobs of directory-size-exporter (#9499)
a-thaler Dec 11, 2023
b1e07e8
reconciler consistently failing - expected and can be ignored (#9510)
tobiscr Dec 11, 2023
3779f97
slack-msg-sender(deps): bump python (#9513)
dependabot[bot] Dec 11, 2023
d8a8b1d
Bumping test-infra and testimages and test-infra-prod (#9514)
kyma-bot Dec 11, 2023
265f5e7
Bumping sec-scanners-config.yaml (#9515)
kyma-bot Dec 11, 2023
ff9c38b
tf(deps): bump hashicorp/google in /configs/terraform/core (#9512)
dependabot[bot] Dec 12, 2023
68ecc0d
Add required status check for KEB (#9505)
MarekMichali Dec 12, 2023
74f1799
add squash config for epp repository (#9516)
k15r Dec 12, 2023
37381cc
Remove skr-aws-ugrade-integration test (#9518)
MarekMichali Dec 12, 2023
63f7aa5
remove epp, eventing-tools, eventing-module jobs (#9517)
k15r Dec 12, 2023
cc53587
Fix image building (#9519)
halamix2 Dec 12, 2023
eebd6aa
Bumping test-infra and testimages and test-infra-prod (#9520)
kyma-bot Dec 12, 2023
878301c
Bumping sec-scanners-config.yaml (#9521)
kyma-bot Dec 12, 2023
87f9b74
Add ADO pipeline preview run feature and test (#9462)
dekiel Dec 13, 2023
f2a61aa
Add skr-trial-suspension-dev prowjob (#9524)
szwedm Dec 13, 2023
5d322cf
Bumping test-infra and testimages and test-infra-prod (#9525)
kyma-bot Dec 13, 2023
3b68f5f
Bumping sec-scanners-config.yaml (#9526)
kyma-bot Dec 13, 2023
3f14310
Adopt nats prow jobs for release flow. (#9511)
friedrichwilken Dec 14, 2023
7a3a820
add e2e-dind-nodejs-20 image with node 20.10 (#9529)
mrCherry97 Dec 15, 2023
31eb94e
fix: Increase resources requests for cli release jobs (#9530)
lindnerby Dec 15, 2023
b61ff29
fix: Set resources limits for cli release jobs (#9534)
lindnerby Dec 15, 2023
3ea7fd0
Bumping test-infra and testimages and test-infra-prod (#9531)
kyma-bot Dec 15, 2023
da3728b
Bumping sec-scanners-config.yaml (#9535)
kyma-bot Dec 15, 2023
e5f228b
Bumping test-infra and testimages and test-infra-prod (#9536)
kyma-bot Dec 15, 2023
8a7aa79
Bumping sec-scanners-config.yaml (#9537)
kyma-bot Dec 15, 2023
c4f068b
Merge branch 'kyma-project:main' into main
dekiel Dec 16, 2023
b513c95
Build image-builder binary in a Dockerfile.
dekiel Dec 27, 2023
fb16bce
Build postsubmit buildkit version in CI.
dekiel Dec 27, 2023
d1866c7
Merge remote-tracking branch 'upstream/main' into build-buildkit-in-ado
dekiel Dec 27, 2023
629770d
Merge remote-tracking branch 'upstream/main' into build-buildkit-in-ado
dekiel Dec 27, 2023
85dfb28
Build image-builder on changes in Dockerfiles.
dekiel Dec 28, 2023
2fb5527
cleanup
dekiel Dec 28, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions cmd/image-builder/images/buildkit/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
FROM alpine:3.17.1 AS creds

SHELL ["/bin/ash", "option", "-o", "pipefail"]
RUN apk add --no-cache curl && \
curl -fsSL "https://github.com/GoogleCloudPlatform/docker-credential-gcr/releases/download/v2.1.5/docker-credential-gcr_linux_amd64-2.1.5.tar.gz" \
| tar xz docker-credential-gcr \
&& chmod +x docker-credential-gcr && mv docker-credential-gcr /usr/bin/

FROM europe-docker.pkg.dev/kyma-project/prod/testimages/buildpack-go:v20231128-9bb59ac6 AS builder

WORKDIR /
COPY . /app/
RUN cd /app/cmd/image-builder && CGO_ENABLED=0 go build -o /app/image-builder -a -ldflags '-extldflags "-static"' .

FROM moby/buildkit:v0.11.1-rootless

COPY --from=creds /usr/bin/docker-credential-gcr /usr/bin/
RUN docker-credential-gcr configure-docker --registries=eu.gcr.io,europe-docker.pkg.dev

ENV USE_BUILDKIT=true

COPY ./image-builder /image-builder
COPY --from=builder /app/image-builder /image-builder

ENTRYPOINT ["/image-builder"]
ENTRYPOINT ["/image-builder"]
100 changes: 98 additions & 2 deletions prow/jobs/kyma-project/test-infra/images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ presubmits: # runs on PRs
prow.k8s.io/pubsub.runID: "pull-build-image-builder"
prow.k8s.io/pubsub.topic: "prowjobs"
preset-sa-kyma-push-images: "true"
run_if_changed: ^pkg/.*.go|cmd/image-builder/.*.go|^go.mod
run_if_changed: ^pkg/.*.go|cmd/image-builder/.*.go|^go.mod|cmd/image-builder/images/
decorate: true
cluster: untrusted-workload
max_concurrency: 10
Expand Down Expand Up @@ -47,6 +47,54 @@ presubmits: # runs on PRs
- name: config
configMap:
name: kaniko-build-config
- name: pull-build-buildkit-image-builder
annotations:
description: "build buildkit image-builder image"
owner: "neighbors"
labels:
prow.k8s.io/pubsub.project: "sap-kyma-prow"
prow.k8s.io/pubsub.runID: "pull-build-image-builder"
prow.k8s.io/pubsub.topic: "prowjobs"
preset-sa-kyma-push-images: "true"
run_if_changed: ^pkg/.*.go|cmd/image-builder/.*.go|^go.mod|cmd/image-builder/images/
decorate: true
cluster: untrusted-workload
max_concurrency: 10
spec:
containers:
- image: "europe-docker.pkg.dev/kyma-project/prod/image-builder:v20231213-b563bbe4"
securityContext:
privileged: false
seccompProfile:
type: RuntimeDefault
allowPrivilegeEscalation: false
env:
- name: "ADO_PAT"
valueFrom:
secretKeyRef:
name: "image-builder-ado-token"
key: "token"
command:
- "/image-builder"
args:
- "--name=image-builder"
- "--config=/config/kaniko-build-config.yaml"
- "--context=."
- "--dockerfile=cmd/image-builder/images/buildkit/Dockerfile"
- "--build-in-ado=true"
- "--tag=v{{ .Date }}-{{ .ShortSHA }}-buildkit"
resources:
requests:
memory: 500Mi
cpu: 500m
volumeMounts:
- name: config
mountPath: /config
readOnly: true
volumes:
- name: config
configMap:
name: kaniko-build-config
- name: pull-main-build-testimages
decorate: true
labels:
Expand Down Expand Up @@ -91,7 +139,7 @@ postsubmits:
prow.k8s.io/pubsub.runID: "pull-build-image-builder"
prow.k8s.io/pubsub.topic: "prowjobs"
preset-sa-kyma-push-images: "true"
run_if_changed: ^pkg/.*.go|cmd/image-builder/.*.go|^go.mod
run_if_changed: ^pkg/.*.go|cmd/image-builder/.*.go|^go.mod|cmd/image-builder/images/
KacperMalachowski marked this conversation as resolved.
Show resolved Hide resolved
branches:
- main
decorate: true
Expand Down Expand Up @@ -131,6 +179,54 @@ postsubmits:
- name: config
configMap:
name: kaniko-build-config
- name: post-build-buildkit-image-builder
annotations:
description: "build buildkit image-builder image"
owner: "neighbors"
labels:
prow.k8s.io/pubsub.project: "sap-kyma-prow"
prow.k8s.io/pubsub.runID: "pull-build-image-builder"
prow.k8s.io/pubsub.topic: "prowjobs"
preset-sa-kyma-push-images: "true"
run_if_changed: ^pkg/.*.go|cmd/image-builder/.*.go|^go.mod|cmd/image-builder/images/
decorate: true
cluster: trusted-workload
max_concurrency: 10
spec:
containers:
- image: "europe-docker.pkg.dev/kyma-project/prod/image-builder:v20231213-b563bbe4"
securityContext:
privileged: false
seccompProfile:
type: RuntimeDefault
allowPrivilegeEscalation: false
env:
- name: "ADO_PAT"
valueFrom:
secretKeyRef:
name: "image-builder-ado-token"
key: "token"
command:
- "/image-builder"
args:
- "--name=image-builder"
- "--config=/config/kaniko-build-config.yaml"
- "--context=."
- "--dockerfile=cmd/image-builder/images/buildkit/Dockerfile"
- "--build-in-ado=true"
- "--tag=v{{ .Date }}-{{ .ShortSHA }}-buildkit"
resources:
requests:
memory: 500Mi
cpu: 500m
volumeMounts:
- name: config
mountPath: /config
readOnly: true
volumes:
- name: config
configMap:
name: kaniko-build-config
- name: post-main-build-testimages
decorate: true
labels:
Expand Down