From 55ce37e05fae88c215e0aaf3fed2fd057caa20f7 Mon Sep 17 00:00:00 2001 From: swaggboi Date: Sat, 6 Mar 2021 21:54:51 -0500 Subject: [PATCH] Add Dockerfile --- Dockerfile | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..54e42c3 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,30 @@ +FROM perl:5.32 + +# Dependency time +RUN apt-get update +RUN apt-get -y install --install-suggests fortune-mod +RUN cpanm CGI +RUN cpanm CGI::Carp +RUN cpanm Mojolicious +RUN cpanm Mojolicious::Plugin::CGI +RUN cpanm Number::Format +RUN cpanm Regexp::Common +RUN cpanm WebService::Mattermost +RUN cpanm XML::LibXML + +# Move it +WORKDIR /opt +COPY cgi-bin/ ./cgi-bin/ +COPY public/ ./public/ +COPY templates/ ./templates/ +COPY .counts . +COPY .mmCreds.xml . +COPY .msg.bans . +COPY .name.bans . +COPY www-swagg.pl . + +# Finish setting up the environment +ENV MOJO_REVERSE_PROXY=1 + +# Send it +CMD ["perl", "www-swagg.pl", "daemon", "-m", "production"]