Skip to content

Commit

Permalink
Merge pull request #75 from citahub/fix-missing-assets-in-docker
Browse files Browse the repository at this point in the history
fix: copy precompiled assets to web docker image
  • Loading branch information
rainchen authored Jul 17, 2020
2 parents 632e5a3 + c26a254 commit 04ababf
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,5 @@
tmp
docker/data
node_modules
.DS_Store
yarn-error.log
5 changes: 3 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ services:
volumes:
- ./docker/data:/var/lib/postgresql/data
app:
image: cyton_dapps_app
build:
context: .
dockerfile: ./docker/app/Dockerfile
volumes:
- .:/app
# volumes:
# - .:/app # for local debug
command: bundle exec puma -C config/puma.docker.rb
depends_on:
- db
Expand Down
4 changes: 2 additions & 2 deletions docker/web/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ WORKDIR $RAILS_ROOT
# create log directory
RUN mkdir log

# copy over static assets
COPY public public/
# copy over static assets from rails app docker image
COPY --from=cyton_dapps_app:latest /app/public public/

# Copy Nginx config template
COPY docker/web/nginx.conf /tmp/docker.nginx
Expand Down

0 comments on commit 04ababf

Please sign in to comment.