Skip to content

Commit ca7bb7f

Browse files
authored
Try fixing enterprise contracts (again...) (#154)
Signed-off-by: Sergio Arroutbi <[email protected]>
1 parent cb99254 commit ca7bb7f

5 files changed

+27
-21
lines changed

.tekton/fbc-4-18-bundle-pull-request.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ spec:
2828
value: 5d
2929
- name: dockerfile
3030
value: bundle.konflux.Dockerfile
31+
- name: hermetic
32+
value: "true"
3133
pipelineSpec:
3234
description: |
3335
This pipeline is ideal for building container images from a Containerfile while maintaining trust after pipeline customization.

.tekton/fbc-4-18-bundle-push.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ spec:
2525
value: quay.io/redhat-user-workloads/konflux-sec-eng-spec-tenant/fbc-4-18-bundle:{{revision}}
2626
- name: dockerfile
2727
value: bundle.konflux.Dockerfile
28+
- name: hermetic
29+
value: "true"
2830
pipelineSpec:
2931
description: |
3032
This pipeline is ideal for building container images from a Containerfile while maintaining trust after pipeline customization.

.tekton/nbde-tang-server-multiarch-pull-request.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ spec:
2828
value: 5d
2929
- name: dockerfile
3030
value: Dockerfile
31+
- name: hermetic
32+
value: "true"
3133
pipelineSpec:
3234
description: |
3335
This pipeline is ideal for building multi-arch container images from a Containerfile while maintaining trust after pipeline customization.

.tekton/nbde-tang-server-multiarch-push.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ spec:
2525
value: quay.io/redhat-user-workloads/konflux-sec-eng-spec-tenant/nbde-tang-server-multiarch:{{revision}}
2626
- name: dockerfile
2727
value: Dockerfile
28+
- name: hermetic
29+
value: "true"
2830
pipelineSpec:
2931
description: |
3032
This pipeline is ideal for building multi-arch container images from a Containerfile while maintaining trust after pipeline customization.

bundle.konflux.Dockerfile

Lines changed: 19 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,20 @@
11
##### UNCOMMENT NEXT BLOCK OF CODE ONCE IMAGE SUBSTITUTION IS CLARIFIED:
2-
# FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_1.22 as builder
2+
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_1.22 as builder
33
#
44
# TODO: Set image to correct version
5-
# ARG IMG=quay.io/sec-eng-special/nbde-tang-server:v1.1.0
6-
# ARG ORIGINAL_IMG=quay.io/sec-eng-special/nbde-tang-server:v1.1.0
7-
# WORKDIR /code
8-
# COPY ./ ./
5+
ARG IMG=registry.redhat.io/nbde-tang-server/tang-rhel9-operator@sha256:562e5f1677dbf5cd9feb00a7270e78c57b28f5177a7bf4bd2d39b2a5cd451da8
6+
ARG ORIGINAL_IMG=quay.io/sec-eng-special/nbde-tang-server:v1.1.0
7+
WORKDIR /code
8+
COPY ./ ./
99
#
10-
# RUN echo "SNAPSHOT=${SNAPSHOT}"
11-
# RUN bash -c printenv
12-
# RUN echo "IMAGE_VERSION=$(echo '${SNAPSHOT}' | base64 -d | jq -r '.components[].containerImage')"
13-
# Replace the bundle image in the repository with the one specified by the IMG build argument.
14-
# TODO: Replace bundle appropriately once image is changed
15-
# RUN chmod -R g+rwX ./ && find bundle/ && find bundle -type f -exec sed -i \
16-
# "s|${ORIGINAL_IMG}|$(echo '${SNAPSHOT}' | base64 -d | jq -r '.components[].containerImage')|g" {} \+; \
17-
# grep -rq "${ORIGINAL_IMG}" bundle/ && \
18-
# { echo "Failed to replace image references"; exit 1; } || echo "Image references replaced" && \
19-
# grep -r "${IMG}" bundle/
10+
RUN echo "SNAPSHOT=${SNAPSHOT}"
11+
RUN bash -c printenv
12+
# Replace the bundle image in the repository with the one specified by the IMG build argument.
13+
# TODO: Replace bundle appropriately once image is changed
14+
RUN chmod -R g+rwX ./ && find bundle/ && find bundle -type f -exec sed -i \
15+
"s|${ORIGINAL_IMG}|${IMG})|g" {} \+; grep -rq "${ORIGINAL_IMG}" bundle/ && \
16+
{ echo "Failed to replace image references"; exit 1; } || echo "Image references replaced" && \
17+
grep -r "${IMG}" bundle/
2018

2119
FROM registry.access.redhat.com/ubi9/ubi-micro@sha256:7f376b75faf8ea546f28f8529c37d24adcde33dca4103f4897ae19a43d58192b
2220

@@ -49,12 +47,12 @@ LABEL operators.operatorframework.io.test.mediatype.v1=scorecard+v1
4947
LABEL operators.operatorframework.io.test.config.v1=tests/scorecard/
5048

5149
### Copy files to locations specified by labels
52-
# COPY --from=builder /code/bundle/manifests /manifests/
53-
# COPY --from=builder /code/bundle/metadata /metadata/
54-
# COPY --from=builder /code/bundle/tests/scorecard /tests/scorecard/
55-
COPY bundle/manifests /manifests/
56-
COPY bundle/metadata /metadata/
57-
COPY bundle/tests/scorecard /tests/scorecard/
50+
COPY --from=builder /code/bundle/manifests /manifests/
51+
COPY --from=builder /code/bundle/metadata /metadata/
52+
COPY --from=builder /code/bundle/tests/scorecard /tests/scorecard/
53+
#COPY bundle/manifests /manifests/
54+
#COPY bundle/metadata /metadata/
55+
#COPY bundle/tests/scorecard /tests/scorecard/
5856

5957
# Copy LICENSE to /licenses directory
6058
COPY LICENSE /licenses/

0 commit comments

Comments
 (0)