mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-25 15:50:20 +00:00
bc167cc6f4
Installing Helm fails often in the CI. The Helm documentation does not point to `https://git.io/get_helm.sh` anymore, but to a location on GitHub. To make it easier to update the location in the future, it has now been added to `build.env`, just like the `HELM_VERSION`. See-also: https://helm.sh/docs/intro/install/ Signed-off-by: Niels de Vos <ndevos@ibm.com>
62 lines
1.8 KiB
Docker
62 lines
1.8 KiB
Docker
# Container image for running the Ceph-CSI tests
|
|
#
|
|
# This container is based on Fedora so that recent versions of tools can easily
|
|
# be installed.
|
|
#
|
|
# Production containers are based one ceph/ceph:latest, which use CentOS as
|
|
# Operating System, so generated binaries and versions of dependencies may be a
|
|
# little different.
|
|
#
|
|
|
|
FROM registry.fedoraproject.org/fedora:latest
|
|
|
|
ARG GOPATH=/go
|
|
ARG GOROOT=/usr/local/go
|
|
ARG GOARCH
|
|
|
|
ENV \
|
|
GOPATH=${GOPATH} \
|
|
GOROOT=${GOROOT} \
|
|
GO111MODULE=on \
|
|
CEPHCSIPATH=/go/src/github.com/ceph/ceph-csi \
|
|
PATH="${GOPATH}/bin:${GOROOT}/bin:/opt/commitlint/node_modules/.bin:${PATH}"
|
|
|
|
COPY build.env /
|
|
|
|
RUN source /build.env \
|
|
&& \
|
|
( test -n "${GOARCH}" && exit 0; echo -e "\n\nMissing GOARCH argument for building image, install Golang or run: make containerized-test GOARCH=amd64\n\n"; exit 1 ) \
|
|
&& dnf -y install \
|
|
git \
|
|
make \
|
|
gcc \
|
|
findutils \
|
|
librados-devel \
|
|
librbd-devel \
|
|
openssl \
|
|
rubygems \
|
|
ShellCheck \
|
|
codespell \
|
|
yamllint \
|
|
npm \
|
|
diffutils \
|
|
python3-prettytable \
|
|
pylint \
|
|
&& dnf -y update \
|
|
&& dnf -y clean all \
|
|
&& gem install mdl \
|
|
&& mkdir -p ${GOROOT} \
|
|
&& curl https://storage.googleapis.com/golang/go${GOLANG_VERSION}.linux-${GOARCH}.tar.gz \
|
|
| tar xzf - -C ${GOROOT} --strip-components=1 \
|
|
&& curl -sf "https://raw.githubusercontent.com/golangci/golangci-lint/${GOLANGCI_VERSION}/install.sh" \
|
|
| bash -s -- -b ${GOPATH}/bin "${GOLANGCI_VERSION}" \
|
|
&& curl -L "${HELM_SCRIPT}" | bash -s -- --version "${HELM_VERSION}" \
|
|
&& mkdir /opt/commitlint && pushd /opt/commitlint \
|
|
&& npm init -y \
|
|
&& npm install @commitlint/cli@"${COMMITLINT_VERSION}" \
|
|
&& popd \
|
|
&& git config --global --add safe.directory ${CEPHCSIPATH} \
|
|
&& true
|
|
|
|
WORKDIR ${CEPHCSIPATH}
|