Skip to content
This repository was archived by the owner on Nov 6, 2020. It is now read-only.

Commit adabd81

Browse files
authored
beta ci: backport missing diff from master (#10661)
* ci: publish docs debug (#10638) * ci: backport missing diff from master
1 parent c2487cf commit adabd81

File tree

5 files changed

+73
-39
lines changed

5 files changed

+73
-39
lines changed

.gitlab-ci.yml

Lines changed: 55 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -34,45 +34,65 @@ variables:
3434
.docker-cache-status: &docker-cache-status
3535
variables:
3636
CARGO_HOME: "/ci-cache/parity-ethereum/cargo/${CI_JOB_NAME}"
37+
dependencies: []
3738
before_script:
38-
- SCCACHE_ERROR_LOG=/builds/parity/parity-ethereum/sccache_error.log RUST_LOG=sccache::server=debug sccache --start-server
39+
- SCCACHE_ERROR_LOG=/builds/parity/parity-ethereum/sccache_debug.log
40+
RUST_LOG=sccache=debug
41+
sccache --start-server
3942
- sccache -s
4043
after_script:
41-
- echo "All crate-types:"
42-
- grep 'parse_arguments.*--crate-type' sccache_error.log | sed -re 's/.*"--crate-type", "([^"]+)".*/\1/' | sort | uniq -c
43-
- echo "Non-cacheable reasons:"
44-
- grep CannotCache sccache_error.log | sed -re 's/.*CannotCache\((.+)\).*/\1/' | sort | uniq -c
44+
# sccache debug info
45+
- if test -e sccache_debug.log;
46+
then
47+
echo "_____sccache_debug.log listing start:_____";
48+
cat sccache_debug.log;
49+
echo "_____sccache_debug.log listing end_____";
50+
echo "All crate-types:";
51+
grep 'parse_arguments.*--crate-type' sccache_debug.log | sed -re 's/.*"--crate-type", "([^"]+)".*/\1/' | sort | uniq -c;
52+
echo "_____Non-cacheable reasons:_____";
53+
grep CannotCache sccache_debug.log | sed -re 's/.*CannotCache\((.+)\).*/\1/' | sort | uniq -c;
54+
else
55+
echo "_____No logs from sccache_____";
56+
exit 0;
57+
fi
4558
tags:
4659
- linux-docker
4760

61+
.build-on-linux: &build-on-linux
62+
stage: build
63+
<<: *docker-cache-status
64+
<<: *collect_artifacts
65+
script:
66+
- scripts/gitlab/build-linux.sh
67+
- sccache -s
68+
4869

4970
cargo-check 0 3:
5071
stage: test
5172
<<: *docker-cache-status
5273
script:
53-
- time cargo check --target $CARGO_TARGET --locked --no-default-features
74+
- time cargo check --target $CARGO_TARGET --locked --no-default-features --verbose --color=always
5475
- sccache -s
5576

5677
cargo-check 1 3:
5778
stage: test
5879
<<: *docker-cache-status
5980
script:
60-
- time cargo check --target $CARGO_TARGET --locked --manifest-path util/io/Cargo.toml --no-default-features
81+
- time cargo check --target $CARGO_TARGET --locked --manifest-path util/io/Cargo.toml --no-default-features --verbose --color=always
6182
- sccache -s
6283

6384
cargo-check 2 3:
6485
stage: test
6586
<<: *docker-cache-status
6687
script:
67-
- time cargo check --target $CARGO_TARGET --locked --manifest-path util/io/Cargo.toml --features "mio"
88+
- time cargo check --target $CARGO_TARGET --locked --manifest-path util/io/Cargo.toml --features "mio" --verbose --color=always
6889
- sccache -s
6990

7091
cargo-audit:
7192
stage: test
7293
<<: *docker-cache-status
7394
script:
7495
- cargo audit
75-
- sccache -s
7696

7797
validate-chainspecs:
7898
stage: test
@@ -92,55 +112,64 @@ test-linux:
92112
stage: build
93113
<<: *docker-cache-status
94114
script:
95-
- ./scripts/gitlab/test-linux.sh
115+
- ./scripts/gitlab/test-linux.sh stable
96116
- sccache -s
97117

98-
build-android:
118+
test-linux-beta:
99119
stage: build
100-
image: parity/rust-parity-ethereum-android-build:stretch
101-
variables:
102-
CARGO_TARGET: armv7-linux-androideabi
120+
only: *releaseable_branches
103121
<<: *docker-cache-status
104-
<<: *collect_artifacts
105122
script:
106-
- scripts/gitlab/build-linux.sh
107-
tags:
108-
- linux-docker
123+
- ./scripts/gitlab/test-linux.sh beta
124+
- sccache -s
109125

110-
build-linux: &build-linux
126+
test-linux-nightly:
111127
stage: build
112128
only: *releaseable_branches
113129
<<: *docker-cache-status
114-
<<: *collect_artifacts
115130
script:
116-
- scripts/gitlab/build-linux.sh
131+
- ./scripts/gitlab/test-linux.sh nightly
117132
- sccache -s
133+
allow_failure: true
134+
135+
build-android:
136+
<<: *build-on-linux
137+
image: parity/rust-parity-ethereum-android-build:stretch
138+
variables:
139+
CARGO_TARGET: armv7-linux-androideabi
140+
141+
build-linux:
142+
<<: *build-on-linux
143+
only: *releaseable_branches
118144

119145
build-linux-i386:
120-
<<: *build-linux
146+
<<: *build-on-linux
147+
only: *releaseable_branches
121148
image: parity/rust-parity-ethereum-build:i386
122149
variables:
123150
CARGO_TARGET: i686-unknown-linux-gnu
124151

125152
build-linux-arm64:
126-
<<: *build-linux
153+
<<: *build-on-linux
154+
only: *releaseable_branches
127155
image: parity/rust-parity-ethereum-build:arm64
128156
variables:
129157
CARGO_TARGET: aarch64-unknown-linux-gnu
130158

131159
build-linux-armhf:
132-
<<: *build-linux
160+
<<: *build-on-linux
161+
only: *releaseable_branches
133162
image: parity/rust-parity-ethereum-build:armhf
134163
variables:
135164
CARGO_TARGET: armv7-unknown-linux-gnueabihf
136165

137166
build-darwin:
138167
stage: build
139-
only: *releaseable_branches
140168
<<: *collect_artifacts
169+
only: *releaseable_branches
141170
variables:
142171
CARGO_TARGET: x86_64-apple-darwin
143-
CARGO_HOME: "${CI_PROJECT_DIR}/.cargo"
172+
CARGO_HOME: "${CI_PROJECT_DIR}/.cargo"
144173
CC: gcc
145174
CXX: g++
146175
script:

scripts/gitlab/build-linux.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ cat .cargo/config
1818
echo "_____ Building target: "$CARGO_TARGET" _____"
1919
if [ "${CARGO_TARGET}" = "armv7-linux-androideabi" ]
2020
then
21-
time cargo build --target $CARGO_TARGET --release -p parity-clib --features final
21+
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p parity-clib --features final
2222
else
23-
time cargo build --target $CARGO_TARGET --release --features final
24-
time cargo build --target $CARGO_TARGET --release -p evmbin
25-
time cargo build --target $CARGO_TARGET --release -p ethstore-cli
26-
time cargo build --target $CARGO_TARGET --release -p ethkey-cli
27-
time cargo build --target $CARGO_TARGET --release -p whisper-cli
23+
time cargo build --target $CARGO_TARGET --verbose --color=always --release --features final
24+
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p evmbin
25+
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p ethstore-cli
26+
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p ethkey-cli
27+
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p whisper-cli
2828
fi
2929

3030
echo "_____ Post-processing binaries _____"

scripts/gitlab/build-windows.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ echo "RUSTC_WRAPPER: " $RUSTC_WRAPPER
1414
echo "SCCACHE_DIR: " $SCCACHE_DIR
1515

1616
echo "_____ Building target: "$CARGO_TARGET" _____"
17-
time cargo build --target $CARGO_TARGET --release --features final
18-
time cargo build --target $CARGO_TARGET --release -p evmbin
19-
time cargo build --target $CARGO_TARGET --release -p ethstore-cli
20-
time cargo build --target $CARGO_TARGET --release -p ethkey-cli
21-
time cargo build --target $CARGO_TARGET --release -p whisper-cli
17+
time cargo build --target $CARGO_TARGET --verbose --release --features final
18+
time cargo build --target $CARGO_TARGET --verbose --release -p evmbin
19+
time cargo build --target $CARGO_TARGET --verbose --release -p ethstore-cli
20+
time cargo build --target $CARGO_TARGET --verbose --release -p ethkey-cli
21+
time cargo build --target $CARGO_TARGET --verbose --release -p whisper-cli
2222

2323
echo "__________Sign binaries__________"
2424
scripts/gitlab/sign-win.cmd $keyfile $certpass target/$CARGO_TARGET/release/parity.exe

scripts/gitlab/test-linux.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
#!/bin/bash
2+
# ARGUMENT $1 Rust flavor to run test with (stable/beta/nightly)
3+
24
echo "________Running test-linux.sh________"
35
set -e # fail on any error
46
set -u # treat unset variables as error
@@ -8,5 +10,8 @@ OPTIONS="--release"
810
#use nproc `linux only
911
THREADS=$(nproc)
1012

13+
rustup default $1
14+
rustup show
15+
1116
echo "________Running Parity Full Test Suite________"
12-
time cargo test $OPTIONS --features "$FEATURES" --locked --all --target $CARGO_TARGET -- --test-threads $THREADS
17+
time cargo test $OPTIONS --features "$FEATURES" --locked --all --target $CARGO_TARGET --verbose --color=always -- --test-threads $THREADS

scripts/gitlab/validate-chainspecs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ echo "________Running validate_chainspecs.sh________"
66
ERR=0
77

88
echo "________Validate chainspecs________"
9-
time cargo build --release -p chainspec
9+
time cargo build --release -p chainspec --verbose --color=always
1010

1111
for spec in ethcore/res/*.json; do
1212
if ! ./target/release/chainspec "$spec"; then ERR=1; fi

0 commit comments

Comments
 (0)