Made builder root again
All checks were successful
continuous-integration/drone the build was successful
All checks were successful
continuous-integration/drone the build was successful
This commit is contained in:
parent
0abfaca967
commit
3bdf79e824
2 changed files with 15 additions and 18 deletions
|
|
@ -2,7 +2,7 @@
|
|||
# Our entire toolchain runs in alpine
|
||||
FROM alpine:3.13.5 AS builder
|
||||
|
||||
ENV PATH "$PATH:/app/.cargo/bin"
|
||||
ENV PATH "$PATH:/root/.cargo/bin"
|
||||
# Needed for proper compiling of openssl-dev
|
||||
ENV RUSTFLAGS "-C target-feature=-crt-static"
|
||||
|
||||
|
|
@ -19,13 +19,7 @@ RUN addgroup -S builder && \
|
|||
openssl-dev \
|
||||
postgresql-dev
|
||||
|
||||
# Switch to the non-root user
|
||||
USER builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Install rustup in the new user's home
|
||||
# Create mountpoints for volumes with correct permissions
|
||||
RUN { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain nightly; } && \
|
||||
rustup target add x86_64-unknown-linux-musl --toolchain nightly && \
|
||||
mkdir -p .cargo/registry target
|
||||
rustup target add x86_64-unknown-linux-musl --toolchain nightly
|
||||
|
|
|
|||
Reference in a new issue