Docs/CloudNative/Kubernetes/Docs/cicd/jenkins/Dockerfile-kubectl-v2.md
2022-10-18 16:59:37 +08:00

625 B

FROM 172.19.0.50:9080/infra/jenkins:2.275
USER root
ADD id_rsa /root/.ssh/id_rsa
ADD config.json /root/.docker/config.json
RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime &&\ 
    echo 'Asia/Shanghai' >/etc/timezone &&\
    curl -sLD https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl -o /usr/bin/kubectl &&\
    curl -fsSL get.docker.com -o /get-docker.sh &&\
    chmod +x /usr/bin/kubectl /get-docker.sh &&\
    echo "    StrictHostKeyChecking no" >/etc/ssh/ssh_config &&\
    /get-docker.sh