🐳 move to new + simple Dockerfile
This commit is contained in:
parent
2cdd1cd961
commit
9202b473f5
16
Dockerfile
16
Dockerfile
@ -1,6 +1,12 @@
|
|||||||
|
FROM node:15.4.0-alpine3.12
|
||||||
|
WORKDIR /app
|
||||||
|
RUN npm i -g pnpm
|
||||||
|
COPY package.json index.html ./
|
||||||
|
RUN pnpm i
|
||||||
|
COPY src ./src
|
||||||
|
COPY public ./public
|
||||||
|
RUN pnpm run build
|
||||||
|
# final image
|
||||||
FROM fholzer/nginx-brotli:v1.19.1
|
FROM fholzer/nginx-brotli:v1.19.1
|
||||||
ENV APP_CONF="config={}"
|
COPY --from=0 /app/dist /usr/share/nginx/html
|
||||||
# TODO: buildstep
|
COPY ./nginx.conf /etc/nginx/nginx.conf
|
||||||
COPY ./dist /usr/share/nginx/html
|
|
||||||
COPY nginx.conf /etc/nginx/conf.d/default.conf.template
|
|
||||||
# COPY ./nginx.conf /etc/nginx/nginx.conf
|
|
@ -1,9 +1,8 @@
|
|||||||
version: '3'
|
version: "3"
|
||||||
services:
|
services:
|
||||||
httpd:
|
httpd:
|
||||||
build: .
|
build: .
|
||||||
environment:
|
volumes:
|
||||||
- APP_CONF=config={"baseUrl":"http://localhost:8081"}
|
- ./dev.env.js:/usr/share/nginx/html/env.js
|
||||||
command: ["sh", "-c", "envsubst < /etc/nginx/conf.d/default.conf.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'"]
|
|
||||||
ports:
|
ports:
|
||||||
- 4050:80
|
- 4050:80
|
||||||
|
5
env.sample.js
Normal file
5
env.sample.js
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
const config = {
|
||||||
|
baseurl: 'https://dev.lauf-fuer-kaya.de',
|
||||||
|
fallback_username: 'admin',
|
||||||
|
fallback_password: '72fpTzsev4xUu78QPs2FCbwZ3'
|
||||||
|
};
|
Loading…
x
Reference in New Issue
Block a user