File tree Expand file tree Collapse file tree 3 files changed +50
-0
lines changed Expand file tree Collapse file tree 3 files changed +50
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Publish Docker
2
+ on : [push]
3
+ jobs :
4
+ build :
5
+ runs-on : ubuntu-latest
6
+ steps :
7
+ - uses : actions/checkout@master
8
+ - name : Publish to Registry
9
+ uses : elgohr/Publish-Docker-Github-Action@master
10
+ with :
11
+ name : sylwekrapala/rust-ubuntu
12
+ username : ${{ secrets.DOCKER_USERNAME }}
13
+ password : ${{ secrets.DOCKER_TOKEN }}
14
+ dockerfile : Dockerfile
15
+ tags : " latest,bionic,1.41-bionic, 1-bionic"
Original file line number Diff line number Diff line change
1
+ FROM buildpack-deps:bionic
2
+
3
+ # based on https://github.com/rust-lang/docker-rust/blob/76921dd61d80c4e8107b858d26bf5e52c4c09816/1.41.0/buster/Dockerfile
4
+
5
+ ENV RUSTUP_HOME=/usr/local/rustup \
6
+ CARGO_HOME=/usr/local/cargo \
7
+ PATH=/usr/local/cargo/bin:$PATH \
8
+ RUST_VERSION=1.41.0
9
+
10
+ RUN set -eux; \
11
+ dpkgArch="$(dpkg --print-architecture)" ; \
12
+ case "${dpkgArch##*-}" in \
13
+ amd64) rustArch='x86_64-unknown-linux-gnu' ; rustupSha256='ad1f8b5199b3b9e231472ed7aa08d2e5d1d539198a15c5b1e53c746aad81d27b' ;; \
14
+ armhf) rustArch='armv7-unknown-linux-gnueabihf' ; rustupSha256='6c6c3789dabf12171c7f500e06d21d8004b5318a5083df8b0b02c0e5ef1d017b' ;; \
15
+ arm64) rustArch='aarch64-unknown-linux-gnu' ; rustupSha256='26942c80234bac34b3c1352abbd9187d3e23b43dae3cf56a9f9c1ea8ee53076d' ;; \
16
+ i386) rustArch='i686-unknown-linux-gnu' ; rustupSha256='27ae12bc294a34e566579deba3e066245d09b8871dc021ef45fc715dced05297' ;; \
17
+ *) echo >&2 "unsupported architecture: ${dpkgArch}" ; exit 1 ;; \
18
+ esac; \
19
+ url="https://static.rust-lang.org/rustup/archive/1.21.1/${rustArch}/rustup-init" ; \
20
+ wget "$url" ; \
21
+ echo "${rustupSha256} *rustup-init" | sha256sum -c -; \
22
+ chmod +x rustup-init; \
23
+ ./rustup-init -y --no-modify-path --profile minimal --default-toolchain $RUST_VERSION; \
24
+ rm rustup-init; \
25
+ chmod -R a+w $RUSTUP_HOME $CARGO_HOME; \
26
+ rustup --version; \
27
+ cargo --version; \
28
+ rustc --version;
Original file line number Diff line number Diff line change
1
+ [ ![ Docker Pulls] ( https://img.shields.io/docker/pulls/sylwekrapala/rust-ubuntu )] ( https://hub.docker.com/r/sylwekrapala/rust-ubuntu )
2
+ [ ![ MicroBadger Size] ( https://img.shields.io/microbadger/image-size/sylwekrapala/rust-ubuntu )] ( https://hub.docker.com/r/sylwekrapala/rust-ubuntu )
3
+ [ ![ Publish Docker] ( https://github.com/xoac/docker-evcxr/workflows/Publish%20Docker/badge.svg )] ( https://github.com/xoac/docker-evcxr/actions?query=workflow%3A%22Publish+Docker%22 )
4
+
5
+ # docker-rust-ubuntu
6
+
7
+ This based on [ official rust build process] ( https://github.com/rust-lang/docker-rust ) but use ubuntu as base image.
You can’t perform that action at this time.
0 commit comments