Browse Source

Mounting of local code as a volume inside the container

master
rodley82 3 years ago
parent
commit
b3bc80a407
  1. 1
      Dockerfile
  2. 4
      docker-compose.yml

1
Dockerfile

@ -27,7 +27,6 @@ ENV GO111MODULE on
# Only for development so we can later use reflex -r '\.go$' make all # Only for development so we can later use reflex -r '\.go$' make all
# RUN go install github.com/cespare/reflex@latest && \ # RUN go install github.com/cespare/reflex@latest && \
# go install github.com/go-delve/delve/cmd/dlv@latest && \ # go install github.com/go-delve/delve/cmd/dlv@latest && \
# go install github.com/tc-hib/go-winres@latest
WORKDIR ${PROJECT_USER_APP_HOME} WORKDIR ${PROJECT_USER_APP_HOME}
COPY --chown=${PROJECT_USER}:${PROJECT_USER} go.mod ./ COPY --chown=${PROJECT_USER}:${PROJECT_USER} go.mod ./

4
docker-compose.yml

@ -3,9 +3,11 @@ services:
catchy-cat: catchy-cat:
image: catchy-cat image: catchy-cat
build: . build: .
# command: ./catchy-cat command: "tail -f /dev/null"
environment: environment:
- PORT=3000 - PORT=3000
- DESTINATION_PATH="./" - DESTINATION_PATH="./"
ports: ports:
- "3000:3000" - "3000:3000"
volumes:
- "./:/go/src/github.com/rodley82/catchy-cat/"

Loading…
Cancel
Save