1d434f7
FROM registry.fedoraproject.org/f30/s2i-base:latest
9904e2e
9904e2e
ENV NAME=golang \
9904e2e
    VERSION=1.11 \
9904e2e
    ARCH=x86_64
9904e2e
9904e2e
ENV SUMMARY="Platform for building and running Go $VERSION based applications" \
9904e2e
    DESCRIPTION="Go $VERSION available as container is a base platform for \
9904e2e
building and running various Go $VERSION applications and frameworks. \
9904e2e
Go is an easy to learn, powerful, statically typed language in the C/C++ \
9904e2e
tradition with garbage collection, concurrent programming support, and memory safety features."
9904e2e
9904e2e
LABEL summary="$SUMMARY" \
9904e2e
      description="$DESCRIPTION" \
9904e2e
      io.k8s.description="$DESCRIPTION" \
9904e2e
      io.k8s.display-name="Go $VERSION" \
9904e2e
      io.openshift.tags="builder,golang,golang18,rh-golang18,go" \
9904e2e
      com.redhat.component="$NAME" \
9904e2e
      name="$FGC/$NAME" \
9904e2e
      version="$VERSION" \
9904e2e
      architecture="$ARCH" \
1d434f7
      maintainer="Jakub Cajka <jcajka@fedoraproject.org>" \
9904e2e
      usage="docker run $FGC/$NAME"
9904e2e
9904e2e
RUN INSTALL_PKGS="golang" && \
9904e2e
    dnf install -y --setopt=tsflags=nodocs $INSTALL_PKGS && \
9904e2e
    rpm -V $INSTALL_PKGS && \
9904e2e
    dnf clean all -y
9904e2e
9904e2e
# Copy the S2I scripts from the specific language image to $STI_SCRIPTS_PATH.
9904e2e
COPY ./s2i/bin/ $STI_SCRIPTS_PATH
1d434f7
# Copy manpage
1d434f7
COPY ./root/help.1 /
9904e2e
9904e2e
RUN chown -R 1001:0 $STI_SCRIPTS_PATH && chown -R 1001:0 /opt/app-root
9904e2e
9904e2e
USER 1001
9904e2e
9904e2e
# Set the default CMD to print the usage of the language image.
9904e2e
CMD $STI_SCRIPTS_PATH/usage