Skip to content

Commit 4f91ccf

Browse files
authored
Enable konflux build (#26)
Signed-off-by: Siddhesh Ghadi <[email protected]>
1 parent 948e2bf commit 4f91ccf

File tree

3 files changed

+56
-2
lines changed

3 files changed

+56
-2
lines changed

.konflux/Containerfile.plugin

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Copyright 2023 Red Hat
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
#
15+
# ------------------------------------------------------------------------
16+
FROM registry.redhat.io/openshift4/ose-must-gather:v4.13.0
17+
18+
LABEL \
19+
name="openshift-gitops-1/must-gather-rhel8" \
20+
License="Apache 2.0" \
21+
com.redhat.component="openshift-gitops-must-gather-container" \
22+
com.redhat.delivery.appregistry="false" \
23+
upstream-vcs-type="git" \
24+
summary="OpenShift GitOps Must Gather" \
25+
maintainer="William Tam <[email protected]>" \
26+
io.k8s.display-name="Red Hat OpenShift GitOps Must Gather"\
27+
io.openshift.tags="openshift,gitops-operator, must-gather" \
28+
io.openshift.maintainer.product="Red Hat OpenShift GitOps" \
29+
io.openshift.maintainer.component="William Tam <[email protected]>"
30+
31+
# Save original gather script
32+
RUN mv /usr/bin/gather /usr/bin/gather_original
33+
34+
COPY gather_gitops.sh /usr/bin/gather
35+
36+
# Make it executable
37+
RUN chmod +x /usr/bin/gather
38+
39+
ENTRYPOINT /usr/bin/gather

.tekton/gitops-must-gather-pull-request.yaml

+7-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ spec:
3030
value:
3131
- linux/x86_64
3232
- name: dockerfile
33-
value: Dockerfile
33+
value: .konflux/Containerfile.plugin
34+
- name: hermetic
35+
value: "true"
3436
pipelineSpec:
3537
description: |
3638
This pipeline is ideal for building multi-arch container images from a Containerfile while maintaining trust after pipeline customization.
@@ -232,6 +234,10 @@ spec:
232234
value: $(tasks.prefetch-dependencies.results.CACHI2_ARTIFACT)
233235
- name: IMAGE_APPEND_PLATFORM
234236
value: "true"
237+
- name: LABELS
238+
value:
239+
- upstream-source-url=$(tasks.clone-repository.results.url)
240+
- upstream-source-ref=$(tasks.clone-repository.results.commit)
235241
runAfter:
236242
- prefetch-dependencies
237243
taskRef:

.tekton/gitops-must-gather-push.yaml

+10-1
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,13 @@ spec:
2626
- name: build-platforms
2727
value:
2828
- linux/x86_64
29+
- linux/arm64
30+
- linux/ppc64le
31+
- linux/s390x
2932
- name: dockerfile
30-
value: Dockerfile
33+
value: .konflux/Containerfile.plugin
34+
- name: hermetic
35+
value: "true"
3136
pipelineSpec:
3237
description: |
3338
This pipeline is ideal for building multi-arch container images from a Containerfile while maintaining trust after pipeline customization.
@@ -229,6 +234,10 @@ spec:
229234
value: $(tasks.prefetch-dependencies.results.CACHI2_ARTIFACT)
230235
- name: IMAGE_APPEND_PLATFORM
231236
value: "true"
237+
- name: LABELS
238+
value:
239+
- upstream-source-url=$(tasks.clone-repository.results.url)
240+
- upstream-source-ref=$(tasks.clone-repository.results.commit)
232241
runAfter:
233242
- prefetch-dependencies
234243
taskRef:

0 commit comments

Comments
 (0)