Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update gitlab dockerfile #3789

Merged
merged 5 commits into from
Apr 19, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 7 additions & 8 deletions tests/docker/gitlab.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,28 +1,27 @@
# syntax=docker/dockerfile:1.4
FROM python:3.9
FROM python:3.11

ARG GCLOUD_VERSION=364.0.0
ARG HELM_VERSION=3.5.4

RUN apt-get update && apt-get install -y curl git jq apache2-utils \
RUN apt-get update && apt-get install -y curl git jq apache2-utils apt-transport-https ca-certificates gnupg \
&& curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl \
&& chmod +x ./kubectl \
&& mv ./kubectl /usr/local/bin \
&& curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-${GCLOUD_VERSION}-linux-x86_64.tar.gz \
&& tar xvzf google-cloud-sdk-${GCLOUD_VERSION}-linux-x86_64.tar.gz \
&& mv google-cloud-sdk /usr/lib/ \
&& echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list \
&& curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | tee /usr/share/keyrings/cloud.google.gpg \
&& apt-get update && apt-get install google-cloud-cli \
&& apt-get install google-cloud-sdk-gke-gcloud-auth-plugin \
&& curl -LO https://get.helm.sh/helm-v${HELM_VERSION}-linux-amd64.tar.gz \
&& tar -zxvf helm-v${HELM_VERSION}-linux-amd64.tar.gz \
&& mv linux-amd64/helm /usr/local/bin/helm

WORKDIR /workspace/tests

COPY --link tests/requirements.txt /workspace/tests/
RUN python -m ensurepip --upgrade
RUN pip install --require-hashes -r requirements.txt

COPY --link tests /workspace/tests
COPY --link deployments /workspace/deployments

ENV PATH="/usr/lib/google-cloud-sdk/bin:${PATH}"

ENTRYPOINT ["python3", "-m", "pytest"]