Skip to content

Commit

Permalink
Merge pull request #1 from mustyoshi/task/docker-cache
Browse files Browse the repository at this point in the history
Docker Cache
  • Loading branch information
mustyoshi authored Nov 23, 2019
2 parents b2a92e6 + 2d2bcf6 commit cdaa7d0
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 75 deletions.
16 changes: 7 additions & 9 deletions .docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@ services:
- ../backend:/usr/src/app/
ports:
- "9090:9090"
entrypoint:
- "bash"
- "start.sh"
depends_on:
- congress_postgres
networks:
Expand All @@ -31,18 +28,17 @@ services:
stdin_open: true
environment:
- STAGE=dev
- CHOKIDAR_USEPOLLING=true
build:
context: ../frontend
dockerfile: .docker/Dockerfile
volumes:
- ../frontend:/usr/src/app
- ../frontend/public:/usr/src/app/public
- ../frontend/src:/usr/src/app/src
ports:
- "80:3000"
networks:
parser:
entrypoint:
- "bash"
- "start.sh"
# nginx:
# image: nginx
# ports:
Expand All @@ -63,10 +59,12 @@ services:
POSTGRES_USER: parser
POSTGRES_DB: us_code
volumes:
- /opt/congress/postgres:/var/lib/postgresql/data
- postgres-volume:/var/lib/postgresql/data
networks:
parser:
networks:
parser:
external:
name: docker_parser
name: docker_parser
volumes:
postgres-volume:
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
**.pyc
**/node_modules
**/node_modules
6 changes: 4 additions & 2 deletions backend/.docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from python:3.7.4-slim-stretch
FROM python:3.7.4-slim-stretch

RUN apt update
RUN apt install wget -y
Expand All @@ -11,4 +11,6 @@ WORKDIR /usr/src/app

EXPOSE 9090
EXPOSE 80
ENTRYPOINT ["bash"]

ENTRYPOINT "python"
CMD ["-m", "billparser"]
25 changes: 0 additions & 25 deletions backend/.docker/docker-compose.yaml

This file was deleted.

1 change: 0 additions & 1 deletion backend/start.sh

This file was deleted.

10 changes: 6 additions & 4 deletions frontend/.docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
FROM node

RUN curl -o- -L https://yarnpkg.com/install.sh | bash
WORKDIR /usr/src/app

COPY package.json /usr/src/app/package.json
COPY yarn.lock /usr/src/app/yarn.lock
WORKDIR /usr/src/app
RUN yarn install

COPY . /usr/src/app

COPY ./src /usr/src/app/src
COPY ./public /usr/src/app/public
COPY ./start.sh /usr/src/app/start.sh

ENTRYPOINT [ "bash" ]
ENTRYPOINT ["bash", "start.sh"]
33 changes: 0 additions & 33 deletions frontend/.docker/docker-compose.yaml

This file was deleted.

0 comments on commit cdaa7d0

Please sign in to comment.