This repository was archived by the owner on Jun 10, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathDockerfile
More file actions
86 lines (76 loc) · 2.78 KB
/
Dockerfile
File metadata and controls
86 lines (76 loc) · 2.78 KB
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
82
83
84
85
86
#################################################################
# #
# Copyright (c) 2018-2021 YottaDB LLC and/or its subsidiaries. #
# All rights reserved. #
# #
# This source code contains the intellectual property #
# of its copyright holder(s), and is made available #
# under a license. If you do not know the terms of #
# the license, please stop and do not read further. #
# #
#################################################################
FROM yottadb/yottadb-base:latest-master
# Install dependencies
RUN apt-get update && \
apt-get install -y \
bzip2 \
curl \
icu-devtools \
libgcrypt20-dev \
libgpgme11-dev \
libconfig-dev \
libssl-dev \
cmake \
git && \
apt-get clean
WORKDIR /opt/yottadb/gui
COPY . /opt/yottadb/gui
# Install ydb_crypt plugin
RUN mkdir /tmp/plugin-build && \
cd /tmp/plugin-build && \
cp /opt/yottadb/current/plugin/gtmcrypt/source.tar . && \
tar -xf source.tar && \
. /opt/yottadb/gui/env && \
make && make install && make clean && \
find $ydb_dist/plugin -type f -exec chown root:root {} +
# Build certificate for SSL/TLS purposes
#RUN openssl req -x509 -newkey rsa:4096 -sha256 -days 3650 -nodes -keyout ydbgui.key -out ydbgui.crt -subj /CN=localhost -passout pass:ydbgui
RUN openssl genrsa -aes128 -passout pass:ydbgui -out /opt/yottadb/gui/ydbgui.key 2048
RUN openssl req -new -key /opt/yottadb/gui/ydbgui.key -passin pass:ydbgui -subj '/C=US/ST=Pennsylvania/L=Malvern/CN=localhost' -out /opt/yottadb/gui/ydbgui.csr
RUN openssl req -x509 -days 365 -sha256 -in /opt/yottadb/gui/ydbgui.csr -key /opt/yottadb/gui/ydbgui.key -passin pass:ydbgui -out /opt/yottadb/gui/ydbgui.pem
# Install node.js
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.37.2/install.sh | bash && \
. $HOME/.nvm/nvm.sh && \
nvm install --lts
# Install M Web Server, M-Unit, and GDE GUI for both M and UTF-8 modes
RUN . /opt/yottadb/gui/env && \
for pkg in M-Web-Server M-Unit GUI; \
do \
option=MUMPS && \
cd /opt/yottadb && \
if [ "$pkg" = "M-Web-Server" ]; \
then \
git clone https://github.com/shabiel/M-Web-Server.git; \
cd $pkg; \
elif [ "$pkg" = "M-Unit" ]; \
then \
git clone https://github.com/ChristopherEdwards/M-Unit.git; \
cd $pkg; \
else \
option=M; \
cd /opt/yottadb/gui; \
fi && \
mkdir cmake-build && \
cd cmake-build && \
cmake .. && \
make && \
make install && \
cd .. && \
mkdir cmake-build-utf8 && \
cd cmake-build-utf8 && \
cmake -D${option}_UTF8_MODE=1 .. && \
make && \
make install; \
done
EXPOSE 8080
ENTRYPOINT ["/opt/yottadb/gui/start.sh"]