-
Notifications
You must be signed in to change notification settings - Fork 214
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #998 from rust-lang/rustfmt
Migrate code formatting to the orchestrator
- Loading branch information
Showing
15 changed files
with
576 additions
and
285 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
FROM rust:alpine | ||
|
||
RUN apk add musl-dev openssl-dev openssl-libs-static | ||
|
||
# Adding -C relocation-model=static due to | ||
# https://github.com/rust-lang/rust/issues/95926 | ||
|
||
# Adding this to find the statically-built version | ||
ENV OPENSSL_NO_PKG_CONFIG=1 OPENSSL_STATIC=1 OPENSSL_DIR=/usr/ | ||
|
||
RUN mkdir /output | ||
|
||
COPY compiler/base/asm-cleanup /compiler/base/asm-cleanup | ||
COPY compiler/base/orchestrator /compiler/base/orchestrator | ||
COPY compiler/base/modify-cargo-toml /compiler/base/modify-cargo-toml | ||
COPY ui /ui | ||
|
||
WORKDIR /compiler/base/orchestrator | ||
|
||
RUN \ | ||
cargo rustc --profile test --lib --locked -- --cfg force_docker -C relocation-model=static; \ | ||
test_bin=$(find target/debug/deps/ -name "orchestrator*" -type f -perm -a=x); \ | ||
mv "${test_bin}" /output/unit_tests_orchestrator; | ||
|
||
WORKDIR /ui | ||
|
||
RUN \ | ||
cargo rustc --tests --locked -- -C relocation-model=static; \ | ||
test_bin=$(find target/debug/deps/ -name "ui*" -type f -perm -a=x); \ | ||
mv "${test_bin}" /output/unit_tests_ui; | ||
|
||
RUN \ | ||
cargo rustc --locked --release -- -C relocation-model=static; \ | ||
mv target/release/ui /output/ui; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
* | ||
!compiler/base/asm-cleanup/** | ||
compiler/base/asm-cleanup/target | ||
!compiler/base/orchestrator/** | ||
compiler/base/orchestrator/target | ||
!compiler/base/modify-cargo-toml/** | ||
compiler/base/modify-cargo-toml/target | ||
!ui/** | ||
ui/frontend | ||
ui/target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -eu | ||
|
||
IMAGE_NAME=backend-build | ||
OUTPUT_DIR=docker-output | ||
|
||
docker build -t "${IMAGE_NAME}" -f ci/Dockerfile . | ||
|
||
mkdir -p "${OUTPUT_DIR}" | ||
|
||
container_id=$(docker create "${IMAGE_NAME}") | ||
for f in unit_tests_orchestrator unit_tests_ui ui; do | ||
docker cp "${container_id}:/output/${f}" "${OUTPUT_DIR}" | ||
done | ||
docker rm -f "${container_id}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.