diff options
author | Dessalines <tyhou13@gmx.com> | 2019-11-01 23:41:57 -0700 |
---|---|---|
committer | Dessalines <tyhou13@gmx.com> | 2019-11-01 23:41:57 -0700 |
commit | 68e4b61808ee76730cdc9f4302700a60a2ebb3b5 (patch) | |
tree | 8d36fb7b39b963696dc980f89f836b52c4aea20a /docker/dev/Dockerfile | |
parent | 9f35b33dc7238f0d6748beafa79ca0af192b5ca6 (diff) |
Password reset mostly working.
Diffstat (limited to 'docker/dev/Dockerfile')
-rw-r--r-- | docker/dev/Dockerfile | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/docker/dev/Dockerfile b/docker/dev/Dockerfile index 5d25e48b..203643e1 100644 --- a/docker/dev/Dockerfile +++ b/docker/dev/Dockerfile @@ -10,27 +10,24 @@ RUN yarn install --pure-lockfile COPY ui /app/ui RUN yarn build -FROM rust:1.38 as rust - -# Install musl -RUN apt-get update -RUN apt-get install musl-tools -y -RUN rustup target add x86_64-unknown-linux-musl +FROM ekidd/rust-musl-builder:1.38.0-openssl11 as rust # Cache deps WORKDIR /app +RUN sudo chown -R rust:rust . RUN USER=root cargo new server WORKDIR /app/server COPY server/Cargo.toml server/Cargo.lock ./ -RUN mkdir -p ./src/bin \ +RUN sudo chown -R rust:rust . +RUN mkdir -p ./src/bin \ && echo 'fn main() { println!("Dummy") }' > ./src/bin/main.rs -RUN RUSTFLAGS=-Clinker=musl-gcc cargo build --release --target=x86_64-unknown-linux-musl +RUN cargo build --release RUN rm -f ./target/x86_64-unknown-linux-musl/release/deps/lemmy_server* COPY server/src ./src/ COPY server/migrations ./migrations/ -# build for release -RUN RUSTFLAGS=-Clinker=musl-gcc cargo build --frozen --release --target=x86_64-unknown-linux-musl +# Build for release +RUN cargo build --frozen --release # Get diesel-cli on there just in case # RUN cargo install diesel_cli --no-default-features --features postgres |