RSS Git Download  Clone
Raw Blame History
FROM perl:5.34.0
WORKDIR /app

# Core OS setup
RUN apt-get update
RUN apt-get install -y build-essential sqlite3 nano

# set timezone:
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y tzdata
RUN unlink /etc/localtime
RUN ln -s /usr/share/zoneinfo/Europe/London /etc/localtime

# Clean up
RUN apt-get clean
# this means apt can no longer find anything, need to run "apt update" again for install any new packages
RUN rm -rf /var/lib/apt/lists/*

# Copy only the files needed for installing dependencies
COPY cpanfile* .
RUN cpanm --notest --installdeps .

# Copy the rest of the application source code
COPY . .

# Run the application
# CMD [ "starman", "bin/app.psgi" ] # don't need high-performance server for 1 sporadic user
CMD [ "plackup", "-E", "deployment", "bin/app.psgi" ]