This repository has been archived by the owner on Aug 11, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathadamantDockerFile
54 lines (40 loc) · 1.87 KB
/
adamantDockerFile
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
#version 0.4.1
FROM ubuntu:17.10
MAINTAINER [email protected]
ENV DEBIAN_FRONTEND noninteractive
ENV TERM linux
RUN sed -i 's/^mesg n$/tty -s \&\& mesg n/g' /root/.profile
RUN apt-get update && apt-get install -y --no-install-recommends apt-utils
RUN apt-get update && apt-get install -y git bash locales
RUN apt-get install -y mc git curl python build-essential curl automake autoconf libtool redis-server wget autotools-dev libsodium-dev
#setting up locale
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash -
RUN apt-get install -y nodejs
RUN apt-get purge -y postgres*
RUN sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/ zesty-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
RUN wget -q https://www.postgresql.org/media/keys/ACCC4CF8.asc -O - | apt-key add -
RUN apt-get update && apt-get install -y libpq-dev
# postgresql postgresql-contrib
RUN npm install -g pm2
RUN useradd adamant -s /bin/bash -m
RUN echo "adamant:password" | chpasswd
RUN echo "%adamant ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers
USER adamant
WORKDIR /home/adamant
ADD https://api.github.com/repos/adamant-im/adamant/git/refs/heads/master version.json
RUN git clone https://github.com/Adamant-im/adamant
WORKDIR adamant
RUN npm install
# RUN sed -i 's/"public": false,/"public": true,/g' config.json
#RUN sed 's/"host": "localhost"/"host": "'$DATABASE_HOST'"/g' config.json > config.json
#RUN sed 's/"user": ""/"user": "'$DATABASE_USER'"/g' config.json > config.json
#RUN sed 's/"password": "password"/"password": "'$DATABASE_PASSWORD'"/g' config.json > config.json
#RUN sed 's/"secu_main"/"'$DATABASE_NAME'"/g' config.json > config.json
#RUN sed 's/"consoleLogLevel": "none"/"consoleLogLevel": "'$LOG_LEVEL'"/g' config.json > config.json
EXPOSE 36666
COPY starter.sh /home/adamant/adamant
CMD ["/bin/bash", "./starter.sh"]