[#68] Removed unnecessary target; added builder building to fej
continuous-integration/drone the build was successful Details

68-clippy
Jef Roosens 2021-05-13 21:01:15 +02:00
parent 204f8f0a56
commit e358757b19
Signed by: Jef Roosens
GPG Key ID: B580B976584B5F30
5 changed files with 10 additions and 9 deletions

View File

@ -2,9 +2,9 @@
# Our entire toolchain runs in alpine # Our entire toolchain runs in alpine
FROM alpine:3.13.5 AS builder FROM alpine:3.13.5 AS builder
ENV PATH "$PATH:/root/.cargo/bin" ENV PATH="$PATH:/root/.cargo/bin" \
# Needed for proper compiling of openssl-dev # Needed for proper compiling of openssl-dev
ENV RUSTFLAGS "-C target-feature=-crt-static" RUSTFLAGS="-C target-feature=-crt-static"
# Add the build user # Add the build user
# Install dependencies # Install dependencies

View File

@ -7,7 +7,6 @@ ENV RUST_BACKTRACE 1
COPY --chown=builder:builder Cargo.toml Cargo.lock ./ COPY --chown=builder:builder Cargo.toml Cargo.lock ./
COPY --chown=builder:builder src/ ./src/ COPY --chown=builder:builder src/ ./src/
COPY --chown=builder:builder migrations/ ./migrations/ COPY --chown=builder:builder migrations/ ./migrations/
COPY --chown=builder:builder ./docker/entrypoint_dev.sh /entrypoint.sh
COPY --chown=builder:builder ./Rocket.toml /app/Rocket.toml COPY --chown=builder:builder ./Rocket.toml /app/Rocket.toml
ENTRYPOINT ["/entrypoint.sh"] ENTRYPOINT ["cargo"]

View File

@ -19,7 +19,6 @@ COPY --chown=builder:builder migrations/ ./migrations/
RUN cargo install \ RUN cargo install \
--path . \ --path . \
--root /app/output \ --root /app/output \
--target x86_64-unknown-linux-musl \
--features frontend --features frontend

View File

@ -1,4 +0,0 @@
#!/usr/bin/env sh
# All this file does is inject the target
cargo "$@" --target x86_64-unknown-linux-musl

7
fejctl
View File

@ -19,6 +19,13 @@ function dc() {
done done
shift $((OPTIND-1)) shift $((OPTIND-1))
if [[ "$build_builder" -eq 1 ]]; then
DOCKER_BUILDKIT=1 docker build \
-t "$image-builder:latest" \
-f docker/Dockerfile.builder \
.
fi
if [[ "$release" -eq 1 ]]; then if [[ "$release" -eq 1 ]]; then
DOCKER_BUILDKIT=1 COMPOSE_DOCKER_CLI_BUILD=1 docker-compose \ DOCKER_BUILDKIT=1 COMPOSE_DOCKER_CLI_BUILD=1 docker-compose \
--file docker/docker-compose.yml \ --file docker/docker-compose.yml \