File tree Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Original file line number Diff line number Diff line change 1
1
# always build this using the latest stable release
2
2
FROM rust:latest as build
3
3
4
+ ARG CLR_NAME=cargo-local-registry
5
+ ARG CLR_VERSION=0.2.2
6
+ ARG CLR_URL=https://github.com/dhovart/${CLR_NAME}/releases/download/${CLR_VERSION}/${CLR_NAME}-${CLR_VERSION}-x86_64-unknown-linux-musl.tar.gz
7
+
8
+ ARG JQ_VERSION=1.6
9
+ ARG JQ_URL=https://github.com/stedolan/jq/releases/download/jq-${JQ_VERSION}/jq-linux64
10
+
4
11
RUN mkdir -p /rust-test-runner/src
5
12
ENV wd /rust-test-runner
6
13
WORKDIR ${wd}
@@ -17,10 +24,13 @@ COPY src/* src/
17
24
RUN cargo build --release
18
25
COPY bin/generate-registry.sh ${wd}/bin/
19
26
# download jq
20
- RUN curl -L -o /usr/local/bin/jq https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64 \
21
- && chmod +x /usr/local/bin/jq
22
- # build cargo-local-registry
23
- RUN cargo install --git https://github.com/ChrisGreenaway/cargo-local-registry.git
27
+ RUN curl -L -o /usr/local/bin/jq "${JQ_URL}" \
28
+ && chmod +x /usr/local/bin/jq
29
+ # retrieve cargo-local-registry
30
+ RUN curl -L -o clr.tar.gz "${CLR_URL}" \
31
+ && tar xvzf clr.tar.gz --strip-components=1 \
32
+ && chmod +x cargo-local-registry \
33
+ && mv cargo-local-registry /usr/local/cargo/bin
24
34
# download popular crates to local registry
25
35
WORKDIR /local-registry
26
36
COPY local-registry/* ./
You can’t perform that action at this time.
0 commit comments