Fixing docker build.
This commit is contained in:
parent
88912e1c65
commit
cf33a39129
|
@ -20,7 +20,7 @@ RUN cargo build --release
|
||||||
|
|
||||||
FROM debian:jessie-slim as volume
|
FROM debian:jessie-slim as volume
|
||||||
COPY torrents.csv /db/
|
COPY torrents.csv /db/
|
||||||
COPY torrent_files.json /db/
|
COPY torrent_files.csv /db/
|
||||||
|
|
||||||
FROM debian:jessie-slim
|
FROM debian:jessie-slim
|
||||||
RUN apt update && apt install -y sqlite3 curl
|
RUN apt update && apt install -y sqlite3 curl
|
||||||
|
@ -33,7 +33,7 @@ RUN mv jq-linux64 /usr/bin/jq
|
||||||
COPY --from=node /app/server/ui/dist /app/dist
|
COPY --from=node /app/server/ui/dist /app/dist
|
||||||
COPY --from=rust /app/server/service/target/release/torrents-csv-service /app/
|
COPY --from=rust /app/server/service/target/release/torrents-csv-service /app/
|
||||||
COPY --from=volume /db/torrents.csv /app/
|
COPY --from=volume /db/torrents.csv /app/
|
||||||
COPY --from=volume /db/torrent_files.json /app/
|
COPY --from=volume /db/torrent_files.csv /app/
|
||||||
COPY scripts /app/scripts
|
COPY scripts /app/scripts
|
||||||
WORKDIR /app/scripts/
|
WORKDIR /app/scripts/
|
||||||
RUN ["/bin/bash", "./build_sqlite.sh"]
|
RUN ["/bin/bash", "./build_sqlite.sh"]
|
||||||
|
|
|
@ -35,7 +35,7 @@ git clone https://gitlab.com/dessalines/torrents.csv
|
||||||
cd torrents.csv/scripts
|
cd torrents.csv/scripts
|
||||||
./webserver.sh
|
./webserver.sh
|
||||||
```
|
```
|
||||||
and goto http://localhost:8080
|
and goto http://localhost:8902
|
||||||
|
|
||||||
If running on a different host, run `export TORRENTS_CSV_ENDPOINT=http://whatever.com` to change the hostname, or use a reverse proxy with nginx or apache2.
|
If running on a different host, run `export TORRENTS_CSV_ENDPOINT=http://whatever.com` to change the hostname, or use a reverse proxy with nginx or apache2.
|
||||||
|
|
||||||
|
@ -100,7 +100,7 @@ cd torrents.csv/scripts
|
||||||
## API
|
## API
|
||||||
A JSON output of search results is available at:
|
A JSON output of search results is available at:
|
||||||
|
|
||||||
http://localhost:8080/service/search?q=[QUERY]&size=[NUMBER_OF_RESULTS]&offset=[PAGE]
|
http://localhost:8902/service/search?q=[QUERY]&size=[NUMBER_OF_RESULTS]&offset=[PAGE]
|
||||||
|
|
||||||
## How the torrents.csv file looks
|
## How the torrents.csv file looks
|
||||||
```sh
|
```sh
|
||||||
|
|
|
@ -7,7 +7,7 @@ services:
|
||||||
command: /bin/sh -c /app/torrents-csv-service
|
command: /bin/sh -c /app/torrents-csv-service
|
||||||
restart: always
|
restart: always
|
||||||
ports:
|
ports:
|
||||||
- "8080:8080"
|
- "8902:8080"
|
||||||
environment:
|
environment:
|
||||||
TORRENTS_CSV_DB_FILE: /app/torrents.db
|
TORRENTS_CSV_DB_FILE: /app/torrents.db
|
||||||
TORRENTS_CSV_FRONT_END_DIR: /app/dist
|
TORRENTS_CSV_FRONT_END_DIR: /app/dist
|
||||||
|
|
Loading…
Reference in New Issue