Skip to content

Commit c1b4451

Browse files
shruti-rhjbpratt
authored andcommitted
contrib: Add Containerfile.art and artifacts.lock.yaml for ART onboarding
Adds contrib/art/Containerfile.art with ART-compatible labels for building Clair container images through the Konflux pipeline for Red Hat OpenShift releases. The file uses COPY directives to fetch JSON data files (repository-to-cpe.json and container-name-repos-map.json) that are prefetched by cachi2 during the build phase. Creates artifacts.lock.yaml in the repository root to declare the data file artifacts for cachi2 prefetch. Files are downloaded and verified with SHA256 checksums during prefetch and made available at /cachi2/output/deps/generic/ for the build phase. This enables both hermetic and open builds without external network calls during the container build. Updates .dockerignore to allow contrib/art/ files through to the build context. Tracking: ART-19361 Signed-off-by: Shruti Anekar <sanekar@redhat.com>
1 parent a5264d8 commit c1b4451

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

contrib/art/Containerfile.art

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ LABEL io.k8s.description="Clair vulnerability scanner for Red Hat Quay"
1818
LABEL io.openshift.tags="quay,clair,security"
1919
LABEL summary="Clair vulnerability scanner for Red Hat Quay"
2020
LABEL description="Clair vulnerability scanner for Red Hat Quay"
21-
#LABEL cpe="cpe:/a:redhat:quay::el9"
21+
LABEL cpe="cpe:/a:redhat:quay::el9"
2222
LABEL vendor="Red Hat, Inc."
2323
LABEL distribution-scope="restricted"
2424
LABEL url="https://docs.redhat.com/en/documentation/red_hat_quay"
@@ -33,9 +33,9 @@ ENV CLAIR_CONF=/config/config.yaml \
3333
CLAIR_MODE=combo \
3434
SSL_CERT_DIR="/etc/ssl/certs:/etc/pki/tls/certs:/var/run/certs"
3535

36-
USER nobody:nobody
36+
RUN mkdir -p /data && cp /cachi2/output/deps/generic/repository-to-cpe.json /cachi2/output/deps/generic/container-name-repos-map.json /data/
3737

3838
COPY --from=build /app/clair /bin/clair
3939
COPY --from=build /app/clairctl /bin/clairctl
40-
ADD https://raw.githubusercontent.com/quay/quay-konflux-components/redhat-3.17/components/clair/data/repository-to-cpe.json /data/
41-
ADD https://raw.githubusercontent.com/quay/quay-konflux-components/redhat-3.17/components/clair/data/container-name-repos-map.json /data/
40+
41+
USER nobody:nobody

0 commit comments

Comments
 (0)