add dockerfile
This commit is contained in:
parent
bd3efb6812
commit
6ca62dba6e
3 changed files with 25 additions and 0 deletions
2
.dockerignore
Normal file
2
.dockerignore
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
node_modules/
|
||||||
|
docs/.vuepress/dist/
|
12
Dockerfile
Normal file
12
Dockerfile
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
FROM node:lts-buster AS build
|
||||||
|
WORKDIR /src
|
||||||
|
COPY . .
|
||||||
|
RUN yarn
|
||||||
|
RUN yarn build
|
||||||
|
|
||||||
|
FROM httpd:latest AS final
|
||||||
|
WORKDIR /usr/local/apache2/htdocs/
|
||||||
|
COPY --from=build /src/docs/.vuepress/dist .
|
||||||
|
|
||||||
|
EXPOSE 80
|
||||||
|
CMD ["httpd-foreground"]
|
11
docker-compose.yml
Normal file
11
docker-compose.yml
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
version: '3.7'
|
||||||
|
|
||||||
|
services:
|
||||||
|
gct_generator:
|
||||||
|
container_name: gct_generator
|
||||||
|
build:
|
||||||
|
context: ./
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
network_mode: 'bridge'
|
||||||
|
ports:
|
||||||
|
- '8080:80'
|
Loading…
Reference in a new issue