-
Notifications
You must be signed in to change notification settings - Fork 109
/
tessera.aws.Dockerfile
28 lines (20 loc) · 1.22 KB
/
tessera.aws.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
# Create Tessera installation with AWS Key Vault support from pre-built .tar distributions
FROM alpine:3.13 as extractor
COPY . /ctx/
# check all necessary files are present
RUN if [ -z $(find . -name tessera-*.tar 2>/dev/null) ] ; then echo "ERROR: No tessera distribution in Docker context" && exit 1; fi
RUN if [ -z $(find . -name aws-key-vault-*.tar 2>/dev/null) ] ; then echo "ERROR: No aws-key-vault distribution in Docker context" && exit 1; fi
# install dists
RUN mkdir /install
RUN mkdir /install/tessera && tar xvf $(find . -name tessera-*.tar 2>/dev/null) -C /install/tessera --strip-components 1
RUN mkdir /install/aws-key-vault && tar xvf $(find . -name aws-key-vault-*.tar 2>/dev/null) -C /install/aws-key-vault --strip-components 1
# create tessera+vault dist (source paths need '/.' to copy only directory contents)
RUN mkdir /install/tessera-plus-vault && cp -a /install/aws-key-vault/. /install/tessera-plus-vault/ && cp -a /install/tessera/. /install/tessera-plus-vault/
# Create executable image
FROM eclipse-temurin:17-jre-jammy
RUN apt-get update && apt-get install -y \
wget \
netcat \
&& rm -rf /var/lib/apt/lists/*
COPY --from=extractor /install/tessera-plus-vault/ /tessera
ENTRYPOINT ["/tessera/bin/tessera"]