-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathapp.Dockerfile
30 lines (29 loc) · 907 Bytes
/
app.Dockerfile
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
FROM ubuntu:16.04
RUN apt-get update && \
apt-get upgrade -y && \
apt-get install -y \
default-jdk \
curl \
sudo \
nano \
grep \
net-tools \
iputils-ping \
telnet \
dnsutils \
openssh-server
RUN mkdir -p /pgrepl/build/libs/
COPY ./build/libs/pgrepl-all-*.jar /pgrepl/build/libs/
RUN sed -i.bak "s/PermitRootLogin prohibit-password/PermitRootLogin yes/g" /etc/ssh/sshd_config && \
echo "root:Docker!" | chpasswd
EXPOSE 8080 1099
ENTRYPOINT service ssh start && \
java \
-Dcom.sun.management.jmxremote \
-Dcom.sun.management.jmxremote.authenticate=false \
-Dcom.sun.management.jmxremote.ssl=false \
-Dcom.sun.management.jmxremote.local.only=false \
-Dcom.sun.management.jmxremote.port=1099 \
-Dcom.sun.management.jmxremote.rmi.port=1099 \
-Djava.rmi.server.hostname=127.0.0.1 \
-jar ./pgrepl/build/libs/pgrepl-all-*.jar