File tree Expand file tree Collapse file tree 3 files changed +27
-0
lines changed Expand file tree Collapse file tree 3 files changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ ENV TZ=UTC
44RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
55ENV RUST_PROFILE=release
66ENV PATH=/root/.cargo/bin:/root/.pyenv/shims:/root/.pyenv/bin:$PATH
7+ ENV PROTOC_VERSION=22.0
78
89RUN sed -i '/updates/d' /etc/apt/sources.list && \
910 sed -i '/security/d' /etc/apt/sources.list
@@ -47,6 +48,14 @@ RUN wget https://sh.rustup.rs -O rustup-install.sh && \
4748 rm rustup-install.sh && \
4849 /root/.cargo/bin/rustup install 1.62
4950
51+ # Download protoc manually, it is in the update repos which we
52+ # disabled above, so `apt-get` can't find it anymore.
53+ RUN cd /tmp/ && \
54+ wget https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
55+ unzip protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
56+ mv bin/protoc /usr/local/bin && \
57+ rm -rf include bin protoc-${PROTOC_VERSION}-linux-x86_64.zip
58+
5059RUN mkdir /build
5160WORKDIR /build
5261
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ ENV TZ=UTC
44RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
55ENV RUST_PROFILE=release
66ENV PATH=/root/.cargo/bin:$PATH
7+ ENV PROTOC_VERSION=22.0
78
89RUN sed -i '/updates/d' /etc/apt/sources.list && \
910 sed -i '/security/d' /etc/apt/sources.list
@@ -36,6 +37,14 @@ RUN wget https://sh.rustup.rs -O rustup-install.sh && \
3637 rm rustup-install.sh && \
3738 /root/.cargo/bin/rustup install 1.62
3839
40+ # Download protoc manually, it is in the update repos which we
41+ # disabled above, so `apt-get` can't find it anymore.
42+ RUN cd /tmp/ && \
43+ wget https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
44+ unzip protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
45+ mv bin/protoc /usr/local/bin && \
46+ rm -rf include bin protoc-${PROTOC_VERSION}-linux-x86_64.zip
47+
3948RUN mkdir /build
4049WORKDIR /build
4150
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ ENV TZ=UTC
44RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
55ENV RUST_PROFILE=release
66ENV PATH=/root/.cargo/bin:$PATH
7+ ENV PROTOC_VERSION=22.0
78
89RUN sed -i '/updates/d' /etc/apt/sources.list && \
910 sed -i '/security/d' /etc/apt/sources.list
@@ -37,6 +38,14 @@ RUN wget https://sh.rustup.rs -O rustup-install.sh && \
3738 rm rustup-install.sh && \
3839 /root/.cargo/bin/rustup install 1.62
3940
41+ # Download protoc manually, it is in the update repos which we
42+ # disabled above, so `apt-get` can't find it anymore.
43+ RUN cd /tmp/ && \
44+ wget https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
45+ unzip protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
46+ mv bin/protoc /usr/local/bin && \
47+ rm -rf include bin protoc-${PROTOC_VERSION}-linux-x86_64.zip
48+
4049RUN mkdir /build
4150WORKDIR /build
4251
You can’t perform that action at this time.
0 commit comments