-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
28 lines (23 loc) · 1 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
############################################################
# Dockerfile
############################################################
# Set the base image
FROM alpine:3.8
############################################################
# Configuration
############################################################
ENV VERSION "2.2.0"
############################################################
# Installation
############################################################
RUN apk add --no-cache ca-certificates bash curl tar gzip &&\
curl -L https://github.com/rancher/cli/releases/download/v${VERSION}/rancher-linux-amd64-v${VERSION}.tar.gz -o /tmp/cli.tar.gz &&\
tar zxv -C /tmp -f /tmp/cli.tar.gz &&\
cp /tmp/rancher-v${VERSION}/rancher /usr/local/bin/rancher &&\
rm -rf /tmp/* &&\
chmod +x /usr/local/bin/rancher &&\
apk del curl tar gzip
############################################################
# Execution
############################################################
CMD [ "rancher", "--help"]