Upgrading rust-musl and alpine, adding filter env var.

This commit is contained in:
Dessalines 2020-06-07 18:29:22 -04:00
parent 9ff134e616
commit 0e7d4fc34f
2 changed files with 4 additions and 3 deletions

View file

@ -1,5 +1,5 @@
# Build
FROM ekidd/rust-musl-builder:1.42.0-openssl11 as rust
FROM ekidd/rust-musl-builder:1.44.0 as rust
# Cache deps
WORKDIR /app
@ -17,7 +17,7 @@ COPY src ./src/
# Build for release
RUN cargo build --frozen --release
FROM alpine:3.10
FROM alpine:3.11
# Copy resources
COPY --from=rust /app/server/target/x86_64-unknown-linux-musl/release/pict-rs /app/pict-rs

View file

@ -22,13 +22,14 @@ pub(crate) struct Config {
short,
long,
env = "PICTRS_FORMAT",
help = "An image format to convert all uploaded files into, supports 'jpg' and 'png'"
help = "An optional image format to convert all uploaded files into, supports 'jpg' and 'png'"
)]
format: Option<Format>,
#[structopt(
short,
long,
env = "PICTRS_FILTER_WHITELIST",
help = "An optional list of filters to whitelist, supports 'identity', 'thumbnail', and 'blur'"
)]
whitelist: Option<Vec<String>>,