mirror of
https://github.com/codex-team/codex.docs.git
synced 2025-08-08 06:55:26 +02:00
Implement development docker support
This commit is contained in:
parent
c0a4f6f3fd
commit
c6534ff996
2 changed files with 30 additions and 0 deletions
14
docker-compose.dev.yml
Normal file
14
docker-compose.dev.yml
Normal file
|
@ -0,0 +1,14 @@
|
|||
version: "3.2"
|
||||
services:
|
||||
docs:
|
||||
build:
|
||||
dockerfile: "docker/Dockerfile.dev"
|
||||
context: .
|
||||
user: "node"
|
||||
volumes:
|
||||
- ./:/usr/src/app
|
||||
- /usr/src/app/node_modules
|
||||
ports:
|
||||
- "3000:3000"
|
||||
stdin_open: true
|
||||
tty: true
|
16
docker/Dockerfile.dev
Normal file
16
docker/Dockerfile.dev
Normal file
|
@ -0,0 +1,16 @@
|
|||
FROM node:10-alpine as builder
|
||||
|
||||
WORKDIR /usr/src/app
|
||||
RUN apk add --no-cache git gcc g++ python make musl-dev
|
||||
|
||||
COPY package.json yarn.lock ./
|
||||
|
||||
RUN yarn install
|
||||
|
||||
FROM node:10-alpine
|
||||
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
COPY --from=builder /usr/src/app/node_modules ./node_modules
|
||||
|
||||
CMD ["yarn", "start:dev"]
|
Loading…
Add table
Add a link
Reference in a new issue