-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.arm
27 lines (20 loc) · 1.2 KB
/
Dockerfile.arm
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
FROM armbuild/alpine
RUN echo 'blurblurbot:x:1000:1000::/var/blurblurbot:/sbin/nologin' >> /etc/passwd \
&& echo 'blurblurbot:!::0:::::' >> /etc/shadow \
&& mkdir /var/blurblurbot \
&& chown blurblurbot /var/blurblurbot
ENV release=v0.1.2
# `apk upgrade` is required as armbuild/alpine is really old image.
RUN apk upgrade --no-cache && apk add --no-cache curl jq gnupg ca-certificates \
&& gpg --keyserver keyserver.ubuntu.com --recv-key F6037DD30859399B
RUN set -x \
&& mkdir /blurblurbot && cd /blurblurbot \
&& release=${release:-$(curl -s https://api.github.com/repos/dtchanpura/blurblurbot/releases/latest | jq -r .tag_name )} \
&& curl -sLO https://github.com/dtchanpura/blurblurbot/releases/download/${release}/blurblurbot-linux-arm-${release}.tar.gz \
&& curl -sLO https://github.com/dtchanpura/blurblurbot/releases/download/${release}/sha256sum.txt.asc \
&& gpg2 --verify sha256sum.txt.asc \
&& grep blurblurbot-linux-arm-${release} sha256sum.txt.asc | sha256sum \
&& tar -xf blurblurbot-linux-arm-${release}.tar.gz \
&& rm -rf sha256sum.txt.asc blurblurbot-linux-arm-${release}.tar.gz && apk del curl jq gnupg
USER blurblurbot
ENTRYPOINT ["/blurblurbot/blurblurbot"]