forked from oracle/docker-images
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathadditionalBuildCmds.txt
52 lines (45 loc) · 2.44 KB
/
additionalBuildCmds.txt
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
[package-manager-packages]
hostname
[final-build-commands]
ENV FMW_IDM_JAR=fmw_12.2.1.4.0_idm_generic.jar \
BASE_DIR=/u01 \
ORACLE_HOME=/u01/oracle \
SCRIPT_DIR=/u01/oracle/dockertools \
PROPS_DIR=/u01/oracle/properties \
USER_PROJECTS_DIR=/u01/oracle/user_projects \
DOMAIN_ROOT=/u01/oracle/user_projects/domains \
DOMAIN_NAME="${DOMAIN_NAME:-oam_domain}" \
DOMAIN_HOME="${DOMAIN_ROOT}"/"${DOMAIN_NAME}" \
ADMIN_USER="${ADMIN_USER:-}" \
ADMIN_PASSWORD="${ADMIN_PASSWORD:-}" \
CONNECTION_STRING="${CONNECTION_STRING:-OamDB:1521/orclpdb1.localdomain}" \
CONTAINER_DIR=/u01/oracle/user_projects/container \
ADMIN_LISTEN_HOST="${ADMIN_LISTEN_HOST:-}" \
ADMIN_NAME="${ADMIN_NAME:-AdminServer}" \
ADMIN_LISTEN_PORT="${ADMIN_LISTEN_PORT:-7001}" \
DOMAIN_TYPE="${DOMAIN_TYPE:-oam}" \
RCUPREFIX=${RCUPREFIX:-OAM01} \
DB_USER=${DB_USER:-} \
DB_PASSWORD=${DB_PASSWORD:-} \
DB_SCHEMA_PASSWORD=${DB_SCHEMA_PASSWORD:-} \
USER_MEM_ARGS=${USER_MEM_ARGS:-"-Djava.security.egd=file:/dev/./urandom"} \
JAVA_OPTIONS="${JAVA_OPTIONS} -Dcom.sun.jndi.ldap.object.disableEndpointIdentification=true" \
PATH=$PATH:/usr/java/default/bin:$ORACLE_HOME/oracle_common/common/bin:/u01/oracle/wlserver/common/bin:/u01/oracle/dockertools \
HEALTH_SCRIPT_FILE=/u01/oracle/dockertools/get_healthcheck_url.sh
USER root
RUN mkdir -p ${USER_PROJECTS_DIR} && \
chown -R oracle:root ${USER_PROJECTS_DIR} && chmod -R 775 ${USER_PROJECTS_DIR} && \
chown -R oracle:root ${BASE_DIR} && \
mkdir -p ${CONTAINER_DIR} && \
chown -R oracle:root ${CONTAINER_DIR} && chmod -R 775 ${CONTAINER_DIR} && \
mkdir -p ${SCRIPT_DIR} && chown oracle:root ${SCRIPT_DIR} && \
mkdir -p ${PROPS_DIR} && chown oracle:root ${PROPS_DIR}
COPY --chown=oracle:root files/container-scripts/ ${SCRIPT_DIR}/
RUN chmod a+xr ${SCRIPT_DIR}/* && \
chown -R oracle:root ${SCRIPT_DIR} && \
sed -i '/@@audit\/createCASBAudit.sql/s/@@audit\/createCASBAudit.sql/--@@audit\/createCASBAudit.sql/g' /u01/oracle/idm/common/sql/oam/sql/oam.sql && \
sed -i '/@@diagnostic\/createIdmDiagnosticLogRecord.sql/s/@@diagnostic\/createIdmDiagnosticLogRecord.sql/--@@diagnostic\/createIdmDiagnosticLogRecord.sql/g' /u01/oracle/idm/common/sql/oam/sql/oam.sql
USER oracle
HEALTHCHECK --start-period=5m --interval=1m CMD curl -k -s --fail `$HEALTH_SCRIPT_FILE` || exit 1
WORKDIR $ORACLE_HOME
CMD ["sh", "-c", "${SCRIPT_DIR}/createDomainAndStart.sh"]