mylogger/Dockerfile

42 lines
877 B
Docker
Raw Permalink Normal View History

2023-04-08 13:08:37 +00:00
FROM debian:bullseye-slim
ARG DEBIAN_FRONTEND=noninteractive
# NodeJs
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
curl \
ca-certificates \
gnupg2 \
git \
2023-04-10 12:11:36 +00:00
&& curl -fsSL https://deb.nodesource.com/setup_14.x | bash - \
2023-04-11 10:14:55 +00:00
&& apt-get install -y --no-install-recommends nodejs \
&& rm -rf /var/lib/apt/lists/* \
&& npm i -g npm@9.6.4
2023-04-08 13:08:37 +00:00
2023-04-10 12:11:36 +00:00
# MyLogger
2023-04-08 13:08:37 +00:00
2023-04-10 12:11:36 +00:00
WORKDIR /mylogger
2023-04-11 18:26:17 +00:00
COPY package.json package-lock.json ./
RUN npm install --omit=dev \
&& git clone --depth 1 --branch fix-143 https://github.com/juan-ferrer-toribio/zongji.git \
&& (cd zongji && npm install --omit=dev)
2023-04-08 13:08:37 +00:00
ARG BUILD_ID=unknown
ARG VERSION
ENV VERSION $VERSION
RUN echo $VERSION
COPY lib lib
COPY config config
2023-04-08 13:08:37 +00:00
COPY \
LICENSE \
README.md \
mylogger.js \
index.js \
./
2023-04-11 18:22:45 +00:00
ENV TZ Europe/Madrid
2023-04-10 12:11:36 +00:00
CMD ["node", "index.js"]