mirror of
https://code.lenaisten.de/Lenaisten/advent22.git
synced 2024-11-22 07:43:00 +00:00
DockerImage
This commit is contained in:
parent
776298a357
commit
2d864dd57f
2 changed files with 45 additions and 0 deletions
27
.dockerignore
Normal file
27
.dockerignore
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
# commonly found
|
||||||
|
**/.git
|
||||||
|
**/.idea
|
||||||
|
**/.DS_Store
|
||||||
|
**/.vscode
|
||||||
|
**/.devcontainer
|
||||||
|
|
||||||
|
**/dist
|
||||||
|
**/.gitignore
|
||||||
|
**/Dockerfile
|
||||||
|
**/.dockerignore
|
||||||
|
|
||||||
|
# found in python and JS dirs
|
||||||
|
**/__pycache__
|
||||||
|
**/node_modules
|
||||||
|
**/.pytest_cache
|
||||||
|
|
||||||
|
# env files
|
||||||
|
**/.env
|
||||||
|
**/.env.local
|
||||||
|
**/.env.*.local
|
||||||
|
|
||||||
|
# log files
|
||||||
|
**/npm-debug.log*
|
||||||
|
**/yarn-debug.log*
|
||||||
|
**/yarn-error.log*
|
||||||
|
**/pnpm-debug.log*
|
18
Dockerfile
Normal file
18
Dockerfile
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
FROM node:lts AS uibuild
|
||||||
|
WORKDIR /usr/src/app
|
||||||
|
COPY ui/package*.json ui/yarn*.lock ./
|
||||||
|
RUN yarn --production=false
|
||||||
|
COPY ui ./
|
||||||
|
RUN yarn build
|
||||||
|
|
||||||
|
FROM tiangolo/uvicorn-gunicorn:python3.11-slim
|
||||||
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
|
ENV \
|
||||||
|
PRODUCTION_MODE="true" \
|
||||||
|
APP_MODULE="advent22_api.app:app"
|
||||||
|
|
||||||
|
COPY api ./
|
||||||
|
RUN python -m pip --no-cache-dir install ./
|
||||||
|
COPY --from=uibuild /usr/src/app/dist /html
|
||||||
|
|
Loading…
Reference in a new issue