22
22
PERCY_PROJECT : crates-io/crates.io
23
23
24
24
steps :
25
- - uses : actions/checkout@v2-beta
25
+ - uses : actions/checkout@v2
26
26
27
27
- uses : actions/cache@v1
28
28
with :
@@ -63,14 +63,15 @@ jobs:
63
63
- nightly
64
64
65
65
env :
66
+ RUST_BACKTRACE : 1
66
67
DATABASE_URL : postgres://postgres:@localhost/cargo_registry_test
67
68
TEST_DATABASE_URL : postgres://postgres:@localhost/cargo_registry_test
68
69
CARGO_INCREMENTAL : 0
69
70
RUSTFLAGS : " -C debuginfo=0 -D warnings"
70
71
MALLOC_CONF : " background_thread:true,abort_conf:true,abort:true,junk:true"
71
72
72
73
steps :
73
- - uses : actions/checkout@v2-beta
74
+ - uses : actions/checkout@v2
74
75
75
76
- name : Cleanup pre-installed Rust toolchains
76
77
# The pre-installed toolchain is under root permission, and this would
85
86
fi
86
87
echo "::add-path::$HOME/.cargo/bin"
87
88
89
+ # FIXME: Nightly and beta channels have high churn. The cache quickly expires, but there is
90
+ # no way (that I can find) to overwrite an existing cache. There is also no way to
91
+ # dynamically include the latest version number for a release channel into the cache `key`
92
+ # value. Once a cached release becomes stale, every job will begin downloading the latest
93
+ # release from upstream and the cache becomes useless for that channel.
94
+ #
95
+ # Including `hashFiles('**/Cargo.lock')` below is a hack. Ideally, we would change the `key`
96
+ # for each channel at the same rate as the release cadence for that channel. For the stable
97
+ # channel this is too frequent and for the nightly channel (and probably beta as well) it is
98
+ # not often enough.
99
+ #
100
+ # Current size as of 2019-12-23: ~123 MB
88
101
- name : Cache rustup
89
102
uses : actions/cache@v1
90
103
with :
@@ -94,6 +107,10 @@ jobs:
94
107
${{ runner.os }}-rustup-${{ matrix.rust }}-
95
108
${{ runner.os }}-rustup-
96
109
110
+ # This step has the same tradeoffs as `Cache rustup`, however the cache size is significantly
111
+ # smaller. The installed `diesel` binary is also stored here.
112
+ #
113
+ # Current size as of 2019-12-23: ~6 MB
97
114
- name : Cache cargo binaries
98
115
uses : actions/cache@v1
99
116
with :
@@ -103,6 +120,7 @@ jobs:
103
120
${{ runner.os }}-cargo-bin-${{ matrix.rust }}-
104
121
${{ runner.os }}-cargo-bin-
105
122
123
+ # Current size as of 2019-12-23: ~77 MB
106
124
- name : Cache cargo registry cache
107
125
uses : actions/cache@v1
108
126
with :
@@ -112,6 +130,7 @@ jobs:
112
130
${{ runner.os }}-cargo-registry-cache-${{ matrix.rust }}-
113
131
${{ runner.os }}-cargo-registry-cache-
114
132
133
+ # Current size as of 2019-12-23: ~38 MB
115
134
- name : Cache cargo registry index
116
135
uses : actions/cache@v1
117
136
with :
@@ -121,6 +140,7 @@ jobs:
121
140
${{ runner.os }}-cargo-registry-index-${{ matrix.rust }}-
122
141
${{ runner.os }}-cargo-registry-index-
123
142
143
+ # Current size as of 2019-12-23: ~4 MB
124
144
- name : Cache cargo git db
125
145
uses : actions/cache@v1
126
146
with :
@@ -130,6 +150,7 @@ jobs:
130
150
${{ runner.os }}-cargo-git-db-${{ matrix.rust }}-
131
151
${{ runner.os }}-cargo-git-db-
132
152
153
+ # Current size as of 2019-12-23: ~336 MB
133
154
- name : Cache cargo build
134
155
uses : actions/cache@v1
135
156
with :
0 commit comments