Last active
October 26, 2015 09:00
-
-
Save scastrec/2a5afb310630d1a11eba to your computer and use it in GitHub Desktop.
Dockerfile for NodeJS + generating PDF with phantom-html2pdf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM centos:centos7 | |
# Enable EPEL for Node.js | |
RUN rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm | |
# Install Node.js and npm | |
RUN yum install -y npm | |
# Install bzip2 | |
RUN yum install -y bzip2 | |
# Install lib for phantom | |
RUN yum install -y freetype | |
# More deps | |
RUN yum install -y libXext libXrender fontconfig libfontconfig.so.1 | |
# fonts | |
RUN yum install -y urw-fonts | |
# Bundle app source | |
COPY ./app/ /opt/app | |
# Install app dependencies | |
RUN cd /opt/money; ls; npm install /opt/money | |
COPY ./app/printables /printables | |
CMD ["node", "/opt/app/src/main.js"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment