-
Notifications
You must be signed in to change notification settings - Fork 21
/
Dockerfile-tests
31 lines (22 loc) · 1023 Bytes
/
Dockerfile-tests
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
FROM sbtscala/scala-sbt:openjdk-17.0.2_1.8.0_2.13.10
# This is only to make `sbt` work because `Version.scala` depends on `git` if this environment is not set
ENV GIT_HASH="0.0.1"
COPY automation/src /app/automation/src
COPY core/src /app/core/src
COPY project /app/project
COPY build.sbt /app
COPY automation-tests-docker-entrypoint.sh /app
RUN touch /app/key.json
# Downloading gcloud package
# https://cloud.google.com/sdk/docs/install#linux
# https://stackoverflow.com/questions/28372328/how-to-install-the-google-cloud-sdk-in-a-docker-image
RUN curl https://dl.google.com/dl/cloudsdk/release/google-cloud-sdk.tar.gz > /tmp/google-cloud-sdk.tar.gz
# Installing the package
RUN mkdir -p /usr/local/gcloud \
&& tar -C /usr/local/gcloud -xvf /tmp/google-cloud-sdk.tar.gz \
&& /usr/local/gcloud/google-cloud-sdk/install.sh
# Adding the package path to local
ENV PATH $PATH:/usr/local/gcloud/google-cloud-sdk/bin
RUN mkdir -p /root/.ssh
WORKDIR /app
ENTRYPOINT ["bash", "automation-tests-docker-entrypoint.sh"]