docker
This commit is contained in:
parent
0b40da51e6
commit
801003b101
42
.dockerignore
Normal file
42
.dockerignore
Normal file
@ -0,0 +1,42 @@
|
||||
# See https://docs.github.com/get-started/getting-started-with-git/ignoring-files for more about ignoring files.
|
||||
|
||||
# Compiled output
|
||||
/dist
|
||||
/tmp
|
||||
/out-tsc
|
||||
/bazel-out
|
||||
|
||||
# Node
|
||||
/node_modules
|
||||
npm-debug.log
|
||||
yarn-error.log
|
||||
|
||||
# IDEs and editors
|
||||
.idea/
|
||||
.project
|
||||
.classpath
|
||||
.c9/
|
||||
*.launch
|
||||
.settings/
|
||||
*.sublime-workspace
|
||||
|
||||
# Visual Studio Code
|
||||
.vscode/*
|
||||
!.vscode/settings.json
|
||||
!.vscode/tasks.json
|
||||
!.vscode/launch.json
|
||||
!.vscode/extensions.json
|
||||
.history/*
|
||||
|
||||
# Miscellaneous
|
||||
/.angular/cache
|
||||
.sass-cache/
|
||||
/connect.lock
|
||||
/coverage
|
||||
/libpeerconnection.log
|
||||
testem.log
|
||||
/typings
|
||||
|
||||
# System files
|
||||
.DS_Store
|
||||
Thumbs.db
|
22
Dockerfile
Normal file
22
Dockerfile
Normal file
@ -0,0 +1,22 @@
|
||||
FROM node:23-alpine AS build
|
||||
|
||||
ARG config production
|
||||
|
||||
WORKDIR /src
|
||||
COPY package*.json .
|
||||
|
||||
RUN npm install -g @angular/cli
|
||||
RUN npm install
|
||||
|
||||
COPY . /src
|
||||
RUN ng build \
|
||||
--configuration=${config} \
|
||||
--delete-output-path false
|
||||
|
||||
FROM nginx:alpine-slim
|
||||
|
||||
COPY --from=build /src/dist/ui/browser/ /usr/share/nginx/html
|
||||
|
||||
COPY nginx/default.conf /etc/nginx/conf.d/
|
||||
|
||||
EXPOSE 80
|
15
nginx/default.conf
Normal file
15
nginx/default.conf
Normal file
@ -0,0 +1,15 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name localhost;
|
||||
|
||||
root /usr/share/nginx/html;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
error_page 500 502 503 504 /50x.html;
|
||||
location = /50x.html {
|
||||
root /usr/share/nginx/html;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user