2023-10-24 12:07:05 +00:00
|
|
|
FROM debian:bookworm-slim
|
2018-12-27 11:54:16 +00:00
|
|
|
EXPOSE 80
|
2019-02-25 13:02:47 +00:00
|
|
|
ENV TZ Europe/Madrid
|
2016-11-17 09:18:11 +00:00
|
|
|
|
2018-12-27 11:54:16 +00:00
|
|
|
ARG DEBIAN_FRONTEND=noninteractive
|
|
|
|
RUN apt-get update \
|
2019-01-08 17:46:14 +00:00
|
|
|
&& apt-get install -y --no-install-recommends nginx \
|
2019-01-08 19:09:55 +00:00
|
|
|
&& rm -rf /var/lib/apt/lists/* \
|
|
|
|
&& ln -sf /dev/stdout /var/log/nginx/access.log \
|
2019-01-04 12:32:04 +00:00
|
|
|
&& ln -sf /dev/stderr /var/log/nginx/error.log
|
|
|
|
|
2018-12-31 13:02:46 +00:00
|
|
|
WORKDIR /etc/nginx
|
2019-01-25 22:02:29 +00:00
|
|
|
COPY front/nginx.conf sites-available/salix
|
2018-12-31 13:02:46 +00:00
|
|
|
RUN rm sites-enabled/default && ln -s ../sites-available/salix sites-enabled/salix
|
|
|
|
|
|
|
|
COPY dist /salix/dist
|
2016-11-17 09:18:11 +00:00
|
|
|
|
2018-12-31 13:02:46 +00:00
|
|
|
CMD ["nginx", "-g", "daemon off;"]
|
2024-01-16 14:09:06 +00:00
|
|
|
|
|
|
|
FROM back AS local
|
|
|
|
EXPOSE 5000
|
|
|
|
|
|
|
|
WORKDIR /salix
|
|
|
|
COPY /front/gulpfile.js ./
|
|
|
|
COPY /front/webpack.config.js ./
|
|
|
|
COPY /front/package.json ./front/
|
|
|
|
|
|
|
|
CMD ["npx", "gulp", "front"]
|
|
|
|
|
|
|
|
FROM back AS test
|
|
|
|
EXPOSE 5000
|
|
|
|
WORKDIR /salix
|
|
|
|
|
|
|
|
COPY front front
|
|
|
|
# RUN npm i -g jest
|
|
|
|
RUN cd front && npm install --ci
|
|
|
|
|
|
|
|
COPY modules modules
|
|
|
|
# COPY dist dist
|
|
|
|
COPY jest-front.js ./
|
|
|
|
COPY jest.front.config.js ./
|
|
|
|
COPY babel.config.js ./
|
|
|
|
COPY fileMock.js ./
|
|
|
|
|
|
|
|
COPY /front/gulpfile.js ./
|
|
|
|
COPY /front/webpack.config.js ./
|
|
|
|
COPY /front/salix ./front/salix
|
|
|
|
COPY /front/core ./front/core
|
|
|
|
|
|
|
|
CMD ["npx", "gulp", "front"]
|
|
|
|
|