nwex.de/Dockerfile
dependabot 7acbfb0feb
Container: Bump node from 19.8.1-alpine to 19.9.0-alpine
Bumps node from 19.8.1-alpine to 19.9.0-alpine.
2023-05-29 01:39:28 +02:00

26 lines
768 B
Docker

FROM node:19.9.0-alpine as build
WORKDIR /usr/src/app
RUN sed -i 's/dl-cdn/dl-5/g' /etc/apk/repositories && sed -i 's/http:/https:/g' /etc/apk/repositories
COPY package.json /usr/src/app/
COPY package-lock.json /usr/src/app/
RUN npm install --production
COPY . /usr/src/app
RUN npx tsc -p tsconfig.json
RUN cp -r /usr/src/app/src /usr/src/app/public
FROM httpd:2.4.57-alpine
# No access logs
RUN sed -i 's/LoadModule log_config_module modules\/mod_log_config.so//g' /usr/local/apache2/conf/httpd.conf
# Enable rewrite
RUN sed -i '/LoadModule rewrite_module/s/^#//g' /usr/local/apache2/conf/httpd.conf
RUN sed -i 's#AllowOverride [Nn]one#AllowOverride All#' /usr/local/apache2/conf/httpd.conf
COPY --from=build /usr/src/app/public/ /usr/local/apache2/htdocs/