2024-10-21 14:18:05 +02:00
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
#!BuildTag: %%IMG_PREFIX%%cluster-api-operator:%%cluster-api-operator_version%%
|
|
|
|
#!BuildTag: %%IMG_PREFIX%%cluster-api-operator:%%cluster-api-operator_version%%-%RELEASE%
|
|
|
|
#!BuildVersion: 15.6
|
|
|
|
ARG SLE_VERSION
|
|
|
|
FROM registry.suse.com/bci/bci-micro:$SLE_VERSION AS micro
|
|
|
|
|
|
|
|
FROM registry.suse.com/bci/bci-base:$SLE_VERSION AS base
|
|
|
|
COPY --from=micro / /installroot/
|
2024-10-21 15:17:49 +02:00
|
|
|
RUN zypper --installroot /installroot --non-interactive install --no-recommends cluster-api-operator shadow; zypper -n clean; rm -rf /var/log/*
|
2024-10-21 14:18:05 +02:00
|
|
|
|
|
|
|
FROM micro AS final
|
|
|
|
# Define labels according to https://en.opensuse.org/Building_derived_containers
|
|
|
|
# labelprefix=com.suse.application.cluster-api-operator
|
|
|
|
LABEL org.opencontainers.image.authors="SUSE LLC (https://www.suse.com/)"
|
|
|
|
LABEL org.opencontainers.image.title="SLE cluster-api-operator Container Image"
|
|
|
|
LABEL org.opencontainers.image.description="cluster-api-operator based on the SLE Base Container Image."
|
|
|
|
LABEL org.opencontainers.image.version="%%cluster-api-operator_version%%"
|
|
|
|
LABEL org.opencontainers.image.url="https://www.suse.com/products/server/"
|
|
|
|
LABEL org.opencontainers.image.created="%BUILDTIME%"
|
|
|
|
LABEL org.opencontainers.image.vendor="SUSE LLC"
|
|
|
|
LABEL org.opensuse.reference="%%IMG_REPO%%/%%IMG_PREFIX%%cluster-api-operator:%%cluster-api-operator_version%%-%RELEASE%"
|
|
|
|
LABEL org.openbuildservice.disturl="%DISTURL%"
|
|
|
|
LABEL com.suse.supportlevel="l3"
|
|
|
|
LABEL com.suse.eula="SUSE Combined EULA February 2024"
|
|
|
|
LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle"
|
|
|
|
LABEL com.suse.image-type="application"
|
|
|
|
LABEL com.suse.release-stage="released"
|
|
|
|
# endlabelprefix
|
|
|
|
|
|
|
|
COPY --from=base /installroot /
|
|
|
|
RUN mv /usr/bin/cluster-api-operator-controller /manager
|
|
|
|
# Use uid of nonroot user (65532) because kubernetes expects numeric user when applying pod security policies
|
|
|
|
USER 65532
|
|
|
|
ENTRYPOINT [ "/manager" ]
|