- or download this
mkdir build
cd build
# Requires mojolicious, you can git clone here also
mojo generate app myapp
- or download this
# cpanfile
requires 'Mojolicious';
# and so on
- or download this
# dockerfile
FROM alpine:latest
...
ENV PERL5LIB=/usr/src/myapp/local/lib/perl5/
CMD [ "script/myapp","daemon","-m","production","-l","http://*:8080" ]
- or download this
# Now to build the image
$ docker build -t myapp-container .
- or download this
# Run the container with host's port 8081
# mapped to container's port 8080 using the cmd from dockerfile.
...
# Save the container
$ docker save myapp-container > myapp-container.tar