This repository has been archived by the owner on Feb 24, 2022. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile.aarch64
81 lines (75 loc) · 2.04 KB
/
Dockerfile.aarch64
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
FROM ghcr.io/linuxserver/baseimage-ubuntu:arm64v8-bionic
# set version label
ARG BUILD_DATE
ARG VERSION
ARG CODIMD_RELEASE
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
LABEL maintainer="chbmb"
# environment settings
ARG DEBIAN_FRONTEND="noninteractive"
ENV NODE_ENV production
RUN \
echo "**** install build packages ****" && \
apt-get update && \
apt-get install -y \
g++ \
gcc \
git \
gnupg \
jq \
libicu60 \
libssl-dev \
make && \
echo "**** install runtime *****" && \
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \
echo 'deb https://deb.nodesource.com/node_10.x bionic main' > /etc/apt/sources.list.d/nodesource.list && \
echo "**** install yarn repository ****" && \
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list && \
apt-get update && \
apt-get install -y \
fontconfig \
fonts-noto \
netcat-openbsd \
nodejs \
yarn && \
echo "***** install phantomjs *****" && \
curl -o \
/tmp/phantom.tar.gz -L \
"https://lsio-ci.ams3.digitaloceanspaces.com/phantomjs/phantomjs-aarch64.tar.gz" && \
tar -xf /tmp/phantom.tar.gz -C / && \
echo "**** install codi-md ****" && \
if [ -z ${CODIMD_RELEASE+x} ]; then \
CODIMD_RELEASE=$(curl -sX GET "https://api.github.com/repos/hedgedoc/hedgedoc/releases/latest" \
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
fi && \
curl -o \
/tmp/codimd.tar.gz -L \
"https://github.com/hedgedoc/hedgedoc/releases/download/${CODIMD_RELEASE}/hedgedoc-${CODIMD_RELEASE}.tar.gz" && \
mkdir -p \
/opt/codimd && \
tar xf /tmp/codimd.tar.gz -C \
/opt/codimd --strip-components=1 && \
cd /opt/codimd && \
bin/setup && \
echo "**** cleanup ****" && \
yarn cache clean && \
apt-get -y purge \
g++ \
gcc \
git \
gnupg \
jq \
libicu60 \
libssl-dev \
make && \
apt-get -y autoremove && \
rm -rf \
/tmp/* \
/var/lib/apt/lists/* \
/var/tmp/*
# add local files
COPY root/ /
# ports and volumes
EXPOSE 3000
VOLUME /config