-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
43 lines (38 loc) · 1.49 KB
/
Dockerfile
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
32
33
34
35
36
37
38
39
40
41
42
43
FROM ubuntu:focal
# Upgrade and install standard OS packages
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update \
&& apt-get dist-upgrade -y \
&& apt-get install -yq \
apt-transport-https \
ca-certificates \
curl \
gettext-base \
git \
gnupg \
jq \
less \
lsb-release \
make \
nano \
software-properties-common \
vim \
wget
# Configure the docker package repository
RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /usr/share/keyrings/docker.gpg \
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list
# Configure the Hashicorp package repository
RUN curl -fsSL https://apt.releases.hashicorp.com/gpg | gpg --dearmor -o /usr/share/keyrings/hashicorp.gpg \
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/hashicorp.gpg] https://apt.releases.hashicorp.com $(lsb_release -cs) main" | tee /etc/apt/sources.list.d/hashicorp.list
# Install tools from custom package repositories
ARG VAULT_VERSION=1.15.6
ARG TERRAFORM_VERSION=1.8.5
RUN apt-get update \
&& apt-get install -yq \
docker-ce \
docker-ce-cli \
containerd.io \
terraform=${TERRAFORM_VERSION}-1 \
vault=${VAULT_VERSION}-1 \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*