2018-07-06 03:23:27 +00:00
|
|
|
# Copyright 2018 The Kubernetes Authors. All rights reserved.
|
2018-04-23 14:46:28 +00:00
|
|
|
#
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at
|
|
|
|
#
|
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific language governing permissions and
|
|
|
|
# limitations under the License.
|
|
|
|
|
2019-12-18 12:32:20 +00:00
|
|
|
FROM quay.io/kubernetes-ingress-controller/nginx-amd64:870be3bcd88c267f14fd82da82303472f383cd14
|
2018-07-21 03:49:28 +00:00
|
|
|
|
|
|
|
RUN clean-install \
|
|
|
|
g++ \
|
|
|
|
gcc \
|
|
|
|
git \
|
|
|
|
libc6-dev \
|
|
|
|
make \
|
|
|
|
wget \
|
2018-08-17 20:35:17 +00:00
|
|
|
python \
|
2019-09-05 15:46:53 +00:00
|
|
|
parallel \
|
2018-07-21 03:49:28 +00:00
|
|
|
pkg-config
|
|
|
|
|
2019-11-29 18:20:18 +00:00
|
|
|
ENV GOLANG_VERSION 1.13.4
|
2018-07-21 03:49:28 +00:00
|
|
|
ENV GO_ARCH linux-amd64
|
2019-11-29 18:20:18 +00:00
|
|
|
ENV GOLANG_SHA 692d17071736f74be04a72a06dab9cac1cd759377bd85316e52b2227604c004c
|
2018-07-21 03:49:28 +00:00
|
|
|
|
|
|
|
RUN set -eux; \
|
|
|
|
url="https://golang.org/dl/go${GOLANG_VERSION}.${GO_ARCH}.tar.gz"; \
|
|
|
|
wget -O go.tgz "$url"; \
|
|
|
|
echo "${GOLANG_SHA} *go.tgz" | sha256sum -c -; \
|
|
|
|
tar -C /usr/local -xzf go.tgz; \
|
|
|
|
rm go.tgz; \
|
|
|
|
export PATH="/usr/local/go/bin:$PATH"; \
|
|
|
|
go version
|
|
|
|
|
|
|
|
ENV GOPATH /go
|
|
|
|
ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH
|
|
|
|
|
|
|
|
RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH"
|
|
|
|
|
|
|
|
WORKDIR $GOPATH
|
|
|
|
|
2019-09-03 19:33:11 +00:00
|
|
|
ENV RESTY_CLI_VERSION 0.25rc2
|
|
|
|
ENV RESTY_CLI_SHA a38d850441384fa037a5922ca012dcce8708d0e4abe34ad2fe4164a01b28bdfb
|
2019-03-01 11:21:26 +00:00
|
|
|
|
2018-07-21 23:05:03 +00:00
|
|
|
RUN set -eux; \
|
|
|
|
url="https://github.com/openresty/resty-cli/archive/v${RESTY_CLI_VERSION}.tar.gz"; \
|
|
|
|
wget -O resty_cli.tgz "$url"; \
|
|
|
|
echo "${RESTY_CLI_SHA} *resty_cli.tgz" | sha256sum -c -; \
|
|
|
|
tar -C /tmp -xzf resty_cli.tgz; \
|
|
|
|
rm resty_cli.tgz; \
|
|
|
|
mv /tmp/resty-cli-${RESTY_CLI_VERSION}/bin/* /usr/local/bin/; \
|
|
|
|
resty -V
|
|
|
|
|
2018-07-21 03:49:28 +00:00
|
|
|
RUN luarocks install luacheck \
|
2019-03-01 11:21:26 +00:00
|
|
|
&& luarocks install busted
|
2018-07-21 03:49:28 +00:00
|
|
|
|
|
|
|
RUN go get github.com/onsi/ginkgo/ginkgo \
|
2018-07-06 03:23:27 +00:00
|
|
|
&& go get golang.org/x/lint/golint
|
2018-10-29 16:01:41 +00:00
|
|
|
|
2019-05-24 00:47:14 +00:00
|
|
|
ARG K8S_RELEASE
|
|
|
|
ARG ETCD_VERSION
|
|
|
|
|
|
|
|
RUN wget https://storage.googleapis.com/kubernetes-release/release/${K8S_RELEASE}/bin/linux/amd64/kubectl -O /usr/local/bin/kubectl \
|
2018-10-29 16:01:41 +00:00
|
|
|
&& chmod +x /usr/local/bin/kubectl
|
2019-05-24 00:47:14 +00:00
|
|
|
|
|
|
|
RUN wget https://storage.googleapis.com/kubernetes-release/release/${K8S_RELEASE}/bin/linux/amd64/kube-apiserver -O /usr/local/bin/kube-apiserver \
|
|
|
|
&& chmod +x /usr/local/bin/kube-apiserver
|
|
|
|
|
|
|
|
RUN curl -L https://storage.googleapis.com/etcd/${ETCD_VERSION}/etcd-${ETCD_VERSION}-linux-amd64.tar.gz -o /tmp/etcd-${ETCD_VERSION}-linux-amd64.tar.gz \
|
|
|
|
&& mkdir -p /tmp/etcd-download \
|
|
|
|
&& tar xzvf /tmp/etcd-${ETCD_VERSION}-linux-amd64.tar.gz -C /tmp/etcd-download --strip-components=1 \
|
|
|
|
&& cp /tmp/etcd-download/etcd /usr/local/bin \
|
|
|
|
&& rm -rf /tmp/etcd-download
|