diff --git a/Dockerfile b/Dockerfile index 815f8b9..003bff3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,7 +17,7 @@ RUN cargo install --path . --features vendored FROM alpine -ENV RUST_BACKTRACE "1" +ENV RUST_BACKTRACE "1" COPY --from=build /home/rust/.cargo/bin/datatrash . COPY static ./static diff --git a/README.md b/README.md index 718c803..6066118 100644 --- a/README.md +++ b/README.md @@ -27,12 +27,15 @@ docker-compose up -d --build The static files directory needs to be next to the binary. -| environment variable | default value | -| -------------------- | --------------------- | -| DATABASE_URL | postresql://localhost | -| SERVER_URL | http://loalhost:8000 | -| FILES_DIR | ./files | -| UPLOAD_MAX_BYTES | 8388608 (8MiB) | -| BIND_ADDRESS | 0.0.0.0:8000 | +| environment variable | default value | +| -------------------- | -------------------- | +| DATABASE_URL | | +| DATABASE_USER | | +| DATABASE_PASS | | +| DATABASE_HOST | localhost | +| DATABASE_NAME | datatrash | +| FILES_DIR | ./files | +| UPLOAD_MAX_BYTES | 8388608 (8MiB) | +| BIND_ADDRESS | 0.0.0.0:8000 | The maximum filename length is 255 diff --git a/docker-compose.yml b/docker-compose.yml index ee06609..d5fe39c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -3,7 +3,9 @@ services: datatrash: build: . environment: - DATABASE_URL: 'postgresql://admin:secure@postgres' + DATABASE_USER: admin + DATABASE_PASSWORD: secure + DATABASE_HOST: postgres ports: - '8000:8000' postgres: