aboutsummaryrefslogtreecommitdiff
path: root/docker
diff options
context:
space:
mode:
authorDavid Phillips <david@yeah.nah.nz>2020-05-20 17:59:37 +1200
committerDavid Phillips <david@yeah.nah.nz>2020-05-20 17:59:37 +1200
commit8b34d23cb10f1f5aa5de4ba04bacf92b6160075e (patch)
tree2034835335bbd9a47ee60a359a432de290a07a5f /docker
parentb4eb42636ebe66192d0e531bc691b6f38debfbde (diff)
downloadidalius-8b34d23cb10f1f5aa5de4ba04bacf92b6160075e.tar.xz
Add an old Dockerfile
Diffstat (limited to 'docker')
-rw-r--r--docker/Dockerfile30
1 files changed, 30 insertions, 0 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile
new file mode 100644
index 0000000..e33f78c
--- /dev/null
+++ b/docker/Dockerfile
@@ -0,0 +1,30 @@
+FROM alpine:latest
+
+ARG uid=1000
+ARG gid=1000
+
+RUN addgroup -g $gid idalius
+RUN adduser -u $uid -D -G idalius idalius
+
+# Intermediate tools used to build perl modules not provided as apk
+RUN apk add perl perl-dev perl-app-cpanminus make gcc libgcc wget musl-dev openssl openssl-dev zlib-dev
+
+# Perl modules used by idalius
+RUN apk add perl-config-tiny perl-html-parser perl-datetime perl-io-socket-ssl
+
+# Build and install POE and POE::Component::IRC modules
+RUN cpanm install POE POE::Component::IRC
+RUN cpanm install -n POE::Component::SSLify
+
+# Remove non-runtime deps
+RUN apk del perl-dev perl-app-cpanminus make gcc libgcc wget musl-dev
+
+# Remove unneeded caches etc
+RUN rm -rf /root/.cpanm /var/cache/apk/*
+
+USER idalius
+
+# Expect idalius volume mounted to /idalius
+WORKDIR /idalius
+ENV PERL5LIB /idalius
+CMD perl ./idalius.pl