WebDyne

 view release on metacpan or  search on metacpan

docker/Dockerfile.tt  view on Meta::CPAN

RUN apt-get update && \
    apt-get install -y \
    perl \
    cpanminus \
    && rm -rf /var/lib/apt/lists/*
[% ELSIF family == 'alpine' %]
RUN apk add --no-cache \
    perl \
    perl-app-cpanminus \
    make
[% ELSIF family == 'fedora' %]
RUN dnf install -y \
    perl \
    perl-core \
    perl-App-cpanminus \
    && dnf clean all
[% ELSIF family == 'perl' %]
#  No extra packages needed
[% END %]


# Install Carton
#
RUN cpanm --notest Carton


# Set up environment for local::lib
#
ENV PERL_CARTON_PATH=${PERL_CARTON_PATH}
ENV PERL5LIB=${PERL_CARTON_PATH}/lib/perl5
ENV PATH=${PERL_CARTON_PATH}/bin:$PATH


# Only psp files go into /app, WebDyne perl modules installed into $PERL_CARTONPATH (/opt/webdyne) 
# by default
#
WORKDIR /app


# Copy CPAN modules from builder + example file
#
COPY --from=builder ${PERL_CARTON_PATH} ${PERL_CARTON_PATH}
COPY docker/app.psp .


# Expose port (default 8080)
#
EXPOSE ${PORT}


# Set document root environment var to the server_time example
#
ENV DOCUMENT_ROOT=${DOCUMENT_ROOT}


# WebDyne environment vars
#
ENV WEBDYNE_CACHE_DN=${PERL_CARTON_PATH}/cache


# Entrypoint script for starting process. Kicks off starman on ${PORT}
#
COPY docker/entrypoint.sh /usr/local/bin
ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]


# Empty cmd, entrypoint script runs "starman --port ${PORT} ${PERL_CARTON_PATH}/bin/webdyne.psgi ${DOCUMENT_ROOT}"
#
CMD []



( run in 0.732 second using v1.01-cache-2.11-cpan-e93a5daba3e )