9f2df2b
FROM {{ config.docker.from }}
9f2df2b
9f2df2b
LABEL MAINTAINER ...
9f2df2b
9f2df2b
ENV NAME=mycontainer VERSION=0 RELEASE=1 ARCH=x86_64
9f2df2b
9f2df2b
LABEL summary="A container that tells you how awesome it is." \
9f2df2b
      com.redhat.component="$NAME" \
9f2df2b
      version="$VERSION" \
9f2df2b
      release="$RELEASE.$DISTTAG" \
9f2df2b
      architecture="$ARCH" \
9f2df2b
      usage="docker run -p 9000:9000 mycontainer" \
9f2df2b
      help="Runs mycontainer, which listens on port 9000 and tells you how awesome it is. No dependencies." \
9f2df2b
      description="{{ spec.description }}" \
9f2df2b
      vendor="{{ spec.vendor }}" \
9f2df2b
      org.fedoraproject.component="postfix" \
9f2df2b
      authoritative-source-url="{{ spec.authoritative_source_url }}" \
9f2df2b
      io.k8s.description="{{ spec.description }}" \
9f2df2b
      io.k8s.display-name="Awesome container with SW version {{ spec.software_version }}" \
9f2df2b
      io.openshift.expose-services="9000:http" \
9f2df2b
      io.openshift.tags="some,tags"
9f2df2b
9f2df2b
EXPOSE 9000
9f2df2b
9f2df2b
# We don't actually use the "software_version" here, but we could,
9f2df2b
#  e.g. to install a module with that ncat version
9f2df2b
RUN {{ commands.pkginstaller.install(['nmap-ncat']) }} && \
9f2df2b
    {{ commands.pkginstaller.cleancache() }}
9f2df2b
9f2df2b
RUN echo {{ spec.spam }}
9f2df2b
RUN echo {{ spec.version }}
9f2df2b
9f2df2b
# add help file
9f2df2b
#  NOTE: this file is rendered from help.md, it's not actually templated (help.md is)
9f2df2b
COPY root/help.1 /
9f2df2b
COPY script.sh /usr/bin/
9f2df2b
9f2df2b
CMD ["/usr/bin/script.sh"]