-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.template
52 lines (41 loc) · 1.56 KB
/
Dockerfile.template
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
#FROM balenalib/%%BALENA_MACHINE_NAME%%-node:15-buster-run
FROM balenalib/%%BALENA_MACHINE_NAME%%-node:16.15-buster-run
# Dockerfile boilerplate - certs and timezone
COPY ca-certificates.crt /etc/ssl/certs/
RUN ln -sf /usr/share/zoneinfo/US/Eastern /etc/localtime
ENV UDEV=on
# RUN apt-get update
RUN apt-get update && apt-get install -y apt-transport-https
RUN install_packages vim postgresql-client inetutils-telnet exfat-fuse exfat-utils
# install migrate tool
RUN curl -L https://github.com/golang-migrate/migrate/releases/download/v4.15.2/migrate.linux-armv7.tar.gz | tar xvz
RUN chmod +x migrate
# COPY usb drive handling rules and scripts over, but let the startserver script put them in place
COPY usb.rules /server/usb/usb.rules
COPY scripts /server/usb/scripts
RUN chmod +x /server/usb/scripts/*.sh
COPY start_container_specific_server.sh /
RUN chmod +x /start_container_specific_server.sh
COPY startservers_api.sh /
RUN chmod +x /startservers_api.sh
COPY startservers_queue.sh /
RUN chmod +x /startservers_queue.sh
COPY startservers_websocket.sh /
RUN chmod +x /startservers_websocket.sh
COPY migrations /go/migrations
COPY conf/postgresql.conf /go/conf/postgresql.conf
COPY conf/pg_hba.conf /go/conf/pg_hba.conf
COPY src /server/src
COPY package.json /server
COPY package-lock.json /server
COPY config_ci.json /server
COPY config_pi.json /server
COPY config_test.json /server
COPY config_dev.json /server
COPY config_prod.json /server/config.json
WORKDIR /server
RUN npm install
CMD cp /server/config.json /config
CMD cd /
CMD /start_container_specific_server.sh
# CMD ["bash"]