Docker changes

This commit is contained in:
Dessalines 2019-04-09 21:29:13 -07:00
parent 3aaba47a52
commit 655e84a87f
2 changed files with 2 additions and 4 deletions

View File

@ -5,6 +5,7 @@ RUN cd /app/server/ui && yarn && yarn build
FROM rust:1.33 as rust FROM rust:1.33 as rust
COPY server/service /app/server/service COPY server/service /app/server/service
WORKDIR /app/server/service
RUN cd /app/server/service && cargo build --release RUN cd /app/server/service && cargo build --release
FROM debian:jessie-slim as volume FROM debian:jessie-slim as volume
@ -26,9 +27,5 @@ COPY --from=volume /db/torrent_files.json /app/
COPY scripts /app/scripts COPY scripts /app/scripts
WORKDIR /app/scripts/ WORKDIR /app/scripts/
RUN ["/bin/bash", "-c", "/app/scripts/build_sqlite.sh"] RUN ["/bin/bash", "-c", "/app/scripts/build_sqlite.sh"]
EXPOSE 8080 EXPOSE 8080
WORKDIR /app/ WORKDIR /app/
ARG TORRENTS_CSV_DB_FILE
RUN sqlite3 ${TORRENTS_CSV_DB_FILE} 'select * from torrents limit 10'

View File

@ -5,6 +5,7 @@ services:
build: build:
context: . context: .
command: /bin/sh -c /app/torrents-csv-service command: /bin/sh -c /app/torrents-csv-service
restart: always
ports: ports:
- "8080:8080" - "8080:8080"
environment: environment: