45 lines
923 B
Docker
45 lines
923 B
Docker
#FROM debian:bullseye-slim
|
|
FROM ubuntu:18.04
|
|
|
|
ENV TZ Europe/Madrid
|
|
|
|
RUN apt-get update \
|
|
&& apt-get install -y --no-install-recommends \
|
|
cups \
|
|
curl \
|
|
ca-certificates \
|
|
sudo
|
|
|
|
RUN curl -fsSL https://deb.nodesource.com/setup_14.x | sudo -E bash - \
|
|
&& apt install -y nodejs \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
WORKDIR /pdf-print-server
|
|
|
|
COPY \
|
|
package.json \
|
|
package-lock.json \
|
|
./
|
|
RUN npm install
|
|
|
|
COPY cupsd.conf /etc/cups/
|
|
|
|
COPY \
|
|
main.js \
|
|
print-server.js \
|
|
config.yml \
|
|
service.js \
|
|
entrypoint.sh \
|
|
./
|
|
COPY sql sql
|
|
COPY tmp tmp
|
|
|
|
COPY GoDEXdriver-1.1.6.tar.gz /tmp/
|
|
RUN (cd /tmp && tar -xf /tmp/GoDEXdriver-1.1.6.tar.gz) \
|
|
&& chmod a+x /tmp/GoDEXdriver-1.1.6/install-driver \
|
|
&& (cd /tmp/GoDEXdriver-1.1.6 && ./install-driver)
|
|
|
|
RUN echo 'root:1234' | chpasswd
|
|
|
|
ENTRYPOINT ["/pdf-print-server/entrypoint.sh"]
|
|
CMD ["node", "main.js"] |