Created
August 13, 2018 02:47
-
-
Save congnt24/9652cac96043b24508c0e9d5312d30b3 to your computer and use it in GitHub Desktop.
dockerfile for install rancher cli
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Set base image. | |
FROM alpine:latest | |
MAINTAINER Dominik Hahn <[email protected]> | |
# Define rancher version | |
ENV RANCHER_CLI_VERSION=v0.6.9 | |
# Install dependencies and rancher | |
RUN apk add --quiet --no-cache ca-certificates && \ | |
apk add --quiet --no-cache --virtual build-dependencies curl && \ | |
curl -sSL "https://github.com/rancher/cli/releases/download/${RANCHER_CLI_VERSION}/rancher-linux-amd64-${RANCHER_CLI_VERSION}.tar.gz" | tar -xz -C /usr/local/bin/ --strip-components=2 && \ | |
chmod +x /usr/local/bin/rancher && \ | |
apk del build-dependencies && \ | |
rm -rf /var/cache/* | |
# Set working directory | |
RUN mkdir /app | |
WORKDIR /app | |
# Executing defaults | |
CMD ["/usr/local/bin/rancher", "--version"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment