-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathDockerfile
80 lines (57 loc) · 1.79 KB
/
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
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
FROM huhgawz/oraclelinux-oraclejdk
MAINTAINER Huhgawz <[email protected]>
USER root
ENV LANG=en_US.UTF-8 \
LANGUAGE=en_US.UTF-8 \
LC_ALL=C
RUN yum install -y \
compat-libstdc++-33 \
cpp \
gcc \
gcc-c++ \
glibc-devel \
glibc-headers \
ksh \
libaio \
libaio-devel \
make \
sysstat \
&& yum clean all \
&& rm -rf /var/cache/yum/*
ARG OHS_VERSION=11.1.1.9.0
COPY ofm_webtier_linux_${OHS_VERSION}_64_disk1_1of1.zip /tmp/
RUN unzip /tmp/ofm_webtier_linux_${OHS_VERSION}_64_disk1_1of1.zip -d /tmp/ohs \
&& rm -f /tmp/ofm_webtier_linux_${OHS_VERSION}_64_disk1_1of1.zip
COPY ohs.rsp /tmp/
COPY oraInst.loc /etc/
COPY sysctl.conf /etc/
RUN useradd -d /oracle oracle \
&& echo "oracle:oracle" | chpasswd \
&& chown -R oracle:oracle /tmp/ohs \
&& chown oracle:oracle /tmp/ohs.rsp \
&& chown oracle:oracle /etc/oraInst.loc \
&& chmod 664 /etc/oraInst.loc \
&& touch /etc/profile.d/ohs.sh \
&& chmod 0755 /etc/profile.d/ohs.sh \
&& echo "export ORACLE_INSTANCE=/oracle/Middleware/Oracle_WT1/instances/instance1" >> /etc/profile.d/ohs.sh
USER oracle
ENV ORACLE_INSTANCE /oracle/Middleware/Oracle_WT1/instances/instance1
WORKDIR /tmp/ohs/Disk1
RUN ./runInstaller -silent -waitforcompletion -force -ignoreSysPrereqs -response /tmp/ohs.rsp
WORKDIR /oracle/Middleware/Oracle_WT1/opmn/bin
RUN ./opmnctl stopall
USER root
RUN rm -rf \
/tmp/ohs \
/tmp/ohs.rsp \
/tmp/OraInstall* \
/tmp/hsperfdata_oracle \
/tmp/tmpInvPtrLoc*
#COPY entrypoint.sh /oracle/
#RUN chown oracle:oracle /oracle/entrypoint.sh \
# && chmod +x /oracle/entrypoint.sh
EXPOSE 7777
USER oracle
WORKDIR /oracle/Middleware/Oracle_WT1/opmn/bin
ENTRYPOINT ["/bin/bash"]
#ENTRYPOINT ["/oracle/entrypoint.sh"]