├── Dockerfile ├── LICENSE ├── README.md ├── files ├── db_install_12.rsp ├── db_install_18.rsp ├── db_install_19.rsp ├── download_urls.txt ├── ords_params.properties ├── tomcat-users.xml └── tomcat.service └── scripts ├── create_ca_wallet.sh ├── entrypoint.sh ├── image_setup.sh ├── install_ame.sh ├── install_aop.sh ├── install_apex.sh ├── install_ca_wallet.sh ├── install_java.sh ├── install_logger.sh ├── install_main.sh ├── install_oosutils.sh ├── install_oracle12ee.sh ├── install_oracle18ee.sh ├── install_oracle19ee.sh ├── install_ords.sh ├── install_sqlcl.sh ├── install_ssh.sh ├── install_swagger.sh ├── install_tomcat.sh ├── setenv.sh └── validations.sh /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM oraclelinux:7.9 2 | 3 | MAINTAINER Daniel Hochleitner 4 | 5 | # environment variables 6 | ENV INSTALL_APEX=true \ 7 | INSTALL_SQLCL=true \ 8 | INSTALL_SQLDEVWEB=true \ 9 | INSTALL_LOGGER=true \ 10 | INSTALL_OOSUTILS=true \ 11 | INSTALL_AOP=true \ 12 | INSTALL_AME=true \ 13 | INSTALL_SWAGGER=true \ 14 | INSTALL_CA_CERTS_WALLET=true \ 15 | DBCA_TOTAL_MEMORY=2048 \ 16 | ORACLE_SID=orcl \ 17 | SERVICE_NAME=orcl \ 18 | DB_INSTALL_VERSION=19 \ 19 | ORACLE_BASE=/u01/app/oracle \ 20 | ORACLE_HOME12=/u01/app/oracle/product/12.2.0.1/dbhome \ 21 | ORACLE_HOME18=/u01/app/oracle/product/18.0.0/dbhome \ 22 | ORACLE_HOME19=/u01/app/oracle/product/19.0.0/dbhome \ 23 | ORACLE_INVENTORY=/u01/app/oraInventory \ 24 | PASS=oracle \ 25 | ORDS_HOME=/u01/ords \ 26 | JAVA_HOME=/opt/java \ 27 | TOMCAT_HOME=/opt/tomcat \ 28 | APEX_PASS=OrclAPEX1999! \ 29 | APEX_ADDITIONAL_LANG= \ 30 | APEX_PATCH_SET_BUNDLE_FILE= \ 31 | TIME_ZONE=UTC 32 | 33 | # copy all scripts 34 | ADD scripts /scripts/ 35 | 36 | # copy all files 37 | ADD files /files/ 38 | 39 | # image setup via shell script to reduce layers and optimize final disk usage 40 | RUN /scripts/install_main.sh 41 | 42 | # ssh, database and apex port 43 | EXPOSE 22 1521 8080 44 | 45 | # use ${ORACLE_BASE} without product subdirectory as data volume 46 | VOLUME ["${ORACLE_BASE}"] 47 | 48 | # entrypoint for database creation, startup and graceful shutdown 49 | ENTRYPOINT ["/scripts/entrypoint.sh"] 50 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2020 Daniel Hochleitner 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Oracle Database & APEX Developer Docker Image 2 | 3 | [![APEX Community](https://cdn.rawgit.com/Dani3lSun/apex-github-badges/78c5adbe/badges/apex-community-badge.svg)](https://github.com/Dani3lSun/apex-github-badges) [![APEX Tool](https://cdn.rawgit.com/Dani3lSun/apex-github-badges/b7e95341/badges/apex-tool-badge.svg)](https://github.com/Dani3lSun/apex-github-badges) 4 | [![APEX Built with Love](https://cdn.rawgit.com/Dani3lSun/apex-github-badges/7919f913/badges/apex-love-badge.svg)](https://github.com/Dani3lSun/apex-github-badges) 5 | 6 | ## Content 7 | 8 | This Docker Image contains the following: 9 | 10 | * Oracle Linux 7.9 11 | * Oracle Database 12.2 / 18.3 / 19.3 Enterprise Edition with non-CDB architecture 12 | * Oracle APEX 20.2 13 | * Oracle ORDS 20.3 14 | * Oracle SQLcl 20.3 15 | * Apache Tomcat 8.5.60 16 | * AdoptOpenJDK 11.0.9.1+1 17 | * OraOpenSource Logger 3.1.1 18 | * OraOpenSource OOS Utils 1.0.1 19 | * APEX Office Print 20.x (Cloud Package) 20 | * APEX Media Extension 20.x (Cloud Package) 21 | * Swagger-UI 3.x 22 | 23 | ## Installation 24 | 25 | ### Using Default Settings (recommended) 26 | 27 | Complete the following steps to create a new container: 28 | 29 | 1. **Clone or Download the Github Repository to your local Machine** 30 | 31 | ```bash 32 | git clone https://github.com/Dani3lSun/docker-db-apex-dev.git 33 | ``` 34 | 35 | 2. **Download missing Software Components** 36 | 37 | Thus you have to agree to the License Agreement of Oracle for parts of this Docker Image, you have to download the Install Files by your own. 38 | You can take the direct Download Links from [download_urls.txt](https://github.com/Dani3lSun/docker-db-apex-dev/blob/master/files/download_urls.txt) in [files](https://github.com/Dani3lSun/docker-db-apex-dev/tree/master/files) directory. 39 | 40 | **Direct Links:** 41 | 42 | * [Oracle Database 12.2.0.1 EE](https://download.oracle.com/otn/linux/oracle12c/122010/linuxx64_12201_database.zip) 43 | * [Oracle Database 18.3 EE](https://download.oracle.com/otn/linux/oracle18c/180000/LINUX.X64_180000_db_home.zip) 44 | * [Oracle Database 19.3 EE](https://download.oracle.com/otn/linux/oracle19c/190000/LINUX.X64_193000_db_home.zip) 45 | * [Oracle APEX 20.2](https://download.oracle.com/otn/java/appexpress/apex_20.2.zip) 46 | * [Oracle ORDS 20.3](https://download.oracle.com/otn/java/ords/ords-20.3.0.301.1819.zip) 47 | * [Oracle SQLcl 20.3](https://download.oracle.com/otn/java/sqldeveloper/sqlcl-20.3.0.274.1916.zip) 48 | * [Apache Tomcat 8.5.60](https://www-eu.apache.org/dist/tomcat/tomcat-8/v8.5.60/bin/apache-tomcat-8.5.60.tar.gz) 49 | * [AdoptOpenJDK 11.0.9.1+1 - Linux x64 tar.gz](https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.9.1%2B1/OpenJDK11U-jdk_x64_linux_hotspot_11.0.9.1_1.tar.gz) 50 | * [OraOpenSource Logger 3.1.1](https://github.com/OraOpenSource/Logger/raw/master/releases/logger_3.1.1.zip) 51 | * [OraOpenSource OOS Utils 1.0.1](https://observant-message.glitch.me/oos-utils/latest/oos-utils-latest.zip) 52 | * [APEX Office Print 20.x (Login and download Cloud Package)](https://www.apexofficeprint.com) 53 | * [APEX Media Extension 20.x (Login and download Cloud Package)](https://www.apexmediaextension.com) 54 | * [Swagger-UI v3.x](https://github.com/swagger-api/swagger-ui/archive/v3.35.2.zip) 55 | * [GOSU - Docker SU Fix](https://github.com/tianon/gosu/releases/download/1.12/gosu-amd64) 56 | 57 | **Place all downloaded files in the** [files](https://github.com/Dani3lSun/docker-db-apex-dev/tree/master/files) **directory!** 58 | 59 | *Note: You only need to download one Oracle Database version :) After that you will configure the version you downloaded by editing the Dockerfile* 60 | 61 | 3. **Customize some settings to reflect your needs (optional)** 62 | 63 | You can change some Environment Variables directly in the [Dockerfile](https://github.com/Dani3lSun/docker-db-apex-dev/blob/master/Dockerfile): 64 | 65 | ```bash 66 | INSTALL_APEX=true # Whether install Oracle APEX (Oracle ORDS / Apache Tomcat) or Not 67 | INSTALL_SQLCL=true # Whether install Oracle SQLCL or Not 68 | INSTALL_SQLDEVWEB=true # Whether to enable SQL Developer Web which is part of ORDS >= 19.4 69 | INSTALL_LOGGER=true # Whether install OraOpenSource Logger or Not 70 | INSTALL_OOSUTILS=true # Whether install OraOpenSource OOS Utils or Not 71 | INSTALL_AOP=true # Whether install APEX Office Print (AOP) or Not (Cloud Package) 72 | INSTALL_AME=true # Whether install APEX Media Extension (AME) or Not (Cloud Package) 73 | INSTALL_SWAGGER=true # Whether install Swagger-UI for REST docs or Not 74 | INSTALL_CA_CERTS_WALLET=true # Whether to install an instance wide APEX SSL Wallet containing all valid public root CA certificates 75 | DBCA_TOTAL_MEMORY=2048 # Memory Size of Database 76 | ORACLE_SID=orcl # SID of Oracle Database 77 | SERVICE_NAME=orcl # SERVICE_NAME of Oracle Database 78 | DB_INSTALL_VERSION=19 # Database version to install, 12 or 18 or 19 79 | ORACLE_BASE=/u01/app/oracle # Path to ORACLE_BASE Directory 80 | ORACLE_HOME12=/u01/app/oracle/product/12.2.0.1/dbhome # Path to ORACLE_HOME Directory of 12.2 database 81 | ORACLE_HOME18=/u01/app/oracle/product/18.0.0/dbhome # Path to ORACLE_HOME Directory of 18.3 database 82 | ORACLE_HOME19=/u01/app/oracle/product/19.0.0/dbhome # Path to ORACLE_HOME Directory of 19.3 database 83 | ORACLE_INVENTORY=/u01/app/oraInventory # Path to ORACLE_INVENTORY Directory 84 | PASS=oracle # Password of all Database Users (like SYS, APEX_PUBLIC_USER ...), Tomcat Admin and SSH 85 | ORDS_HOME=/u01/ords # Path to ORDS_HOME Directory 86 | JAVA_HOME=/opt/java # Path to JAVA_HOME Directory 87 | TOMCAT_HOME=/opt/tomcat # Path to TOMCAT_HOME Directory 88 | APEX_PASS=OrclAPEX1999! # Admin Password of Oracle APEX Web Login (Caution: Oracle APEX Password Policy) 89 | APEX_ADDITIONAL_LANG= # Additional Language of APEX, blank to only install English (e.g de, es, fr, it, ja, ko, pt-br, zh-cn, zh-tw) 90 | APEX_PATCH_SET_BUNDLE_FILE= # Additional file name of the APEX Patch Set Bundle zip file (e.g. p32006852_2020_Generic.zip), file should be put into "files" directory 91 | TIME_ZONE=UTC # Timezone of your favorite Location (Europe/Berlin, UTC, US/Eastern, ...) --> Only Linux zoneinfo supported 92 | ``` 93 | 94 | 4. **Build the Docker Image** 95 | 96 | ```bash 97 | cd /path/to/docker-db-apex-dev 98 | docker build -t . 99 | # e.g 100 | docker build -t db-apex-dev-image . 101 | ``` 102 | 103 | *Note: Please be sure to have enough disk space left. Building this image needs around 40-50GB of free space. The successfully built image has a size of 15-16GB* 104 | 105 | 5. **Run the Docker Container** 106 | 107 | ```bash 108 | docker run -d --name -p :22 -p :8080 -p :1521 -v /dev/shm --tmpfs /dev/shm:rw,nosuid,nodev,exec,size=2g 109 | # e.g 110 | docker run -d --name db-apex-dev-container -p 2222:22 -p 8080:8080 -p 1521:1521 -v /dev/shm --tmpfs /dev/shm:rw,nosuid,nodev,exec,size=2g db-apex-dev-image 111 | ``` 112 | 113 | *Note: /dev/shm should be equal the size of allocated Memory to the Database. /dev/shm must also be mounted as tmpfs.* 114 | 115 | 6. **Start/Stop of Docker Container** 116 | 117 | ```bash 118 | docker start 119 | docker stop 120 | # e.g 121 | docker start db-apex-dev-container 122 | docker stop db-apex-dev-container 123 | ``` 124 | 125 | ## Access To Services 126 | 127 | For this Docker Run Example and the **Default Environment Variables (Step 3)**: 128 | 129 | **docker run -d --name db-apex-dev-container -p 2222:22 -p 8080:8080 -p 1521:1521 -v /dev/shm --tmpfs /dev/shm:rw,nosuid,nodev,exec,size=2g db-apex-dev-image** 130 | 131 | ### Oracle APEX 132 | 133 | [http://localhost:8080/ords/](http://localhost:8080/ords/) 134 | 135 | Property | Value 136 | -------- | ----- 137 | Workspace | INTERNAL 138 | User | ADMIN 139 | Password | OrclAPEX1999! 140 | 141 | *If APEX Office Print is installed (INSTALL_AOP=true)* 142 | 143 | Property | Value 144 | -------- | ----- 145 | Workspace | AOP 146 | User | ADMIN 147 | Password | OrclAPEX1999! 148 | 149 | ### SQL Developer Web 150 | 151 | *If SQL Developer Web is enabled (INSTALL_SQLDEVWEB=true)* 152 | 153 | [http://localhost:8080/ords/sql-developer](http://localhost:8080/ords/sql-developer) 154 | 155 | Property | Value 156 | -------- | ----- 157 | User | SDW_ADMIN 158 | Password | oracle 159 | 160 | ### Database Connections 161 | 162 | To access the database e.g. from SQL Developer you configure the following properties: 163 | 164 | Property | Value 165 | -------- | ----- 166 | Hostname | localhost 167 | Port | 1521 168 | SID | orcl 169 | Service | orcl 170 | 171 | The configured user with their credentials are: 172 | 173 | User | Password 174 | -------- | ----- 175 | system | oracle 176 | sys | oracle 177 | apex_listener | oracle 178 | apex\_rest\_public\_user | oracle 179 | apex\_public\_user | oracle 180 | logger\_user | oracle 181 | oosutils\_user | oracle 182 | aop | oracle 183 | ame | oracle 184 | sdw\_admin | oracle 185 | 186 | Use the following connect string to connect as SYSTEM via SQL*Plus or SQLcl: ```system/oracle@localhost/orcl``` 187 | 188 | ### SSH 189 | 190 | To access the Docker Container via SSH: ```ssh root@localhost -p 2222``` 191 | 192 | User | Password 193 | -------- | ----- 194 | root | oracle 195 | oracle | oracle 196 | 197 | If you want to use SSH without a Password but rather with PubKey Authentication you have the place a **authorized_keys** file in the [files](https://github.com/Dani3lSun/docker-db-apex-dev/tree/master/files) directory before build. 198 | 199 | 200 | ## Credits 201 | This Dockerfile is based on the following work: 202 | 203 | - Philipp Salvisberg's GitHub Project [PhilippSalvisberg/docker-oracle12ee](https://github.com/PhilippSalvisberg/docker-oracle12ee) 204 | - Andrzej Raczkowski's GitHub Project [araczkowski/docker-oracle-apex-ords](https://github.com/araczkowski/docker-oracle-apex-ords) 205 | 206 | ## License 207 | 208 | MIT 209 | 210 | See [Oracle Database Licensing Information User Manual](https://docs.oracle.com/database/122/DBLIC/Licensing-Information.htm#DBLIC-GUID-B6113390-9586-46D7-9008-DCC9EDA45AB4) regarding Oracle Database licenses. 211 | -------------------------------------------------------------------------------- /files/db_install_12.rsp: -------------------------------------------------------------------------------- 1 | #################################################################### 2 | ## Copyright(c) Oracle Corporation 1998,2017. All rights reserved.## 3 | ## ## 4 | ## Specify values for the variables listed below to customize ## 5 | ## your installation. ## 6 | ## ## 7 | ## Each variable is associated with a comment. The comment ## 8 | ## can help to populate the variables with the appropriate ## 9 | ## values. ## 10 | ## ## 11 | ## IMPORTANT NOTE: This file contains plain text passwords and ## 12 | ## should be secured to have read permission only by oracle user ## 13 | ## or db administrator who owns this installation. ## 14 | ## ## 15 | #################################################################### 16 | 17 | 18 | #------------------------------------------------------------------------------- 19 | # Do not change the following system generated value. 20 | #------------------------------------------------------------------------------- 21 | oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v12.2.0 22 | 23 | #------------------------------------------------------------------------------- 24 | # Specify the installation option. 25 | # It can be one of the following: 26 | # - INSTALL_DB_SWONLY 27 | # - INSTALL_DB_AND_CONFIG 28 | # - UPGRADE_DB 29 | #------------------------------------------------------------------------------- 30 | oracle.install.option=INSTALL_DB_SWONLY 31 | 32 | #------------------------------------------------------------------------------- 33 | # Specify the Unix group to be set for the inventory directory. 34 | #------------------------------------------------------------------------------- 35 | UNIX_GROUP_NAME=oinstall 36 | 37 | #------------------------------------------------------------------------------- 38 | # Specify the location which holds the inventory files. 39 | # This is an optional parameter if installing on 40 | # Windows based Operating System. 41 | #------------------------------------------------------------------------------- 42 | INVENTORY_LOCATION=#ORACLE_INVENTORY# 43 | 44 | #------------------------------------------------------------------------------- 45 | # Specify the complete path of the Oracle Home. 46 | #------------------------------------------------------------------------------- 47 | ORACLE_HOME=#ORACLE_HOME# 48 | 49 | #------------------------------------------------------------------------------- 50 | # Specify the complete path of the Oracle Base. 51 | #------------------------------------------------------------------------------- 52 | ORACLE_BASE=#ORACLE_BASE# 53 | 54 | #------------------------------------------------------------------------------- 55 | # Specify the installation edition of the component. 56 | # 57 | # The value should contain only one of these choices. 58 | # - EE : Enterprise Edition 59 | # - SE2 : Standard Edition 2 60 | #------------------------------------------------------------------------------- 61 | oracle.install.db.InstallEdition=EE 62 | 63 | ############################################################################### 64 | # # 65 | # PRIVILEGED OPERATING SYSTEM GROUPS # 66 | # ------------------------------------------ # 67 | # Provide values for the OS groups to which SYSDBA and SYSOPER privileges # 68 | # needs to be granted. If the install is being performed as a member of the # 69 | # group "dba", then that will be used unless specified otherwise below. # 70 | # # 71 | # The value to be specified for OSDBA and OSOPER group is only for UNIX based # 72 | # Operating System. # 73 | # # 74 | ############################################################################### 75 | 76 | #------------------------------------------------------------------------------ 77 | # The OSDBA_GROUP is the OS group which is to be granted SYSDBA privileges. 78 | #------------------------------------------------------------------------------- 79 | oracle.install.db.OSDBA_GROUP=dba 80 | 81 | #------------------------------------------------------------------------------ 82 | # The OSOPER_GROUP is the OS group which is to be granted SYSOPER privileges. 83 | # The value to be specified for OSOPER group is optional. 84 | #------------------------------------------------------------------------------ 85 | oracle.install.db.OSOPER_GROUP=oper 86 | 87 | #------------------------------------------------------------------------------ 88 | # The OSBACKUPDBA_GROUP is the OS group which is to be granted SYSBACKUP privileges. 89 | #------------------------------------------------------------------------------ 90 | oracle.install.db.OSBACKUPDBA_GROUP=dba 91 | 92 | #------------------------------------------------------------------------------ 93 | # The OSDGDBA_GROUP is the OS group which is to be granted SYSDG privileges. 94 | #------------------------------------------------------------------------------ 95 | oracle.install.db.OSDGDBA_GROUP=dba 96 | 97 | #------------------------------------------------------------------------------ 98 | # The OSKMDBA_GROUP is the OS group which is to be granted SYSKM privileges. 99 | #------------------------------------------------------------------------------ 100 | oracle.install.db.OSKMDBA_GROUP=dba 101 | 102 | #------------------------------------------------------------------------------ 103 | # The OSRACDBA_GROUP is the OS group which is to be granted SYSRAC privileges. 104 | #------------------------------------------------------------------------------ 105 | oracle.install.db.OSRACDBA_GROUP=dba 106 | 107 | ############################################################################### 108 | # # 109 | # Grid Options # 110 | # # 111 | ############################################################################### 112 | #------------------------------------------------------------------------------ 113 | # Specify the type of Real Application Cluster Database 114 | # 115 | # - ADMIN_MANAGED: Admin-Managed 116 | # - POLICY_MANAGED: Policy-Managed 117 | # 118 | # If left unspecified, default will be ADMIN_MANAGED 119 | #------------------------------------------------------------------------------ 120 | oracle.install.db.rac.configurationType= 121 | 122 | #------------------------------------------------------------------------------ 123 | # Value is required only if RAC database type is ADMIN_MANAGED 124 | # 125 | # Specify the cluster node names selected during the installation. 126 | # Leaving it blank will result in install on local server only (Single Instance) 127 | # 128 | # Example : oracle.install.db.CLUSTER_NODES=node1,node2 129 | #------------------------------------------------------------------------------ 130 | oracle.install.db.CLUSTER_NODES= 131 | 132 | #------------------------------------------------------------------------------ 133 | # This variable is used to enable or disable RAC One Node install. 134 | # 135 | # - true : Value of RAC One Node service name is used. 136 | # - false : Value of RAC One Node service name is not used. 137 | # 138 | # If left blank, it will be assumed to be false. 139 | #------------------------------------------------------------------------------ 140 | oracle.install.db.isRACOneInstall= 141 | 142 | #------------------------------------------------------------------------------ 143 | # Value is required only if oracle.install.db.isRACOneInstall is true. 144 | # 145 | # Specify the name for RAC One Node Service 146 | #------------------------------------------------------------------------------ 147 | oracle.install.db.racOneServiceName= 148 | 149 | #------------------------------------------------------------------------------ 150 | # Value is required only if RAC database type is POLICY_MANAGED 151 | # 152 | # Specify a name for the new Server pool that will be configured 153 | # Example : oracle.install.db.rac.serverpoolName=pool1 154 | #------------------------------------------------------------------------------ 155 | oracle.install.db.rac.serverpoolName= 156 | 157 | #------------------------------------------------------------------------------ 158 | # Value is required only if RAC database type is POLICY_MANAGED 159 | # 160 | # Specify a number as cardinality for the new Server pool that will be configured 161 | # Example : oracle.install.db.rac.serverpoolCardinality=2 162 | #------------------------------------------------------------------------------ 163 | oracle.install.db.rac.serverpoolCardinality= 164 | 165 | ############################################################################### 166 | # # 167 | # Database Configuration Options # 168 | # # 169 | ############################################################################### 170 | 171 | #------------------------------------------------------------------------------- 172 | # Specify the type of database to create. 173 | # It can be one of the following: 174 | # - GENERAL_PURPOSE 175 | # - DATA_WAREHOUSE 176 | # GENERAL_PURPOSE: A starter database designed for general purpose use or transaction-heavy applications. 177 | # DATA_WAREHOUSE : A starter database optimized for data warehousing applications. 178 | #------------------------------------------------------------------------------- 179 | oracle.install.db.config.starterdb.type= 180 | 181 | #------------------------------------------------------------------------------- 182 | # Specify the Starter Database Global Database Name. 183 | #------------------------------------------------------------------------------- 184 | oracle.install.db.config.starterdb.globalDBName= 185 | 186 | #------------------------------------------------------------------------------- 187 | # Specify the Starter Database SID. 188 | #------------------------------------------------------------------------------- 189 | oracle.install.db.config.starterdb.SID= 190 | 191 | #------------------------------------------------------------------------------- 192 | # Specify whether the database should be configured as a Container database. 193 | # The value can be either "true" or "false". If left blank it will be assumed 194 | # to be "false". 195 | #------------------------------------------------------------------------------- 196 | oracle.install.db.ConfigureAsContainerDB= 197 | 198 | #------------------------------------------------------------------------------- 199 | # Specify the Pluggable Database name for the pluggable database in Container Database. 200 | #------------------------------------------------------------------------------- 201 | oracle.install.db.config.PDBName= 202 | 203 | #------------------------------------------------------------------------------- 204 | # Specify the Starter Database character set. 205 | # 206 | # One of the following 207 | # AL32UTF8, WE8ISO8859P15, WE8MSWIN1252, EE8ISO8859P2, 208 | # EE8MSWIN1250, NE8ISO8859P10, NEE8ISO8859P4, BLT8MSWIN1257, 209 | # BLT8ISO8859P13, CL8ISO8859P5, CL8MSWIN1251, AR8ISO8859P6, 210 | # AR8MSWIN1256, EL8ISO8859P7, EL8MSWIN1253, IW8ISO8859P8, 211 | # IW8MSWIN1255, JA16EUC, JA16EUCTILDE, JA16SJIS, JA16SJISTILDE, 212 | # KO16MSWIN949, ZHS16GBK, TH8TISASCII, ZHT32EUC, ZHT16MSWIN950, 213 | # ZHT16HKSCS, WE8ISO8859P9, TR8MSWIN1254, VN8MSWIN1258 214 | #------------------------------------------------------------------------------- 215 | oracle.install.db.config.starterdb.characterSet= 216 | 217 | #------------------------------------------------------------------------------ 218 | # This variable should be set to true if Automatic Memory Management 219 | # in Database is desired. 220 | # If Automatic Memory Management is not desired, and memory allocation 221 | # is to be done manually, then set it to false. 222 | #------------------------------------------------------------------------------ 223 | oracle.install.db.config.starterdb.memoryOption= 224 | 225 | #------------------------------------------------------------------------------- 226 | # Specify the total memory allocation for the database. Value(in MB) should be 227 | # at least 256 MB, and should not exceed the total physical memory available 228 | # on the system. 229 | # Example: oracle.install.db.config.starterdb.memoryLimit=512 230 | #------------------------------------------------------------------------------- 231 | oracle.install.db.config.starterdb.memoryLimit= 232 | 233 | #------------------------------------------------------------------------------- 234 | # This variable controls whether to load Example Schemas onto 235 | # the starter database or not. 236 | # The value can be either "true" or "false". If left blank it will be assumed 237 | # to be "false". 238 | #------------------------------------------------------------------------------- 239 | oracle.install.db.config.starterdb.installExampleSchemas= 240 | 241 | ############################################################################### 242 | # # 243 | # Passwords can be supplied for the following four schemas in the # 244 | # starter database: # 245 | # SYS # 246 | # SYSTEM # 247 | # DBSNMP (used by Enterprise Manager) # 248 | # # 249 | # Same password can be used for all accounts (not recommended) # 250 | # or different passwords for each account can be provided (recommended) # 251 | # # 252 | ############################################################################### 253 | 254 | #------------------------------------------------------------------------------ 255 | # This variable holds the password that is to be used for all schemas in the 256 | # starter database. 257 | #------------------------------------------------------------------------------- 258 | oracle.install.db.config.starterdb.password.ALL= 259 | 260 | #------------------------------------------------------------------------------- 261 | # Specify the SYS password for the starter database. 262 | #------------------------------------------------------------------------------- 263 | oracle.install.db.config.starterdb.password.SYS= 264 | 265 | #------------------------------------------------------------------------------- 266 | # Specify the SYSTEM password for the starter database. 267 | #------------------------------------------------------------------------------- 268 | oracle.install.db.config.starterdb.password.SYSTEM= 269 | 270 | #------------------------------------------------------------------------------- 271 | # Specify the DBSNMP password for the starter database. 272 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 273 | #------------------------------------------------------------------------------- 274 | oracle.install.db.config.starterdb.password.DBSNMP= 275 | 276 | #------------------------------------------------------------------------------- 277 | # Specify the PDBADMIN password required for creation of Pluggable Database in the Container Database. 278 | #------------------------------------------------------------------------------- 279 | oracle.install.db.config.starterdb.password.PDBADMIN= 280 | 281 | #------------------------------------------------------------------------------- 282 | # Specify the management option to use for managing the database. 283 | # Options are: 284 | # 1. CLOUD_CONTROL - If you want to manage your database with Enterprise Manager Cloud Control along with Database Express. 285 | # 2. DEFAULT -If you want to manage your database using the default Database Express option. 286 | #------------------------------------------------------------------------------- 287 | oracle.install.db.config.starterdb.managementOption= 288 | 289 | #------------------------------------------------------------------------------- 290 | # Specify the OMS host to connect to Cloud Control. 291 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 292 | #------------------------------------------------------------------------------- 293 | oracle.install.db.config.starterdb.omsHost= 294 | 295 | #------------------------------------------------------------------------------- 296 | # Specify the OMS port to connect to Cloud Control. 297 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 298 | #------------------------------------------------------------------------------- 299 | oracle.install.db.config.starterdb.omsPort= 300 | 301 | #------------------------------------------------------------------------------- 302 | # Specify the EM Admin user name to use to connect to Cloud Control. 303 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 304 | #------------------------------------------------------------------------------- 305 | oracle.install.db.config.starterdb.emAdminUser= 306 | 307 | #------------------------------------------------------------------------------- 308 | # Specify the EM Admin password to use to connect to Cloud Control. 309 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 310 | #------------------------------------------------------------------------------- 311 | oracle.install.db.config.starterdb.emAdminPassword= 312 | 313 | ############################################################################### 314 | # # 315 | # SPECIFY RECOVERY OPTIONS # 316 | # ------------------------------------ # 317 | # Recovery options for the database can be mentioned using the entries below # 318 | # # 319 | ############################################################################### 320 | 321 | #------------------------------------------------------------------------------ 322 | # This variable is to be set to false if database recovery is not required. Else 323 | # this can be set to true. 324 | #------------------------------------------------------------------------------- 325 | oracle.install.db.config.starterdb.enableRecovery= 326 | 327 | #------------------------------------------------------------------------------- 328 | # Specify the type of storage to use for the database. 329 | # It can be one of the following: 330 | # - FILE_SYSTEM_STORAGE 331 | # - ASM_STORAGE 332 | #------------------------------------------------------------------------------- 333 | oracle.install.db.config.starterdb.storageType= 334 | 335 | #------------------------------------------------------------------------------- 336 | # Specify the database file location which is a directory for datafiles, control 337 | # files, redo logs. 338 | # 339 | # Applicable only when oracle.install.db.config.starterdb.storage=FILE_SYSTEM_STORAGE 340 | #------------------------------------------------------------------------------- 341 | oracle.install.db.config.starterdb.fileSystemStorage.dataLocation= 342 | 343 | #------------------------------------------------------------------------------- 344 | # Specify the recovery location. 345 | # 346 | # Applicable only when oracle.install.db.config.starterdb.storage=FILE_SYSTEM_STORAGE 347 | #------------------------------------------------------------------------------- 348 | oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation= 349 | 350 | #------------------------------------------------------------------------------- 351 | # Specify the existing ASM disk groups to be used for storage. 352 | # 353 | # Applicable only when oracle.install.db.config.starterdb.storageType=ASM_STORAGE 354 | #------------------------------------------------------------------------------- 355 | oracle.install.db.config.asm.diskGroup= 356 | 357 | #------------------------------------------------------------------------------- 358 | # Specify the password for ASMSNMP user of the ASM instance. 359 | # 360 | # Applicable only when oracle.install.db.config.starterdb.storage=ASM_STORAGE 361 | #------------------------------------------------------------------------------- 362 | oracle.install.db.config.asm.ASMSNMPPassword= 363 | 364 | #------------------------------------------------------------------------------ 365 | # Specify the My Oracle Support Account Username. 366 | # 367 | # Example : MYORACLESUPPORT_USERNAME=abc@oracle.com 368 | #------------------------------------------------------------------------------ 369 | MYORACLESUPPORT_USERNAME= 370 | 371 | #------------------------------------------------------------------------------ 372 | # Specify the My Oracle Support Account Username password. 373 | # 374 | # Example : MYORACLESUPPORT_PASSWORD=password 375 | #------------------------------------------------------------------------------ 376 | MYORACLESUPPORT_PASSWORD= 377 | 378 | #------------------------------------------------------------------------------ 379 | # Specify whether to enable the user to set the password for 380 | # My Oracle Support credentials. The value can be either true or false. 381 | # If left blank it will be assumed to be false. 382 | # 383 | # Example : SECURITY_UPDATES_VIA_MYORACLESUPPORT=true 384 | #------------------------------------------------------------------------------ 385 | SECURITY_UPDATES_VIA_MYORACLESUPPORT= 386 | 387 | #------------------------------------------------------------------------------ 388 | # Specify whether user doesn't want to configure Security Updates. 389 | # The value for this variable should be true if you don't want to configure 390 | # Security Updates, false otherwise. 391 | # 392 | # The value can be either true or false. If left blank it will be assumed 393 | # to be true. 394 | # 395 | # Example : DECLINE_SECURITY_UPDATES=false 396 | #------------------------------------------------------------------------------ 397 | DECLINE_SECURITY_UPDATES= 398 | 399 | #------------------------------------------------------------------------------ 400 | # Specify the Proxy server name. Length should be greater than zero. 401 | # 402 | # Example : PROXY_HOST=proxy.domain.com 403 | #------------------------------------------------------------------------------ 404 | PROXY_HOST= 405 | 406 | #------------------------------------------------------------------------------ 407 | # Specify the proxy port number. Should be Numeric and at least 2 chars. 408 | # 409 | # Example : PROXY_PORT=25 410 | #------------------------------------------------------------------------------ 411 | PROXY_PORT= 412 | 413 | #------------------------------------------------------------------------------ 414 | # Specify the proxy user name. Leave PROXY_USER and PROXY_PWD 415 | # blank if your proxy server requires no authentication. 416 | # 417 | # Example : PROXY_USER=username 418 | #------------------------------------------------------------------------------ 419 | PROXY_USER= 420 | 421 | #------------------------------------------------------------------------------ 422 | # Specify the proxy password. Leave PROXY_USER and PROXY_PWD 423 | # blank if your proxy server requires no authentication. 424 | # 425 | # Example : PROXY_PWD=password 426 | #------------------------------------------------------------------------------ 427 | PROXY_PWD= 428 | 429 | #------------------------------------------------------------------------------ 430 | # Specify the Oracle Support Hub URL. 431 | # 432 | # Example : COLLECTOR_SUPPORTHUB_URL=https://orasupporthub.company.com:8080/ 433 | #------------------------------------------------------------------------------ 434 | COLLECTOR_SUPPORTHUB_URL= -------------------------------------------------------------------------------- /files/db_install_18.rsp: -------------------------------------------------------------------------------- 1 | #################################################################### 2 | ## Copyright(c) Oracle Corporation 1998,2018. All rights reserved.## 3 | ## ## 4 | ## Specify values for the variables listed below to customize ## 5 | ## your installation. ## 6 | ## ## 7 | ## Each variable is associated with a comment. The comment ## 8 | ## can help to populate the variables with the appropriate ## 9 | ## values. ## 10 | ## ## 11 | ## IMPORTANT NOTE: This file contains plain text passwords and ## 12 | ## should be secured to have read permission only by oracle user ## 13 | ## or db administrator who owns this installation. ## 14 | ## ## 15 | #################################################################### 16 | 17 | 18 | #------------------------------------------------------------------------------- 19 | # Do not change the following system generated value. 20 | #------------------------------------------------------------------------------- 21 | oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v18.0.0 22 | 23 | #------------------------------------------------------------------------------- 24 | # Specify the installation option. 25 | # It can be one of the following: 26 | # - INSTALL_DB_SWONLY 27 | # - INSTALL_DB_AND_CONFIG 28 | #------------------------------------------------------------------------------- 29 | oracle.install.option=INSTALL_DB_SWONLY 30 | 31 | #------------------------------------------------------------------------------- 32 | # Specify the Unix group to be set for the inventory directory. 33 | #------------------------------------------------------------------------------- 34 | UNIX_GROUP_NAME=oinstall 35 | 36 | #------------------------------------------------------------------------------- 37 | # Specify the location which holds the inventory files. 38 | # This is an optional parameter if installing on 39 | # Windows based Operating System. 40 | #------------------------------------------------------------------------------- 41 | INVENTORY_LOCATION=#ORACLE_INVENTORY# 42 | #------------------------------------------------------------------------------- 43 | # Specify the complete path of the Oracle Home. 44 | #------------------------------------------------------------------------------- 45 | ORACLE_HOME=#ORACLE_HOME# 46 | 47 | #------------------------------------------------------------------------------- 48 | # Specify the complete path of the Oracle Base. 49 | #------------------------------------------------------------------------------- 50 | ORACLE_BASE=#ORACLE_BASE# 51 | 52 | #------------------------------------------------------------------------------- 53 | # Specify the installation edition of the component. 54 | # 55 | # The value should contain only one of these choices. 56 | # - EE : Enterprise Edition 57 | # - SE2 : Standard Edition 2 58 | 59 | 60 | #------------------------------------------------------------------------------- 61 | 62 | oracle.install.db.InstallEdition=EE 63 | ############################################################################### 64 | # # 65 | # PRIVILEGED OPERATING SYSTEM GROUPS # 66 | # ------------------------------------------ # 67 | # Provide values for the OS groups to which SYSDBA and SYSOPER privileges # 68 | # needs to be granted. If the install is being performed as a member of the # 69 | # group "dba", then that will be used unless specified otherwise below. # 70 | # # 71 | # The value to be specified for OSDBA and OSOPER group is only for UNIX based # 72 | # Operating System. # 73 | # # 74 | ############################################################################### 75 | 76 | #------------------------------------------------------------------------------ 77 | # The OSDBA_GROUP is the OS group which is to be granted SYSDBA privileges. 78 | #------------------------------------------------------------------------------- 79 | oracle.install.db.OSDBA_GROUP=dba 80 | 81 | #------------------------------------------------------------------------------ 82 | # The OSOPER_GROUP is the OS group which is to be granted SYSOPER privileges. 83 | # The value to be specified for OSOPER group is optional. 84 | #------------------------------------------------------------------------------ 85 | oracle.install.db.OSOPER_GROUP=oper 86 | 87 | #------------------------------------------------------------------------------ 88 | # The OSBACKUPDBA_GROUP is the OS group which is to be granted SYSBACKUP privileges. 89 | #------------------------------------------------------------------------------ 90 | oracle.install.db.OSBACKUPDBA_GROUP=dba 91 | 92 | #------------------------------------------------------------------------------ 93 | # The OSDGDBA_GROUP is the OS group which is to be granted SYSDG privileges. 94 | #------------------------------------------------------------------------------ 95 | oracle.install.db.OSDGDBA_GROUP=dba 96 | 97 | #------------------------------------------------------------------------------ 98 | # The OSKMDBA_GROUP is the OS group which is to be granted SYSKM privileges. 99 | #------------------------------------------------------------------------------ 100 | oracle.install.db.OSKMDBA_GROUP=dba 101 | 102 | #------------------------------------------------------------------------------ 103 | # The OSRACDBA_GROUP is the OS group which is to be granted SYSRAC privileges. 104 | #------------------------------------------------------------------------------ 105 | oracle.install.db.OSRACDBA_GROUP=dba 106 | 107 | ############################################################################### 108 | # # 109 | # Grid Options # 110 | # # 111 | ############################################################################### 112 | 113 | #------------------------------------------------------------------------------ 114 | # Value is required only if the specified install option is INSTALL_DB_SWONLY 115 | # 116 | # Specify the cluster node names selected during the installation. 117 | # 118 | # Example : oracle.install.db.CLUSTER_NODES=node1,node2 119 | #------------------------------------------------------------------------------ 120 | oracle.install.db.CLUSTER_NODES= 121 | 122 | ############################################################################### 123 | # # 124 | # Database Configuration Options # 125 | # # 126 | ############################################################################### 127 | 128 | #------------------------------------------------------------------------------- 129 | # Specify the type of database to create. 130 | # It can be one of the following: 131 | # - GENERAL_PURPOSE 132 | # - DATA_WAREHOUSE 133 | # GENERAL_PURPOSE: A starter database designed for general purpose use or transaction-heavy applications. 134 | # DATA_WAREHOUSE : A starter database optimized for data warehousing applications. 135 | #------------------------------------------------------------------------------- 136 | oracle.install.db.config.starterdb.type= 137 | 138 | #------------------------------------------------------------------------------- 139 | # Specify the Starter Database Global Database Name. 140 | #------------------------------------------------------------------------------- 141 | oracle.install.db.config.starterdb.globalDBName= 142 | 143 | #------------------------------------------------------------------------------- 144 | # Specify the Starter Database SID. 145 | #------------------------------------------------------------------------------- 146 | oracle.install.db.config.starterdb.SID= 147 | 148 | #------------------------------------------------------------------------------- 149 | # Specify whether the database should be configured as a Container database. 150 | # The value can be either "true" or "false". If left blank it will be assumed 151 | # to be "false". 152 | #------------------------------------------------------------------------------- 153 | oracle.install.db.ConfigureAsContainerDB= 154 | 155 | #------------------------------------------------------------------------------- 156 | # Specify the Pluggable Database name for the pluggable database in Container Database. 157 | #------------------------------------------------------------------------------- 158 | oracle.install.db.config.PDBName= 159 | 160 | #------------------------------------------------------------------------------- 161 | # Specify the Starter Database character set. 162 | # 163 | # One of the following 164 | # AL32UTF8, WE8ISO8859P15, WE8MSWIN1252, EE8ISO8859P2, 165 | # EE8MSWIN1250, NE8ISO8859P10, NEE8ISO8859P4, BLT8MSWIN1257, 166 | # BLT8ISO8859P13, CL8ISO8859P5, CL8MSWIN1251, AR8ISO8859P6, 167 | # AR8MSWIN1256, EL8ISO8859P7, EL8MSWIN1253, IW8ISO8859P8, 168 | # IW8MSWIN1255, JA16EUC, JA16EUCTILDE, JA16SJIS, JA16SJISTILDE, 169 | # KO16MSWIN949, ZHS16GBK, TH8TISASCII, ZHT32EUC, ZHT16MSWIN950, 170 | # ZHT16HKSCS, WE8ISO8859P9, TR8MSWIN1254, VN8MSWIN1258 171 | #------------------------------------------------------------------------------- 172 | oracle.install.db.config.starterdb.characterSet= 173 | 174 | #------------------------------------------------------------------------------ 175 | # This variable should be set to true if Automatic Memory Management 176 | # in Database is desired. 177 | # If Automatic Memory Management is not desired, and memory allocation 178 | # is to be done manually, then set it to false. 179 | #------------------------------------------------------------------------------ 180 | oracle.install.db.config.starterdb.memoryOption= 181 | 182 | #------------------------------------------------------------------------------- 183 | # Specify the total memory allocation for the database. Value(in MB) should be 184 | # at least 256 MB, and should not exceed the total physical memory available 185 | # on the system. 186 | # Example: oracle.install.db.config.starterdb.memoryLimit=512 187 | #------------------------------------------------------------------------------- 188 | oracle.install.db.config.starterdb.memoryLimit= 189 | 190 | #------------------------------------------------------------------------------- 191 | # This variable controls whether to load Example Schemas onto 192 | # the starter database or not. 193 | # The value can be either "true" or "false". If left blank it will be assumed 194 | # to be "false". 195 | #------------------------------------------------------------------------------- 196 | oracle.install.db.config.starterdb.installExampleSchemas= 197 | 198 | ############################################################################### 199 | # # 200 | # Passwords can be supplied for the following four schemas in the # 201 | # starter database: # 202 | # SYS # 203 | # SYSTEM # 204 | # DBSNMP (used by Enterprise Manager) # 205 | # # 206 | # Same password can be used for all accounts (not recommended) # 207 | # or different passwords for each account can be provided (recommended) # 208 | # # 209 | ############################################################################### 210 | 211 | #------------------------------------------------------------------------------ 212 | # This variable holds the password that is to be used for all schemas in the 213 | # starter database. 214 | #------------------------------------------------------------------------------- 215 | oracle.install.db.config.starterdb.password.ALL= 216 | 217 | #------------------------------------------------------------------------------- 218 | # Specify the SYS password for the starter database. 219 | #------------------------------------------------------------------------------- 220 | oracle.install.db.config.starterdb.password.SYS= 221 | 222 | #------------------------------------------------------------------------------- 223 | # Specify the SYSTEM password for the starter database. 224 | #------------------------------------------------------------------------------- 225 | oracle.install.db.config.starterdb.password.SYSTEM= 226 | 227 | #------------------------------------------------------------------------------- 228 | # Specify the DBSNMP password for the starter database. 229 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 230 | #------------------------------------------------------------------------------- 231 | oracle.install.db.config.starterdb.password.DBSNMP= 232 | 233 | #------------------------------------------------------------------------------- 234 | # Specify the PDBADMIN password required for creation of Pluggable Database in the Container Database. 235 | #------------------------------------------------------------------------------- 236 | oracle.install.db.config.starterdb.password.PDBADMIN= 237 | 238 | #------------------------------------------------------------------------------- 239 | # Specify the management option to use for managing the database. 240 | # Options are: 241 | # 1. CLOUD_CONTROL - If you want to manage your database with Enterprise Manager Cloud Control along with Database Express. 242 | # 2. DEFAULT -If you want to manage your database using the default Database Express option. 243 | #------------------------------------------------------------------------------- 244 | oracle.install.db.config.starterdb.managementOption= 245 | 246 | #------------------------------------------------------------------------------- 247 | # Specify the OMS host to connect to Cloud Control. 248 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 249 | #------------------------------------------------------------------------------- 250 | oracle.install.db.config.starterdb.omsHost= 251 | 252 | #------------------------------------------------------------------------------- 253 | # Specify the OMS port to connect to Cloud Control. 254 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 255 | #------------------------------------------------------------------------------- 256 | oracle.install.db.config.starterdb.omsPort= 257 | 258 | #------------------------------------------------------------------------------- 259 | # Specify the EM Admin user name to use to connect to Cloud Control. 260 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 261 | #------------------------------------------------------------------------------- 262 | oracle.install.db.config.starterdb.emAdminUser= 263 | 264 | #------------------------------------------------------------------------------- 265 | # Specify the EM Admin password to use to connect to Cloud Control. 266 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 267 | #------------------------------------------------------------------------------- 268 | oracle.install.db.config.starterdb.emAdminPassword= 269 | 270 | ############################################################################### 271 | # # 272 | # SPECIFY RECOVERY OPTIONS # 273 | # ------------------------------------ # 274 | # Recovery options for the database can be mentioned using the entries below # 275 | # # 276 | ############################################################################### 277 | 278 | #------------------------------------------------------------------------------ 279 | # This variable is to be set to false if database recovery is not required. Else 280 | # this can be set to true. 281 | #------------------------------------------------------------------------------- 282 | oracle.install.db.config.starterdb.enableRecovery= 283 | 284 | #------------------------------------------------------------------------------- 285 | # Specify the type of storage to use for the database. 286 | # It can be one of the following: 287 | # - FILE_SYSTEM_STORAGE 288 | # - ASM_STORAGE 289 | #------------------------------------------------------------------------------- 290 | oracle.install.db.config.starterdb.storageType= 291 | 292 | #------------------------------------------------------------------------------- 293 | # Specify the database file location which is a directory for datafiles, control 294 | # files, redo logs. 295 | # 296 | # Applicable only when oracle.install.db.config.starterdb.storage=FILE_SYSTEM_STORAGE 297 | #------------------------------------------------------------------------------- 298 | oracle.install.db.config.starterdb.fileSystemStorage.dataLocation= 299 | 300 | #------------------------------------------------------------------------------- 301 | # Specify the recovery location. 302 | # 303 | # Applicable only when oracle.install.db.config.starterdb.storage=FILE_SYSTEM_STORAGE 304 | #------------------------------------------------------------------------------- 305 | oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation= 306 | 307 | #------------------------------------------------------------------------------- 308 | # Specify the existing ASM disk groups to be used for storage. 309 | # 310 | # Applicable only when oracle.install.db.config.starterdb.storageType=ASM_STORAGE 311 | #------------------------------------------------------------------------------- 312 | oracle.install.db.config.asm.diskGroup= 313 | 314 | #------------------------------------------------------------------------------- 315 | # Specify the password for ASMSNMP user of the ASM instance. 316 | # 317 | # Applicable only when oracle.install.db.config.starterdb.storage=ASM_STORAGE 318 | #------------------------------------------------------------------------------- 319 | oracle.install.db.config.asm.ASMSNMPPassword= 320 | -------------------------------------------------------------------------------- /files/db_install_19.rsp: -------------------------------------------------------------------------------- 1 | #################################################################### 2 | ## Copyright(c) Oracle Corporation 1998,2019. All rights reserved.## 3 | ## ## 4 | ## Specify values for the variables listed below to customize ## 5 | ## your installation. ## 6 | ## ## 7 | ## Each variable is associated with a comment. The comment ## 8 | ## can help to populate the variables with the appropriate ## 9 | ## values. ## 10 | ## ## 11 | ## IMPORTANT NOTE: This file contains plain text passwords and ## 12 | ## should be secured to have read permission only by oracle user ## 13 | ## or db administrator who owns this installation. ## 14 | ## ## 15 | #################################################################### 16 | 17 | 18 | #------------------------------------------------------------------------------- 19 | # Do not change the following system generated value. 20 | #------------------------------------------------------------------------------- 21 | oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v19.0.0 22 | 23 | #------------------------------------------------------------------------------- 24 | # Specify the installation option. 25 | # It can be one of the following: 26 | # - INSTALL_DB_SWONLY 27 | # - INSTALL_DB_AND_CONFIG 28 | #------------------------------------------------------------------------------- 29 | oracle.install.option=INSTALL_DB_SWONLY 30 | 31 | #------------------------------------------------------------------------------- 32 | # Specify the Unix group to be set for the inventory directory. 33 | #------------------------------------------------------------------------------- 34 | UNIX_GROUP_NAME=oinstall 35 | 36 | #------------------------------------------------------------------------------- 37 | # Specify the location which holds the inventory files. 38 | # This is an optional parameter if installing on 39 | # Windows based Operating System. 40 | #------------------------------------------------------------------------------- 41 | INVENTORY_LOCATION=#ORACLE_INVENTORY# 42 | #------------------------------------------------------------------------------- 43 | # Specify the complete path of the Oracle Home. 44 | #------------------------------------------------------------------------------- 45 | ORACLE_HOME=#ORACLE_HOME# 46 | 47 | #------------------------------------------------------------------------------- 48 | # Specify the complete path of the Oracle Base. 49 | #------------------------------------------------------------------------------- 50 | ORACLE_BASE=#ORACLE_BASE# 51 | 52 | #------------------------------------------------------------------------------- 53 | # Specify the installation edition of the component. 54 | # 55 | # The value should contain only one of these choices. 56 | # - EE : Enterprise Edition 57 | # - SE2 : Standard Edition 2 58 | 59 | 60 | #------------------------------------------------------------------------------- 61 | 62 | oracle.install.db.InstallEdition=EE 63 | ############################################################################### 64 | # # 65 | # PRIVILEGED OPERATING SYSTEM GROUPS # 66 | # ------------------------------------------ # 67 | # Provide values for the OS groups to which SYSDBA and SYSOPER privileges # 68 | # needs to be granted. If the install is being performed as a member of the # 69 | # group "dba", then that will be used unless specified otherwise below. # 70 | # # 71 | # The value to be specified for OSDBA and OSOPER group is only for UNIX based # 72 | # Operating System. # 73 | # # 74 | ############################################################################### 75 | 76 | #------------------------------------------------------------------------------ 77 | # The OSDBA_GROUP is the OS group which is to be granted SYSDBA privileges. 78 | #------------------------------------------------------------------------------- 79 | oracle.install.db.OSDBA_GROUP=dba 80 | 81 | #------------------------------------------------------------------------------ 82 | # The OSOPER_GROUP is the OS group which is to be granted SYSOPER privileges. 83 | # The value to be specified for OSOPER group is optional. 84 | #------------------------------------------------------------------------------ 85 | oracle.install.db.OSOPER_GROUP=oper 86 | 87 | #------------------------------------------------------------------------------ 88 | # The OSBACKUPDBA_GROUP is the OS group which is to be granted SYSBACKUP privileges. 89 | #------------------------------------------------------------------------------ 90 | oracle.install.db.OSBACKUPDBA_GROUP=dba 91 | 92 | #------------------------------------------------------------------------------ 93 | # The OSDGDBA_GROUP is the OS group which is to be granted SYSDG privileges. 94 | #------------------------------------------------------------------------------ 95 | oracle.install.db.OSDGDBA_GROUP=dba 96 | 97 | #------------------------------------------------------------------------------ 98 | # The OSKMDBA_GROUP is the OS group which is to be granted SYSKM privileges. 99 | #------------------------------------------------------------------------------ 100 | oracle.install.db.OSKMDBA_GROUP=dba 101 | 102 | #------------------------------------------------------------------------------ 103 | # The OSRACDBA_GROUP is the OS group which is to be granted SYSRAC privileges. 104 | #------------------------------------------------------------------------------ 105 | oracle.install.db.OSRACDBA_GROUP=dba 106 | 107 | ############################################################################### 108 | # # 109 | # Grid Options # 110 | # # 111 | ############################################################################### 112 | 113 | #------------------------------------------------------------------------------ 114 | # Value is required only if the specified install option is INSTALL_DB_SWONLY 115 | # 116 | # Specify the cluster node names selected during the installation. 117 | # 118 | # Example : oracle.install.db.CLUSTER_NODES=node1,node2 119 | #------------------------------------------------------------------------------ 120 | oracle.install.db.CLUSTER_NODES= 121 | 122 | ############################################################################### 123 | # # 124 | # Database Configuration Options # 125 | # # 126 | ############################################################################### 127 | 128 | #------------------------------------------------------------------------------- 129 | # Specify the type of database to create. 130 | # It can be one of the following: 131 | # - GENERAL_PURPOSE 132 | # - DATA_WAREHOUSE 133 | # GENERAL_PURPOSE: A starter database designed for general purpose use or transaction-heavy applications. 134 | # DATA_WAREHOUSE : A starter database optimized for data warehousing applications. 135 | #------------------------------------------------------------------------------- 136 | oracle.install.db.config.starterdb.type= 137 | 138 | #------------------------------------------------------------------------------- 139 | # Specify the Starter Database Global Database Name. 140 | #------------------------------------------------------------------------------- 141 | oracle.install.db.config.starterdb.globalDBName= 142 | 143 | #------------------------------------------------------------------------------- 144 | # Specify the Starter Database SID. 145 | #------------------------------------------------------------------------------- 146 | oracle.install.db.config.starterdb.SID= 147 | 148 | #------------------------------------------------------------------------------- 149 | # Specify whether the database should be configured as a Container database. 150 | # The value can be either "true" or "false". If left blank it will be assumed 151 | # to be "false". 152 | #------------------------------------------------------------------------------- 153 | oracle.install.db.ConfigureAsContainerDB= 154 | 155 | #------------------------------------------------------------------------------- 156 | # Specify the Pluggable Database name for the pluggable database in Container Database. 157 | #------------------------------------------------------------------------------- 158 | oracle.install.db.config.PDBName= 159 | 160 | #------------------------------------------------------------------------------- 161 | # Specify the Starter Database character set. 162 | # 163 | # One of the following 164 | # AL32UTF8, WE8ISO8859P15, WE8MSWIN1252, EE8ISO8859P2, 165 | # EE8MSWIN1250, NE8ISO8859P10, NEE8ISO8859P4, BLT8MSWIN1257, 166 | # BLT8ISO8859P13, CL8ISO8859P5, CL8MSWIN1251, AR8ISO8859P6, 167 | # AR8MSWIN1256, EL8ISO8859P7, EL8MSWIN1253, IW8ISO8859P8, 168 | # IW8MSWIN1255, JA16EUC, JA16EUCTILDE, JA16SJIS, JA16SJISTILDE, 169 | # KO16MSWIN949, ZHS16GBK, TH8TISASCII, ZHT32EUC, ZHT16MSWIN950, 170 | # ZHT16HKSCS, WE8ISO8859P9, TR8MSWIN1254, VN8MSWIN1258 171 | #------------------------------------------------------------------------------- 172 | oracle.install.db.config.starterdb.characterSet= 173 | 174 | #------------------------------------------------------------------------------ 175 | # This variable should be set to true if Automatic Memory Management 176 | # in Database is desired. 177 | # If Automatic Memory Management is not desired, and memory allocation 178 | # is to be done manually, then set it to false. 179 | #------------------------------------------------------------------------------ 180 | oracle.install.db.config.starterdb.memoryOption= 181 | 182 | #------------------------------------------------------------------------------- 183 | # Specify the total memory allocation for the database. Value(in MB) should be 184 | # at least 256 MB, and should not exceed the total physical memory available 185 | # on the system. 186 | # Example: oracle.install.db.config.starterdb.memoryLimit=512 187 | #------------------------------------------------------------------------------- 188 | oracle.install.db.config.starterdb.memoryLimit= 189 | 190 | #------------------------------------------------------------------------------- 191 | # This variable controls whether to load Example Schemas onto 192 | # the starter database or not. 193 | # The value can be either "true" or "false". If left blank it will be assumed 194 | # to be "false". 195 | #------------------------------------------------------------------------------- 196 | oracle.install.db.config.starterdb.installExampleSchemas= 197 | 198 | ############################################################################### 199 | # # 200 | # Passwords can be supplied for the following four schemas in the # 201 | # starter database: # 202 | # SYS # 203 | # SYSTEM # 204 | # DBSNMP (used by Enterprise Manager) # 205 | # # 206 | # Same password can be used for all accounts (not recommended) # 207 | # or different passwords for each account can be provided (recommended) # 208 | # # 209 | ############################################################################### 210 | 211 | #------------------------------------------------------------------------------ 212 | # This variable holds the password that is to be used for all schemas in the 213 | # starter database. 214 | #------------------------------------------------------------------------------- 215 | oracle.install.db.config.starterdb.password.ALL= 216 | 217 | #------------------------------------------------------------------------------- 218 | # Specify the SYS password for the starter database. 219 | #------------------------------------------------------------------------------- 220 | oracle.install.db.config.starterdb.password.SYS= 221 | 222 | #------------------------------------------------------------------------------- 223 | # Specify the SYSTEM password for the starter database. 224 | #------------------------------------------------------------------------------- 225 | oracle.install.db.config.starterdb.password.SYSTEM= 226 | 227 | #------------------------------------------------------------------------------- 228 | # Specify the DBSNMP password for the starter database. 229 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 230 | #------------------------------------------------------------------------------- 231 | oracle.install.db.config.starterdb.password.DBSNMP= 232 | 233 | #------------------------------------------------------------------------------- 234 | # Specify the PDBADMIN password required for creation of Pluggable Database in the Container Database. 235 | #------------------------------------------------------------------------------- 236 | oracle.install.db.config.starterdb.password.PDBADMIN= 237 | 238 | #------------------------------------------------------------------------------- 239 | # Specify the management option to use for managing the database. 240 | # Options are: 241 | # 1. CLOUD_CONTROL - If you want to manage your database with Enterprise Manager Cloud Control along with Database Express. 242 | # 2. DEFAULT -If you want to manage your database using the default Database Express option. 243 | #------------------------------------------------------------------------------- 244 | oracle.install.db.config.starterdb.managementOption= 245 | 246 | #------------------------------------------------------------------------------- 247 | # Specify the OMS host to connect to Cloud Control. 248 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 249 | #------------------------------------------------------------------------------- 250 | oracle.install.db.config.starterdb.omsHost= 251 | 252 | #------------------------------------------------------------------------------- 253 | # Specify the OMS port to connect to Cloud Control. 254 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 255 | #------------------------------------------------------------------------------- 256 | oracle.install.db.config.starterdb.omsPort= 257 | 258 | #------------------------------------------------------------------------------- 259 | # Specify the EM Admin user name to use to connect to Cloud Control. 260 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 261 | #------------------------------------------------------------------------------- 262 | oracle.install.db.config.starterdb.emAdminUser= 263 | 264 | #------------------------------------------------------------------------------- 265 | # Specify the EM Admin password to use to connect to Cloud Control. 266 | # Applicable only when oracle.install.db.config.starterdb.managementOption=CLOUD_CONTROL 267 | #------------------------------------------------------------------------------- 268 | oracle.install.db.config.starterdb.emAdminPassword= 269 | 270 | ############################################################################### 271 | # # 272 | # SPECIFY RECOVERY OPTIONS # 273 | # ------------------------------------ # 274 | # Recovery options for the database can be mentioned using the entries below # 275 | # # 276 | ############################################################################### 277 | 278 | #------------------------------------------------------------------------------ 279 | # This variable is to be set to false if database recovery is not required. Else 280 | # this can be set to true. 281 | #------------------------------------------------------------------------------- 282 | oracle.install.db.config.starterdb.enableRecovery= 283 | 284 | #------------------------------------------------------------------------------- 285 | # Specify the type of storage to use for the database. 286 | # It can be one of the following: 287 | # - FILE_SYSTEM_STORAGE 288 | # - ASM_STORAGE 289 | #------------------------------------------------------------------------------- 290 | oracle.install.db.config.starterdb.storageType= 291 | 292 | #------------------------------------------------------------------------------- 293 | # Specify the database file location which is a directory for datafiles, control 294 | # files, redo logs. 295 | # 296 | # Applicable only when oracle.install.db.config.starterdb.storage=FILE_SYSTEM_STORAGE 297 | #------------------------------------------------------------------------------- 298 | oracle.install.db.config.starterdb.fileSystemStorage.dataLocation= 299 | 300 | #------------------------------------------------------------------------------- 301 | # Specify the recovery location. 302 | # 303 | # Applicable only when oracle.install.db.config.starterdb.storage=FILE_SYSTEM_STORAGE 304 | #------------------------------------------------------------------------------- 305 | oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation= 306 | 307 | #------------------------------------------------------------------------------- 308 | # Specify the existing ASM disk groups to be used for storage. 309 | # 310 | # Applicable only when oracle.install.db.config.starterdb.storageType=ASM_STORAGE 311 | #------------------------------------------------------------------------------- 312 | oracle.install.db.config.asm.diskGroup= 313 | 314 | #------------------------------------------------------------------------------- 315 | # Specify the password for ASMSNMP user of the ASM instance. 316 | # 317 | # Applicable only when oracle.install.db.config.starterdb.storage=ASM_STORAGE 318 | #------------------------------------------------------------------------------- 319 | oracle.install.db.config.asm.ASMSNMPPassword= 320 | -------------------------------------------------------------------------------- /files/download_urls.txt: -------------------------------------------------------------------------------- 1 | # Tomcat 2 | https://www-eu.apache.org/dist/tomcat/tomcat-8/v8.5.60/bin/apache-tomcat-8.5.60.tar.gz 3 | 4 | # AdoptOpenJDK 11 (Linux x64 tar.gz) 5 | https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.9.1%2B1/OpenJDK11U-jdk_x64_linux_hotspot_11.0.9.1_1.tar.gz 6 | 7 | # Oracle Database 12.2.0.1 EE 8 | https://download.oracle.com/otn/linux/oracle12c/122010/linuxx64_12201_database.zip 9 | 10 | # Oracle Database 18.3 EE 11 | https://download.oracle.com/otn/linux/oracle18c/180000/LINUX.X64_180000_db_home.zip 12 | 13 | # Oracle Database 19.3 EE 14 | https://download.oracle.com/otn/linux/oracle19c/190000/LINUX.X64_193000_db_home.zip 15 | 16 | # Oracle APEX 17 | https://download.oracle.com/otn/java/appexpress/apex_20.2.zip 18 | 19 | # Oracle ORDS 20 | https://download.oracle.com/otn/java/ords/ords-20.3.0.301.1819.zip 21 | 22 | # Oracle SQLcl 23 | https://download.oracle.com/otn/java/sqldeveloper/sqlcl-20.3.0.274.1916.zip 24 | 25 | # Swagger-UI 26 | https://github.com/swagger-api/swagger-ui/archive/v3.35.2.zip 27 | 28 | # GOSU (Docker SU Fix) 29 | https://github.com/tianon/gosu/releases/download/1.12/gosu-amd64 30 | 31 | # OraOpenSource Logger 32 | https://github.com/OraOpenSource/Logger/raw/master/releases/logger_3.1.1.zip 33 | 34 | # OraOpenSource OOS Utils 35 | https://observant-message.glitch.me/oos-utils/latest/oos-utils-latest.zip 36 | -------------------------------------------------------------------------------- /files/ords_params.properties: -------------------------------------------------------------------------------- 1 | #Wed Dec 20 10:30:00 CET 2017 2 | db.hostname=localhost 3 | db.password=#PASSWORD# 4 | db.port=1521 5 | db.sid=#ORACLE_SID# 6 | db.username=APEX_PUBLIC_USER 7 | migrate.apex.rest=false 8 | plsql.gateway.add=true 9 | rest.services.apex.add=true 10 | rest.services.ords.add=true 11 | schema.tablespace.default=APEX 12 | schema.tablespace.temp=TEMP 13 | standalone.http.port=8080 14 | standalone.mode=false 15 | user.apex.listener.password=#PASSWORD# 16 | user.apex.restpublic.password=#PASSWORD# 17 | user.public.password=#PASSWORD# 18 | user.tablespace.default=USERS 19 | user.tablespace.temp=TEMP 20 | sys.user=SYS 21 | sys.password=#PASSWORD# 22 | feature.sdw=false 23 | restEnabledSql.active=false 24 | database.api.enabled=false -------------------------------------------------------------------------------- /files/tomcat-users.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /files/tomcat.service: -------------------------------------------------------------------------------- 1 | # Systemd unit file for tomcat 2 | [Unit] 3 | Description=Apache Tomcat Web Application Container 4 | After=syslog.target network.target 5 | 6 | [Service] 7 | Type=forking 8 | 9 | Environment=JAVA_HOME=#JAVA_HOME# 10 | Environment=CATALINA_PID=#TOMCAT_HOME#/temp/tomcat.pid 11 | Environment=CATALINA_HOME=#TOMCAT_HOME# 12 | Environment=CATALINA_BASE=#TOMCAT_HOME# 13 | Environment='CATALINA_OPTS=-Xms256M -Xmx512M -server -XX:+UseParallelGC' 14 | Environment='JAVA_OPTS=-Djava.awt.headless=true -Djava.security.egd=file:/dev/./urandom' 15 | 16 | ExecStart=#TOMCAT_HOME#/bin/startup.sh 17 | ExecStop=/bin/kill -15 $MAINPID 18 | 19 | User=tomcat 20 | Group=tomcat 21 | UMask=0007 22 | RestartSec=10 23 | Restart=always 24 | 25 | [Install] 26 | WantedBy=multi-user.target -------------------------------------------------------------------------------- /scripts/create_ca_wallet.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | 4 | # Info 5 | # https://raw.githubusercontent.com/bnoordhuis/mozilla-central/master/toolkit/crashreporter/client/certdata2pem.py 6 | # https://raw.githubusercontent.com/alpinelinux/ca-certificates/master/certdata2pem.py 7 | # https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/ 8 | # https://hg.mozilla.org/mozilla-central/raw-file/tip/security/nss/lib/ckfw/builtins/certdata.txt 9 | 10 | # Usage: 11 | # . create_ca_wallet.sh 12 | 13 | # Set env vars 14 | set_env() { 15 | export WORKING_DIR=$(pwd) 16 | export OUTPUT_TMP_DIR=$WORKING_DIR/output 17 | export WALLET_DIR=$WORKING_DIR/wallet 18 | } 19 | 20 | # Create needed folders 21 | create_folders() { 22 | mkdir $OUTPUT_TMP_DIR 23 | if [ ! -d $WALLET_DIR ]; then 24 | mkdir $WALLET_DIR 25 | fi 26 | } 27 | 28 | # Get mozilla resources & scripts 29 | fetch_scripts() { 30 | echo "" 31 | echo "**** Fetching script & certificates data from mozilla ****" 32 | curl -O https://raw.githubusercontent.com/alpinelinux/ca-certificates/3184fe80e403b9dc6d5fe3b7ebcd9d375363e2e4/certdata2pem.py 33 | curl -O https://hg.mozilla.org/mozilla-central/raw-file/tip/security/nss/lib/ckfw/builtins/certdata.txt 34 | curl -O https://git.launchpad.net/ubuntu/+source/ca-certificates/plain/mozilla/blacklist.txt 35 | chmod +x certdata2pem.py 36 | } 37 | 38 | # extract pem from data 39 | convert_certdata_pem() { 40 | echo "" 41 | echo "**** Extracting data from certdata.txt and creating certificates ****" 42 | python certdata2pem.py 43 | } 44 | 45 | # Create password file 46 | create_password_file() { 47 | if [ ! -f $WALLET_DIR/_pwd.txt ]; then 48 | echo "" 49 | echo "**** Creating Password File ****" 50 | echo "Location: ${WALLET_DIR}/_pwd.txt" 51 | openssl rand -base64 64 | tr -dc 'a-zA-Z0-9' | fold -w 40 | head -n 1 >$WALLET_DIR/_pwd.txt 52 | else 53 | echo "" 54 | echo "**** Password File already present ****" 55 | echo "Location: ${WALLET_DIR}/_pwd.txt" 56 | fi 57 | } 58 | 59 | # Create Oracle wallet 60 | create_oracle_wallet() { 61 | echo "" 62 | echo "**** Creating Oracle Wallet containing all CA certificates ****" 63 | if type "orapki" >/dev/null; then 64 | echo "" 65 | echo "> Creating Wallet with orapki" 66 | orapki wallet create -wallet $WALLET_DIR -pwd <(cat $WALLET_DIR/_pwd.txt) -auto_login 67 | echo "" 68 | echo "> Add each single CA certificate to Wallet" 69 | for file in $OUTPUT_TMP_DIR/*.crt; do 70 | orapki wallet add -wallet $WALLET_DIR -trusted_cert -cert $file -pwd <(cat $WALLET_DIR/_pwd.txt) 71 | done 72 | else 73 | echo "" 74 | echo "> Build single certificate file containing all CAs" 75 | for file in $OUTPUT_TMP_DIR/*.crt; do 76 | cat $file >>$WALLET_DIR/ca-certificates.crt 77 | done 78 | echo "" 79 | echo "> Creating Wallet with openssl" 80 | openssl pkcs12 -export -in $WALLET_DIR/ca-certificates.crt -out $WALLET_DIR/ewallet.p12 -nokeys -passout file:$WALLET_DIR/_pwd.txt 81 | fi 82 | } 83 | 84 | # Cleanup 85 | cleanup() { 86 | rm -fr $OUTPUT_TMP_DIR 87 | rm -f $WALLET_DIR/ca-certificates.crt 88 | } 89 | 90 | # End output 91 | end_output() { 92 | echo "" 93 | echo "**** Done ****" 94 | echo "Location: ${WALLET_DIR}" 95 | } 96 | 97 | # Execute functions 98 | set_env 99 | create_folders 100 | cd $OUTPUT_TMP_DIR 101 | fetch_scripts 102 | convert_certdata_pem 103 | cd $WORKING_DIR 104 | create_password_file 105 | create_oracle_wallet 106 | cleanup 107 | end_output 108 | -------------------------------------------------------------------------------- /scripts/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # set environment 4 | . /scripts/setenv.sh 5 | 6 | # add hostname 7 | echo "127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4" > /etc/hosts 8 | echo "::1 localhost localhost.localdomain localhost6 localhost6.localdomain6" >> /etc/hosts 9 | echo "127.0.0.1 $HOSTNAME" >> /etc/hosts 10 | 11 | # set timezone 12 | ln -s -f /usr/share/zoneinfo/${TIME_ZONE} /etc/localtime 13 | 14 | # start all components 15 | # ssh 16 | /usr/sbin/sshd 17 | # oracle 18 | if [ ${DB_INSTALL_VERSION} == "12" ]; then 19 | export ORACLE_HOME=${ORACLE_HOME12} 20 | fi 21 | if [ ${DB_INSTALL_VERSION} == "18" ]; then 22 | export ORACLE_HOME=${ORACLE_HOME18} 23 | fi 24 | if [ ${DB_INSTALL_VERSION} == "19" ]; then 25 | export ORACLE_HOME=${ORACLE_HOME19} 26 | fi 27 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl start" 28 | gosu oracle bash -c 'echo startup\; | ${ORACLE_HOME}/bin/sqlplus -s -l / as sysdba' 29 | # tomcat 30 | if [ ${INSTALL_APEX} == "true" ]; then 31 | gosu tomcat bash -c "${TOMCAT_HOME}/bin/startup.sh" 32 | fi 33 | 34 | # Infinite wait loop, trap interrupt/terminate signal for graceful termination 35 | trap "gosu oracle bash -c 'echo shutdown immediate\; | ${ORACLE_HOME}/bin/sqlplus -S / as sysdba'" INT TERM 36 | while true; do sleep 1; done 37 | ;; 38 | -------------------------------------------------------------------------------- /scripts/image_setup.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # add hostname 4 | echo "127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4" > /etc/hosts 5 | echo "::1 localhost localhost.localdomain localhost6 localhost6.localdomain6" >> /etc/hosts 6 | echo "127.0.0.1 $HOSTNAME" >> /etc/hosts 7 | 8 | # folder permissions 9 | chmod -R 777 /files 10 | chmod -R 777 /scripts 11 | 12 | # set timezone 13 | ln -s -f /usr/share/zoneinfo/${TIME_ZONE} /etc/localtime 14 | 15 | # disable SELinux 16 | setenforce disabled 17 | if [ -f /etc/selinux/config ]; then 18 | sed -i -E 's:SELINUX=enforcing:SELINUX=disabled:g' /etc/selinux/config 19 | fi 20 | 21 | # update YUM 22 | yum clean all 23 | yum update -y 24 | yum install -y openssl 25 | -------------------------------------------------------------------------------- /scripts/install_ame.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | ame_create_user(){ 4 | echo "Creating AME User." 5 | 6 | echo 'create user AME identified by "'${PASS}'" default tablespace USERS temporary tablespace TEMP' > create_user_custom.sql 7 | echo "/" >> create_user_custom.sql 8 | echo "alter user AME quota unlimited on USERS" >> create_user_custom.sql 9 | echo "/" >> create_user_custom.sql 10 | echo "grant connect, create cluster, create dimension, create indextype, create job, create materialized view, create operator, create procedure, create sequence, create session, create synonym, create table, create trigger, create type, create view to AME;" >> create_user_custom.sql 11 | echo "/" >> create_user_custom.sql 12 | 13 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_user_custom 14 | } 15 | 16 | ame_create_workspace(){ 17 | echo "Creating AME APEX Workspace" 18 | 19 | echo 'DECLARE' > create_workspace.sql 20 | echo 'l_workspace_id NUMBER;' >> create_workspace.sql 21 | echo 'BEGIN' >> create_workspace.sql 22 | echo "APEX_INSTANCE_ADMIN.ADD_WORKSPACE (p_workspace => 'AME', p_primary_schema => 'AME');" >> create_workspace.sql 23 | echo "COMMIT;" >> create_workspace.sql 24 | echo "SELECT workspace_id INTO l_workspace_id FROM apex_workspaces WHERE workspace = 'AME';" >> create_workspace.sql 25 | echo "wwv_flow_api.set_security_group_id(p_security_group_id => l_workspace_id);" >> create_workspace.sql 26 | echo "apex_util.create_user(p_user_name => 'ADMIN', p_web_password => '"${APEX_PASS}"', p_email_address => 'admin@docker.local', p_change_password_on_first_use => 'N', p_developer_privs => 'ADMIN:CREATE:DATA_LOADER:EDIT:HELP:MONITOR:SQL', p_default_schema => 'AME', p_allow_app_building_yn => 'Y', p_allow_sql_workshop_yn => 'Y', p_allow_websheet_dev_yn => 'Y', p_allow_team_development_yn => 'Y');" >> create_workspace.sql 27 | echo "END;" >> create_workspace.sql 28 | echo "/" >> create_workspace.sql 29 | 30 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_workspace 31 | } 32 | 33 | ame_install_db(){ 34 | echo "Installing AME" 35 | 36 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l ame/${PASS} @install 37 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l ame/${PASS} @ame_db_sample_obj 38 | } 39 | 40 | ame_install_apex(){ 41 | echo "Creating AME APEX Application" 42 | 43 | APEX_SCHEMA=`sqlplus -s -l sys/${PASS} AS SYSDBA < install_ame_app.sql 50 | echo "apex_application_install.set_workspace('AME');" >> install_ame_app.sql 51 | echo "apex_application_install.generate_offset;" >> install_ame_app.sql 52 | echo "apex_application_install.set_schema('AME');" >> install_ame_app.sql 53 | echo "apex_application_install.set_application_id(160);" >> install_ame_app.sql 54 | echo "end;" >> install_ame_app.sql 55 | echo "/" >> install_ame_app.sql 56 | if [ "$APEX_SCHEMA" = "APEX_180100" ]; then 57 | echo "Install AME Sample App for APEX 18.1" 58 | echo "@@ame_sample_apex_app.sql" >> install_ame_app.sql 59 | elif [ "$APEX_SCHEMA" = "APEX_180200" ]; then 60 | echo "Install AME Sample App for APEX 18.2" 61 | echo "@@ame_sample_apex_app.sql" >> install_ame_app.sql 62 | elif [ "$APEX_SCHEMA" = "APEX_190100" ]; then 63 | echo "Install AME Sample App for APEX 19.1" 64 | echo "@@ame_sample_apex_app.sql" >> install_ame_app.sql 65 | elif [ "$APEX_SCHEMA" = "APEX_190200" ]; then 66 | echo "Install AME Sample App for APEX 19.2" 67 | echo "@@ame_sample_apex_app.sql" >> install_ame_app.sql 68 | elif [ "$APEX_SCHEMA" = "APEX_200100" ]; then 69 | echo "Install AME Sample App for APEX 20.1" 70 | echo "@@ame_sample_apex_app.sql" >> install_ame_app.sql 71 | elif [ "$APEX_SCHEMA" = "APEX_200200" ]; then 72 | echo "Install AME Sample App for APEX 20.2" 73 | echo "@@ame_sample_apex_app.sql" >> install_ame_app.sql 74 | fi 75 | 76 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l ame/${PASS} @install_ame_app 77 | } 78 | 79 | 80 | ame_public_grants(){ 81 | echo "Creating AME Public Grants." 82 | 83 | echo "grant execute on ame.ame_api20_pkg to PUBLIC;" > create_ame_public_grants.sql 84 | 85 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l ame/${PASS} @create_ame_public_grants 86 | } 87 | 88 | ame_public_synonyms(){ 89 | echo "Creating AME Public Synonyms." 90 | 91 | echo "create or replace public synonym ame_api20_pkg for ame.ame_api20_pkg;" > create_ame_public_synonyms.sql 92 | echo "create or replace public synonym ame_api_pkg for ame.ame_api20_pkg;" >> create_ame_public_synonyms.sql 93 | 94 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_ame_public_synonyms 95 | } 96 | 97 | ame_unzip(){ 98 | echo "Extracting AME" 99 | mkdir /files/ame 100 | unzip /files/ame_cloud_v*.zip -d /files/ame/ 101 | } 102 | 103 | echo "Installing AME into DB: ${ORACLE_SID}" 104 | 105 | . /home/oracle/.bash_profile 106 | ame_unzip 107 | 108 | cd /files/ame/v*/db 109 | ame_create_user 110 | ame_create_workspace 111 | ame_install_db 112 | ame_public_grants 113 | ame_public_synonyms 114 | 115 | cd /files/ame/v*/apex 116 | ame_install_apex 117 | 118 | cd / 119 | -------------------------------------------------------------------------------- /scripts/install_aop.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | aop_create_user(){ 4 | echo "Creating AOP User." 5 | 6 | echo 'create user AOP identified by "'${PASS}'" default tablespace USERS temporary tablespace TEMP' > create_user_custom.sql 7 | echo "/" >> create_user_custom.sql 8 | echo "alter user AOP quota unlimited on USERS" >> create_user_custom.sql 9 | echo "/" >> create_user_custom.sql 10 | echo "grant connect, create cluster, create dimension, create indextype, create job, create materialized view, create operator, create procedure, create sequence, create session, create synonym, create table, create trigger, create type, create view to AOP;" >> create_user_custom.sql 11 | echo "/" >> create_user_custom.sql 12 | 13 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_user_custom 14 | } 15 | 16 | aop_create_workspace(){ 17 | echo "Creating AOP APEX Workspace" 18 | 19 | echo 'DECLARE' > create_workspace.sql 20 | echo 'l_workspace_id NUMBER;' >> create_workspace.sql 21 | echo 'BEGIN' >> create_workspace.sql 22 | echo "APEX_INSTANCE_ADMIN.ADD_WORKSPACE (p_workspace => 'AOP', p_primary_schema => 'AOP');" >> create_workspace.sql 23 | echo "COMMIT;" >> create_workspace.sql 24 | echo "SELECT workspace_id INTO l_workspace_id FROM apex_workspaces WHERE workspace = 'AOP';" >> create_workspace.sql 25 | echo "wwv_flow_api.set_security_group_id(p_security_group_id => l_workspace_id);" >> create_workspace.sql 26 | echo "apex_util.create_user(p_user_name => 'ADMIN', p_web_password => '"${APEX_PASS}"', p_email_address => 'admin@docker.local', p_change_password_on_first_use => 'N', p_developer_privs => 'ADMIN:CREATE:DATA_LOADER:EDIT:HELP:MONITOR:SQL', p_default_schema => 'AOP', p_allow_app_building_yn => 'Y', p_allow_sql_workshop_yn => 'Y', p_allow_websheet_dev_yn => 'Y', p_allow_team_development_yn => 'Y');" >> create_workspace.sql 27 | echo "END;" >> create_workspace.sql 28 | echo "/" >> create_workspace.sql 29 | 30 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_workspace 31 | } 32 | 33 | aop_install_db(){ 34 | echo "Installing AOP" 35 | 36 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l aop/${PASS} @install 37 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l aop/${PASS} @aop_db_sample_obj 38 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l aop/${PASS} @aop_db_sample_pkg 39 | } 40 | 41 | aop_install_apex(){ 42 | echo "Creating AOP APEX Application" 43 | 44 | APEX_SCHEMA=`sqlplus -s -l sys/${PASS} AS SYSDBA < install_aop_app.sql 51 | echo "apex_application_install.set_workspace('AOP');" >> install_aop_app.sql 52 | echo "apex_application_install.generate_offset;" >> install_aop_app.sql 53 | echo "apex_application_install.set_schema('AOP');" >> install_aop_app.sql 54 | echo "apex_application_install.set_application_id(150);" >> install_aop_app.sql 55 | echo "end;" >> install_aop_app.sql 56 | echo "/" >> install_aop_app.sql 57 | if [ "$APEX_SCHEMA" = "APEX_050000" ]; then 58 | echo "Install AOP Sample App for APEX 5.0.x" 59 | echo "@@apex_version_5.0/aop_sample_apex_app.sql" >> install_aop_app.sql 60 | elif [ "$APEX_SCHEMA" = "APEX_050100" ]; then 61 | echo "Install AOP Sample App for APEX 5.1.x" 62 | echo "@@apex_version_5.1/aop_sample_apex_app.sql" >> install_aop_app.sql 63 | elif [ "$APEX_SCHEMA" = "APEX_180100" ]; then 64 | echo "Install AOP Sample App for APEX 18.x - 19.1" 65 | echo "@@apex_version_18.x_19.1/aop_sample_apex_app.sql" >> install_aop_app.sql 66 | elif [ "$APEX_SCHEMA" = "APEX_180200" ]; then 67 | echo "Install AOP Sample App for APEX 18.x - 19.1" 68 | echo "@@apex_version_18.x_19.1/aop_sample_apex_app.sql" >> install_aop_app.sql 69 | elif [ "$APEX_SCHEMA" = "APEX_190100" ]; then 70 | echo "Install AOP Sample App for APEX 18.x - 19.1" 71 | echo "@@apex_version_18.x_19.1/aop_sample_apex_app.sql" >> install_aop_app.sql 72 | elif [ "$APEX_SCHEMA" = "APEX_190200" ]; then 73 | echo "Install AOP Sample App for APEX 19.2" 74 | echo "@@apex_version_19.2/aop_sample_apex_app.sql" >> install_aop_app.sql 75 | elif [ "$APEX_SCHEMA" = "APEX_200100" ]; then 76 | echo "Install AOP Sample App for APEX 20.1" 77 | echo "@@apex_version_20.x/aop_sample_apex_app.sql" >> install_aop_app.sql 78 | elif [ "$APEX_SCHEMA" = "APEX_200200" ]; then 79 | echo "Install AOP Sample App for APEX 20.2" 80 | echo "@@apex_version_20.x/aop_sample_apex_app.sql" >> install_aop_app.sql 81 | fi 82 | 83 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l aop/${PASS} @install_aop_app 84 | } 85 | 86 | 87 | aop_public_grants(){ 88 | echo "Creating AOP Public Grants." 89 | 90 | echo "grant execute on aop.aop_api20_pkg to PUBLIC;" > create_aop_public_grants.sql 91 | echo "grant execute on aop.aop_convert20_pkg to PUBLIC;" >> create_aop_public_grants.sql 92 | echo "grant execute on aop.aop_plsql20_pkg to PUBLIC;" >> create_aop_public_grants.sql 93 | echo "grant execute on aop.aop_settings20_pkg to PUBLIC;" >> create_aop_public_grants.sql 94 | 95 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l aop/${PASS} @create_aop_public_grants 96 | } 97 | 98 | aop_public_synonyms(){ 99 | echo "Creating AOP Public Synonyms." 100 | 101 | echo "create or replace public synonym aop_api20_pkg for aop.aop_api20_pkg;" > create_aop_public_synonyms.sql 102 | echo "create or replace public synonym aop_convert20_pkg for aop.aop_convert20_pkg;" >> create_aop_public_synonyms.sql 103 | echo "create or replace public synonym aop_plsql20_pkg for aop.aop_plsql20_pkg;" >> create_aop_public_synonyms.sql 104 | echo "create or replace public synonym aop_settings20_pkg for aop.aop_settings20_pkg;" >> create_aop_public_synonyms.sql 105 | 106 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_aop_public_synonyms 107 | } 108 | 109 | aop_unzip(){ 110 | echo "Extracting AOP" 111 | mkdir /files/aop 112 | unzip /files/aop_cloud_v*.zip -d /files/aop/ 113 | } 114 | 115 | echo "Installing AOP into DB: ${ORACLE_SID}" 116 | 117 | . /home/oracle/.bash_profile 118 | aop_unzip 119 | 120 | cd /files/aop/v*/db 121 | aop_create_user 122 | aop_create_workspace 123 | aop_install_db 124 | aop_public_grants 125 | aop_public_synonyms 126 | 127 | cd /files/aop/v*/apex 128 | aop_install_apex 129 | 130 | cd / 131 | -------------------------------------------------------------------------------- /scripts/install_apex.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | disable_http(){ 4 | echo "Turning off DBMS_XDB HTTP port" 5 | echo "EXEC DBMS_XDB.SETHTTPPORT(0);" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA 6 | } 7 | 8 | enable_http(){ 9 | echo "Turning on DBMS_XDB HTTP port" 10 | echo "EXEC DBMS_XDB.SETHTTPPORT(8080);" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA 11 | } 12 | 13 | apex_epg_config(){ 14 | cd ${ORACLE_HOME}/apex 15 | echo "Setting up EPG for APEX by running: @apex_epg_config ${ORACLE_HOME}" 16 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @apex_epg_config ${ORACLE_HOME} 17 | echo "Unlock anonymous account" 18 | echo "ALTER USER ANONYMOUS ACCOUNT UNLOCK;" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA 19 | echo "Optimizing EPG performance" 20 | echo "ALTER SYSTEM SET SHARED_SERVERS=15 SCOPE=BOTH;" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA 21 | echo -e "ALTER SYSTEM SET DISPATCHERS='(PROTOCOL=TCP) (SERVICE=${ORACLE_SID}XDB) (DISPATCHERS=3)' SCOPE=BOTH;" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA 22 | } 23 | 24 | apex_create_tablespace(){ 25 | cd ${ORACLE_HOME}/apex 26 | echo "Creating APEX tablespace." 27 | 28 | if [ ${DB_INSTALL_VERSION} == "12" ]; then 29 | DATAFILE_SID=${ORACLE_SID} 30 | fi 31 | if [ ${DB_INSTALL_VERSION} == "18" ]; then 32 | DATAFILE_SID=${ORACLE_SID^^} 33 | fi 34 | if [ ${DB_INSTALL_VERSION} == "19" ]; then 35 | DATAFILE_SID=${ORACLE_SID^^} 36 | fi 37 | 38 | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA < apxchpwd_custom.sql 60 | echo " wwv_flow_security.g_security_group_id := 10;" >> apxchpwd_custom.sql 61 | echo " wwv_flow_security.g_user := 'admin';" >> apxchpwd_custom.sql 62 | echo " wwv_flow_fnd_user_int.create_or_update_user( p_user_id => NULL," >> apxchpwd_custom.sql 63 | echo " p_username => 'admin'," >> apxchpwd_custom.sql 64 | echo " p_email => 'admin'," >> apxchpwd_custom.sql 65 | echo " p_password => '${APEX_PASS}' );" >> apxchpwd_custom.sql 66 | echo " commit;" >> apxchpwd_custom.sql 67 | echo "end;" >> apxchpwd_custom.sql 68 | echo "/" >> apxchpwd_custom.sql 69 | 70 | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA < create_allow_all_acl.sql 112 | echo " BEGIN" >> create_allow_all_acl.sql 113 | echo " dbms_network_acl_admin.drop_acl(acl => 'all-network-PUBLIC.xml');" >> create_allow_all_acl.sql 114 | echo " EXCEPTION" >> create_allow_all_acl.sql 115 | echo " WHEN OTHERS THEN" >> create_allow_all_acl.sql 116 | echo " NULL;" >> create_allow_all_acl.sql 117 | echo " END;" >> create_allow_all_acl.sql 118 | echo " dbms_network_acl_admin.create_acl(acl => 'all-network-PUBLIC.xml'," >> create_allow_all_acl.sql 119 | echo " description => 'Allow all network traffic'," >> create_allow_all_acl.sql 120 | echo " principal => 'PUBLIC'," >> create_allow_all_acl.sql 121 | echo " is_grant => TRUE," >> create_allow_all_acl.sql 122 | echo " privilege => 'connect');" >> create_allow_all_acl.sql 123 | echo " dbms_network_acl_admin.add_privilege(acl => 'all-network-PUBLIC.xml'," >> create_allow_all_acl.sql 124 | echo " principal => 'PUBLIC'," >> create_allow_all_acl.sql 125 | echo " is_grant => TRUE," >> create_allow_all_acl.sql 126 | echo " privilege => 'resolve');" >> create_allow_all_acl.sql 127 | echo " dbms_network_acl_admin.assign_acl(acl => 'all-network-PUBLIC.xml'," >> create_allow_all_acl.sql 128 | echo " host => '*');" >> create_allow_all_acl.sql 129 | echo "END;" >> create_allow_all_acl.sql 130 | echo "/" >> create_allow_all_acl.sql 131 | echo "sho err" >> create_allow_all_acl.sql 132 | echo "COMMIT;" >> create_allow_all_acl.sql 133 | echo "/" >> create_allow_all_acl.sql 134 | 135 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_allow_all_acl.sql 136 | } 137 | 138 | unzip_apex(){ 139 | echo "Extracting APEX" 140 | rm -rf ${ORACLE_HOME}/apex 141 | unzip /files/apex*.zip -d ${ORACLE_HOME}/ 142 | } 143 | 144 | install_apex_patch(){ 145 | echo "Installing APEX Patch Set Bundle" 146 | mkdir /files/apexpatch 147 | unzip /files/${APEX_PATCH_SET_BUNDLE_FILE} -d /files/apexpatch/ 148 | cd /files/apexpatch/* 149 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @catpatch.sql 150 | } 151 | 152 | echo "Installing APEX in DB: ${ORACLE_SID}" 153 | . /home/oracle/.bash_profile 154 | unzip_apex 155 | disable_http 156 | apex_create_tablespace 157 | apex_install 158 | apex_change_admin_pwd 159 | apex_rest_config 160 | apex_allow_all_acl 161 | if [ ! -z "${APEX_ADDITIONAL_LANG}" ]; then 162 | apex_install_lang 163 | fi 164 | if [ ! -z "${APEX_PATCH_SET_BUNDLE_FILE}" ]; then 165 | install_apex_patch 166 | fi 167 | cd / 168 | -------------------------------------------------------------------------------- /scripts/install_ca_wallet.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | create_wallet() { 4 | . create_ca_wallet.sh 5 | } 6 | 7 | move_wallet() { 8 | mv wallet /home/oracle 9 | chown -R oracle:oinstall /home/oracle/wallet 10 | } 11 | 12 | set_apex_wallet_and_pwd() { 13 | . /home/oracle/.bash_profile 14 | 15 | echo "Set APEX Instance SSL Wallet" 16 | WALLET_PWD=$(cat /home/oracle/wallet/_pwd.txt) 17 | 18 | echo "begin" >set_apex_wallet.sql 19 | echo " apex_instance_admin.set_parameter('WALLET_PATH','file:/home/oracle/wallet');" >>set_apex_wallet.sql 20 | echo " apex_instance_admin.set_parameter('WALLET_PWD','${WALLET_PWD}');" >>set_apex_wallet.sql 21 | echo " commit;" >>set_apex_wallet.sql 22 | echo "end;" >>set_apex_wallet.sql 23 | echo "/" >>set_apex_wallet.sql 24 | 25 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @set_apex_wallet 26 | } 27 | 28 | cd /scripts 29 | create_wallet 30 | move_wallet 31 | cd /files 32 | set_apex_wallet_and_pwd 33 | -------------------------------------------------------------------------------- /scripts/install_java.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | cd /files 3 | 4 | tar -xzf OpenJDK11U-jdk_*.tar.gz 5 | mv jdk-* ${JAVA_HOME} 6 | 7 | echo 'JAVA_HOME='${JAVA_HOME} >> /etc/profile 8 | echo 'PATH=$PATH:$HOME/bin:$JAVA_HOME/bin' >> /etc/profile 9 | echo 'export JAVA_HOME' >> /etc/profile 10 | echo 'export PATH' >> /etc/profile 11 | source /etc/profile 12 | 13 | echo "export JAVA_HOME=${JAVA_HOME}" >> /home/oracle/.bash_profile 14 | echo "export JAVA_HOME=${JAVA_HOME}" >> /home/oracle/.bashrc # .bash_profile not executed by docker 15 | echo "export JAVA_HOME=${JAVA_HOME}" >> /root/.bash_profile 16 | echo "export JAVA_HOME=${JAVA_HOME}" >> /root/.bashrc # .bash_profile not executed by docker 17 | echo "export PATH=\$JAVA_HOME/bin:\$PATH" >> /home/oracle/.bash_profile 18 | echo "export PATH=\$JAVA_HOME/bin:\$PATH" >> /home/oracle/.bashrc # .bash_profile not executed by docker 19 | echo "export PATH=\$JAVA_HOME/bin:\$PATH" >> /root/.bash_profile 20 | echo "export PATH=\$JAVA_HOME/bin:\$PATH" >> /root/.bashrc # .bash_profile not executed by docker 21 | -------------------------------------------------------------------------------- /scripts/install_logger.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | logger_create_tablespace(){ 4 | echo "Creating Logger Tablespace." 5 | 6 | if [ ${DB_INSTALL_VERSION} == "12" ]; then 7 | DATAFILE_SID=${ORACLE_SID} 8 | fi 9 | if [ ${DB_INSTALL_VERSION} == "18" ]; then 10 | DATAFILE_SID=${ORACLE_SID^^} 11 | fi 12 | if [ ${DB_INSTALL_VERSION} == "19" ]; then 13 | DATAFILE_SID=${ORACLE_SID^^} 14 | fi 15 | 16 | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA < create_user_custom.sql 25 | echo "/" >> create_user_custom.sql 26 | echo "alter user LOGGER_USER quota unlimited on LOGGER_TS" >> create_user_custom.sql 27 | echo "/" >> create_user_custom.sql 28 | echo "grant connect,create view, create job, create table, create sequence, create trigger, create procedure, create any context to LOGGER_USER" >> create_user_custom.sql 29 | echo "/" >> create_user_custom.sql 30 | 31 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_user_custom 32 | } 33 | 34 | logger_install(){ 35 | echo "Installing Logger." 36 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l logger_user/${PASS} @logger_install 37 | } 38 | 39 | logger_disable_admin_privs(){ 40 | echo "UPDATE logger_prefs SET logger_prefs.pref_value = 'FALSE' WHERE logger_prefs.pref_name = 'PROTECT_ADMIN_PROCS';" > disable_logger_admin_privs.sql 41 | echo "COMMIT;" >> disable_logger_admin_privs.sql 42 | echo "/" >> disable_logger_admin_privs.sql 43 | 44 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l logger_user/${PASS} @disable_logger_admin_privs 45 | } 46 | 47 | logger_public_grants(){ 48 | echo "Creating Logger Public Grants." 49 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l logger_user/${PASS} @grant_logger_to_user PUBLIC 50 | } 51 | 52 | logger_public_synonyms(){ 53 | echo "Creating Logger Public Synonyms." 54 | 55 | echo "create or replace public synonym logger for logger_user.logger;" > create_logger_public_synonyms.sql 56 | echo "create or replace public synonym logger_logs for logger_user.logger_logs;" >> create_logger_public_synonyms.sql 57 | echo "create or replace public synonym logger_logs_apex_items for logger_user.logger_logs_apex_items;" >> create_logger_public_synonyms.sql 58 | echo "create or replace public synonym logger_prefs for logger_user.logger_prefs;" >> create_logger_public_synonyms.sql 59 | echo "create or replace public synonym logger_prefs_by_client_id for logger_user.logger_prefs_by_client_id;" >> create_logger_public_synonyms.sql 60 | echo "create or replace public synonym logger_logs_5_min for logger_user.logger_logs_5_min;" >> create_logger_public_synonyms.sql 61 | echo "create or replace public synonym logger_logs_60_min for logger_user.logger_logs_60_min;" >> create_logger_public_synonyms.sql 62 | echo "create or replace public synonym logger_logs_terse for logger_user.logger_logs_terse;" >> create_logger_public_synonyms.sql 63 | 64 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_logger_public_synonyms 65 | } 66 | 67 | unzip_logger(){ 68 | echo "Extracting Logger" 69 | mkdir /files/logger 70 | unzip /files/logger_*.zip -d /files/logger/ 71 | } 72 | 73 | echo "Installing Logger into DB: ${ORACLE_SID}" 74 | . /home/oracle/.bash_profile 75 | unzip_logger 76 | cd /files/logger 77 | logger_create_tablespace 78 | logger_create_user 79 | logger_install 80 | logger_disable_admin_privs 81 | cd scripts 82 | logger_public_grants 83 | logger_public_synonyms 84 | cd / 85 | -------------------------------------------------------------------------------- /scripts/install_main.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | echo "--------------------------------------------------" 4 | echo "Environment Vars.................................." 5 | echo "INSTALL_APEX: ${INSTALL_APEX}" 6 | echo "INSTALL_SQLCL: ${INSTALL_SQLCL}" 7 | echo "INSTALL_SQLDEVWEB: ${INSTALL_SQLDEVWEB}" 8 | echo "INSTALL_LOGGER: ${INSTALL_LOGGER}" 9 | echo "INSTALL_OOSUTILS: ${INSTALL_OOSUTILS}" 10 | echo "INSTALL_AOP: ${INSTALL_AOP}" 11 | echo "INSTALL_AME: ${INSTALL_AME}" 12 | echo "INSTALL_SWAGGER: ${INSTALL_SWAGGER}" 13 | echo "INSTALL_CA_CERTS_WALLET: ${INSTALL_CA_CERTS_WALLET}" 14 | echo "DB_INSTALL_VERSION: ${DB_INSTALL_VERSION}" 15 | echo "DBCA_TOTAL_MEMORY: ${DBCA_TOTAL_MEMORY}" 16 | echo "ORACLE_SID: ${ORACLE_SID}" 17 | echo "SERVICE_NAME: ${SERVICE_NAME}" 18 | echo "ORACLE_BASE: ${ORACLE_BASE}" 19 | echo "ORACLE_HOME12: ${ORACLE_HOME12}" 20 | echo "ORACLE_HOME18: ${ORACLE_HOME18}" 21 | echo "ORACLE_HOME19: ${ORACLE_HOME19}" 22 | if [ ${DB_INSTALL_VERSION} == "12" ]; then 23 | export ORACLE_HOME=${ORACLE_HOME12} 24 | fi 25 | if [ ${DB_INSTALL_VERSION} == "18" ]; then 26 | export ORACLE_HOME=${ORACLE_HOME18} 27 | fi 28 | if [ ${DB_INSTALL_VERSION} == "19" ]; then 29 | export ORACLE_HOME=${ORACLE_HOME19} 30 | fi 31 | echo "ORACLE_HOME: ${ORACLE_HOME}" 32 | echo "ORACLE_INVENTORY: ${ORACLE_INVENTORY}" 33 | echo "PASS: ${PASS}" 34 | echo "ORDS_HOME: ${ORDS_HOME}" 35 | echo "JAVA_HOME: ${JAVA_HOME}" 36 | echo "TOMCAT_HOME: ${TOMCAT_HOME}" 37 | echo "APEX_PASS: ${APEX_PASS}" 38 | echo "APEX_ADDITIONAL_LANG: ${APEX_ADDITIONAL_LANG}" 39 | echo "APEX_PATCH_SET_BUNDLE_FILE: ${APEX_PATCH_SET_BUNDLE_FILE}" 40 | echo "TIME_ZONE: ${TIME_ZONE}" 41 | # 42 | # 43 | echo "--------------------------------------------------" 44 | echo "Validations......................................." 45 | ./scripts/validations.sh || exit 1 46 | # 47 | echo "--------------------------------------------------" 48 | echo "Image Setup......................................." 49 | ./scripts/image_setup.sh 50 | # 51 | echo "--------------------------------------------------" 52 | if [ ${DB_INSTALL_VERSION} == "12" ]; then 53 | echo "Installing ORACLE Database 12 EE......................" 54 | ./scripts/install_oracle12ee.sh 55 | fi 56 | if [ ${DB_INSTALL_VERSION} == "18" ]; then 57 | echo "Installing ORACLE Database 18 EE......................" 58 | ./scripts/install_oracle18ee.sh 59 | fi 60 | if [ ${DB_INSTALL_VERSION} == "19" ]; then 61 | echo "Installing ORACLE Database 19 EE......................" 62 | ./scripts/install_oracle19ee.sh 63 | fi 64 | # 65 | echo "--------------------------------------------------" 66 | echo "Installing JAVA..................................." 67 | ./scripts/install_java.sh 68 | # 69 | if [ ${INSTALL_SQLCL} == "true" ]; then 70 | echo "--------------------------------------------------" 71 | echo "Installing SQLCL.................................." 72 | ./scripts/install_sqlcl.sh 73 | fi 74 | # 75 | if [ ${INSTALL_APEX} == "true" ]; then 76 | # 77 | echo "--------------------------------------------------" 78 | echo "Installing ORACLE APEX............................" 79 | ./scripts/install_apex.sh 80 | # 81 | echo "--------------------------------------------------" 82 | echo "Installing TOMCAT................................." 83 | ./scripts/install_tomcat.sh 84 | # 85 | echo "--------------------------------------------------" 86 | echo "Installing ORACLE ORDS............................" 87 | ./scripts/install_ords.sh 88 | # 89 | if [ ${INSTALL_AOP} == "true" ]; then 90 | echo "--------------------------------------------------" 91 | echo "Installing AOP...................................." 92 | ./scripts/install_aop.sh 93 | fi 94 | if [ ${INSTALL_AME} == "true" ]; then 95 | echo "--------------------------------------------------" 96 | echo "Installing AME...................................." 97 | ./scripts/install_ame.sh 98 | fi 99 | if [ ${INSTALL_SWAGGER} == "true" ]; then 100 | echo "--------------------------------------------------" 101 | echo "Installing Swagger................................" 102 | ./scripts/install_swagger.sh 103 | fi 104 | if [ ${INSTALL_CA_CERTS_WALLET} == "true" ]; then 105 | echo "--------------------------------------------------" 106 | echo "Installing APEX CA SSL Wallet....................." 107 | ./scripts/install_ca_wallet.sh 108 | fi 109 | fi 110 | # 111 | if [ ${INSTALL_LOGGER} == "true" ]; then 112 | # 113 | echo "--------------------------------------------------" 114 | echo "Installing OraOpenSource Logger..................." 115 | ./scripts/install_logger.sh 116 | fi 117 | # 118 | if [ ${INSTALL_OOSUTILS} == "true" ]; then 119 | # 120 | echo "--------------------------------------------------" 121 | echo "Installing OraOpenSource OOS Utils................" 122 | ./scripts/install_oosutils.sh 123 | fi 124 | # 125 | echo "--------------------------------------------------" 126 | echo "Installing SSH...................................." 127 | ./scripts/install_ssh.sh 128 | # 129 | echo "--------------------------------------------------" 130 | echo "Cleanup..........................................." 131 | yum clean all 132 | rm -r -f /tmp/* 133 | rm -r -f /files/* 134 | rm -r -f /var/tmp/* 135 | echo "--------------------------------------------------" 136 | echo "DONE.............................................." 137 | -------------------------------------------------------------------------------- /scripts/install_oosutils.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | oosutils_create_user(){ 4 | echo "Creating OOS Utils User." 5 | 6 | echo 'create user OOSUTILS_USER identified by "'${PASS}'" default tablespace USERS temporary tablespace TEMP' > create_user_custom.sql 7 | echo "/" >> create_user_custom.sql 8 | echo "alter user OOSUTILS_USER quota unlimited on USERS" >> create_user_custom.sql 9 | echo "/" >> create_user_custom.sql 10 | echo "grant connect, create table, create procedure, create session to OOSUTILS_USER" >> create_user_custom.sql 11 | echo "/" >> create_user_custom.sql 12 | 13 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_user_custom 14 | } 15 | 16 | oosutils_install(){ 17 | echo "Installing OOS Utils." 18 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l oosutils_user/${PASS} @install/oos_utils_install 19 | } 20 | 21 | 22 | oosutils_public_grants(){ 23 | echo "Creating OOS Utils Public Grants." 24 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l oosutils_user/${PASS} @install/grant_to_oos_utils PUBLIC 25 | } 26 | 27 | oosutils_public_synonyms(){ 28 | echo "Creating OOS Utils Public Synonyms." 29 | 30 | echo "create or replace public synonym oos_util for oosutils_user.oos_util;" > create_oosutils_public_synonyms.sql 31 | echo "create or replace public synonym oos_util_apex for oosutils_user.oos_util_apex;" >> create_oosutils_public_synonyms.sql 32 | echo "create or replace public synonym oos_util_bit for oosutils_user.oos_util_bit;" >> create_oosutils_public_synonyms.sql 33 | echo "create or replace public synonym oos_util_crypto for oosutils_user.oos_util_crypto;" >> create_oosutils_public_synonyms.sql 34 | echo "create or replace public synonym oos_util_date for oosutils_user.oos_util_date;" >> create_oosutils_public_synonyms.sql 35 | echo "create or replace public synonym oos_util_lob for oosutils_user.oos_util_lob;" >> create_oosutils_public_synonyms.sql 36 | echo "create or replace public synonym oos_util_string for oosutils_user.oos_util_string;" >> create_oosutils_public_synonyms.sql 37 | echo "create or replace public synonym oos_util_totp for oosutils_user.oos_util_totp;" >> create_oosutils_public_synonyms.sql 38 | echo "create or replace public synonym oos_util_validation for oosutils_user.oos_util_validation;" >> create_oosutils_public_synonyms.sql 39 | echo "create or replace public synonym oos_util_web for oosutils_user.oos_util_web;" >> create_oosutils_public_synonyms.sql 40 | 41 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_oosutils_public_synonyms 42 | } 43 | 44 | oosutils_unzip(){ 45 | echo "Extracting OOS Utils" 46 | mkdir /files/oosutils 47 | unzip /files/oos-utils*.zip -d /files/oosutils/ 48 | } 49 | 50 | echo "Installing OOS Utils into DB: ${ORACLE_SID}" 51 | . /home/oracle/.bash_profile 52 | oosutils_unzip 53 | cd /files/oosutils/oos-utils-* 54 | oosutils_create_user 55 | oosutils_install 56 | oosutils_public_grants 57 | oosutils_public_synonyms 58 | cd / 59 | -------------------------------------------------------------------------------- /scripts/install_oracle12ee.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # create oracle groups 4 | groupadd --gid 54321 oinstall 5 | groupadd --gid 54322 dba 6 | groupadd --gid 54323 oper 7 | 8 | # create oracle user 9 | useradd --create-home --gid oinstall --groups oinstall,dba --uid 54321 oracle 10 | 11 | # set unix password 12 | echo 'oracle:'${PASS} | chpasswd 13 | 14 | # install required OS components 15 | yum install -y oracle-database-server-12cR2-preinstall.x86_64 \ 16 | perl \ 17 | tar \ 18 | unzip \ 19 | wget 20 | 21 | 22 | # environment variables (not configurable when creating a container) 23 | echo "export ORACLE_HOME=${ORACLE_HOME}" >> /.oracle_env 24 | echo "export ORACLE_BASE=${ORACLE_BASE}" >> /.oracle_env 25 | echo "export ORACLE_SID=${ORACLE_SID}" >> /.oracle_env 26 | echo "export PATH=/usr/sbin:\$PATH" >> /.oracle_env 27 | echo "export PATH=\$ORACLE_HOME/bin:\$PATH" >> /.oracle_env 28 | echo "export LD_LIBRARY_PATH=\$ORACLE_HOME/lib:/lib:/usr/lib" >> /.oracle_env 29 | echo "export CLASSPATH=\$ORACLE_HOME/jlib:\$ORACLE_HOME/rdbms/jlib" >> /.oracle_env 30 | echo "export TMP=/tmp" >> /.oracle_env 31 | echo "export TMPDIR=\$TMP" >> /.oracle_env 32 | echo "export TERM=linux" >> /.oracle_env # avoid in sqlcl: "tput: No value for $TERM and no -T specified" 33 | echo "export NLS_LANG=American_America.AL32UTF8" >> /.oracle_env 34 | chmod +x /.oracle_env 35 | 36 | # set environment 37 | . /.oracle_env 38 | cat /.oracle_env >> /home/oracle/.bash_profile 39 | cat /.oracle_env >> /home/oracle/.bashrc # .bash_profile not executed by docker 40 | cat /.oracle_env >> /root/.bash_profile 41 | cat /.oracle_env >> /root/.bashrc # .bash_profile not executed by docker 42 | 43 | # create directories and separate /u01/app/oracle/product to mount ${ORACLE_BASE} as volume 44 | mkdir -p /u01/app/oracle 45 | mkdir -p /u01/app/oracle-product 46 | mkdir -p /u01/app/oraInventory 47 | chown -R oracle:oinstall /u01 48 | ln -s /u01/app/oracle-product /u01/app/oracle/product 49 | 50 | # install gosu as workaround for su problems (see http://grokbase.com/t/gg/docker-user/162h4pekwa/docker-su-oracle-su-cannot-open-session-permission-denied) 51 | cp /files/gosu-amd64 /usr/local/bin/gosu 52 | chmod +x /usr/local/bin/gosu 53 | 54 | # extract Oracle database software 55 | cd /files 56 | chown oracle:oinstall /files/linuxx64_12201_database.zip 57 | echo "extracting Oracle database software..." 58 | gosu oracle bash -c "unzip -o /files/linuxx64_12201_database.zip -d /files/" > /dev/null 59 | rm -f /files/linuxx64_12201_database.zip 60 | 61 | # install Oracle software into ${ORACLE_BASE} 62 | sed -i -E 's:#ORACLE_INVENTORY#:'${ORACLE_INVENTORY}':g' /files/db_install_12.rsp 63 | sed -i -E 's:#ORACLE_HOME#:'${ORACLE_HOME}':g' /files/db_install_12.rsp 64 | sed -i -E 's:#ORACLE_BASE#:'${ORACLE_BASE}':g' /files/db_install_12.rsp 65 | 66 | chown oracle:oinstall /files/db_install_12.rsp 67 | echo "running Oracle installer to install database software only..." 68 | gosu oracle bash -c "/files/database/runInstaller -silent -force -waitforcompletion -responsefile /files/db_install_12.rsp -ignoresysprereqs -ignoreprereq" 69 | 70 | # Run Oracle root scripts 71 | echo "running Oracle root scripts..." 72 | #/u01/app/oraInventory/orainstRoot.sh > /dev/null 2>&1 73 | echo | ${ORACLE_HOME}/root.sh > /dev/null 2>&1 || true 74 | 75 | # Delete installer files 76 | rm -fr /files/database 77 | 78 | # Creating Database 79 | echo "Creating database. SID: ${ORACLE_SID}" 80 | mv /u01/app/oracle-product/12.2.0.1/dbhome/dbs ${ORACLE_BASE}/dbs 81 | ln -s ${ORACLE_BASE}/dbs /u01/app/oracle-product/12.2.0.1/dbhome/dbs 82 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl start" 83 | gosu oracle bash -c "${ORACLE_HOME}/bin/dbca -silent -createDatabase -templateName General_Purpose.dbc \ 84 | -gdbname ${SERVICE_NAME} -sid ${ORACLE_SID} -responseFile NO_VALUE -characterSet AL32UTF8 \ 85 | -totalMemory $DBCA_TOTAL_MEMORY -emConfiguration NONE -sysPassword ${PASS} -systemPassword ${PASS}" 86 | echo "Configure listener." 87 | gosu oracle bash -c 'echo -e "ALTER SYSTEM SET LOCAL_LISTENER='"'"'(ADDRESS = (PROTOCOL = TCP)(HOST = $(hostname))(PORT = 1521))'"'"' SCOPE=BOTH;\n ALTER SYSTEM REGISTER;\n EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l / as sysdba' 88 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl stop; ${ORACLE_HOME}/bin/lsnrctl start" 89 | 90 | # set some global database settings 91 | gosu oracle bash -c 'echo "ALTER PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA' 92 | -------------------------------------------------------------------------------- /scripts/install_oracle18ee.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # create oracle groups 4 | groupadd --gid 54321 oinstall 5 | groupadd --gid 54322 dba 6 | groupadd --gid 54323 oper 7 | 8 | # create oracle user 9 | useradd --create-home --gid oinstall --groups oinstall,dba --uid 54321 oracle 10 | 11 | # set unix password 12 | echo 'oracle:'${PASS} | chpasswd 13 | 14 | # install required OS components 15 | yum install -y oracle-database-preinstall-18c.x86_64 \ 16 | perl \ 17 | tar \ 18 | unzip \ 19 | wget 20 | 21 | 22 | # environment variables (not configurable when creating a container) 23 | echo "export ORACLE_HOME=${ORACLE_HOME}" >> /.oracle_env 24 | echo "export ORACLE_BASE=${ORACLE_BASE}" >> /.oracle_env 25 | echo "export ORACLE_SID=${ORACLE_SID}" >> /.oracle_env 26 | echo "export PATH=/usr/sbin:\$PATH" >> /.oracle_env 27 | echo "export PATH=\$ORACLE_HOME/bin:\$PATH" >> /.oracle_env 28 | echo "export LD_LIBRARY_PATH=\$ORACLE_HOME/lib:/lib:/usr/lib" >> /.oracle_env 29 | echo "export CLASSPATH=\$ORACLE_HOME/jlib:\$ORACLE_HOME/rdbms/jlib" >> /.oracle_env 30 | echo "export TMP=/tmp" >> /.oracle_env 31 | echo "export TMPDIR=\$TMP" >> /.oracle_env 32 | echo "export TERM=linux" >> /.oracle_env # avoid in sqlcl: "tput: No value for $TERM and no -T specified" 33 | echo "export NLS_LANG=American_America.AL32UTF8" >> /.oracle_env 34 | chmod +x /.oracle_env 35 | 36 | # set environment 37 | . /.oracle_env 38 | cat /.oracle_env >> /home/oracle/.bash_profile 39 | cat /.oracle_env >> /home/oracle/.bashrc # .bash_profile not executed by docker 40 | cat /.oracle_env >> /root/.bash_profile 41 | cat /.oracle_env >> /root/.bashrc # .bash_profile not executed by docker 42 | 43 | # create directories and separate /u01/app/oracle/product to mount ${ORACLE_BASE} as volume 44 | mkdir -p /u01/app/oracle 45 | mkdir -p /u01/app/oracle-product 46 | mkdir -p /u01/app/oraInventory 47 | chown -R oracle:oinstall /u01 48 | ln -s /u01/app/oracle-product /u01/app/oracle/product 49 | 50 | # install gosu as workaround for su problems (see http://grokbase.com/t/gg/docker-user/162h4pekwa/docker-su-oracle-su-cannot-open-session-permission-denied) 51 | cp /files/gosu-amd64 /usr/local/bin/gosu 52 | chmod +x /usr/local/bin/gosu 53 | 54 | # extract Oracle database software 55 | cd /files 56 | chown oracle:oinstall /files/LINUX.X64_180000_db_home.zip 57 | echo "extracting Oracle database software..." 58 | gosu oracle bash -c "mkdir -p ${ORACLE_HOME}" 59 | gosu oracle bash -c "unzip -o /files/LINUX.X64_180000_db_home.zip -d ${ORACLE_HOME}" > /dev/null 60 | rm -f /files/LINUX.X64_180000_db_home.zip 61 | 62 | # install Oracle software into ${ORACLE_BASE} 63 | sed -i -E 's:#ORACLE_INVENTORY#:'${ORACLE_INVENTORY}':g' /files/db_install_18.rsp 64 | sed -i -E 's:#ORACLE_HOME#:'${ORACLE_HOME}':g' /files/db_install_18.rsp 65 | sed -i -E 's:#ORACLE_BASE#:'${ORACLE_BASE}':g' /files/db_install_18.rsp 66 | 67 | chown oracle:oinstall /files/db_install_18.rsp 68 | echo "running Oracle installer to install database software only..." 69 | gosu oracle bash -c "${ORACLE_HOME}/runInstaller -silent -force -waitforcompletion -responsefile /files/db_install_18.rsp -ignorePrereqFailure" 70 | 71 | # Run Oracle root scripts 72 | echo "running Oracle root scripts..." 73 | #/u01/app/oraInventory/orainstRoot.sh > /dev/null 2>&1 74 | echo | ${ORACLE_HOME}/root.sh > /dev/null 2>&1 || true 75 | 76 | # Creating Database 77 | echo "Creating database. SID: ${ORACLE_SID}" 78 | mv /u01/app/oracle-product/18.0.0/dbhome/dbs ${ORACLE_BASE}/dbs 79 | ln -s ${ORACLE_BASE}/dbs /u01/app/oracle-product/18.0.0/dbhome/dbs 80 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl start" 81 | gosu oracle bash -c "${ORACLE_HOME}/bin/dbca -silent -createDatabase -templateName General_Purpose.dbc \ 82 | -gdbname ${SERVICE_NAME} -sid ${ORACLE_SID} -responseFile NO_VALUE -characterSet AL32UTF8 -datafileDestination /u01/app/oracle/oradata/ \ 83 | -totalMemory $DBCA_TOTAL_MEMORY -emConfiguration NONE -sysPassword ${PASS} -systemPassword ${PASS}" 84 | echo "Configure listener." 85 | gosu oracle bash -c 'echo -e "ALTER SYSTEM SET LOCAL_LISTENER='"'"'(ADDRESS = (PROTOCOL = TCP)(HOST = $(hostname))(PORT = 1521))'"'"' SCOPE=BOTH;\n ALTER SYSTEM REGISTER;\n EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l / as sysdba' 86 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl stop; ${ORACLE_HOME}/bin/lsnrctl start" 87 | 88 | # set some global database settings 89 | gosu oracle bash -c 'echo "ALTER PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA' 90 | -------------------------------------------------------------------------------- /scripts/install_oracle19ee.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # create oracle groups 4 | groupadd --gid 54321 oinstall 5 | groupadd --gid 54322 dba 6 | groupadd --gid 54323 oper 7 | 8 | # create oracle user 9 | useradd --create-home --gid oinstall --groups oinstall,dba --uid 54321 oracle 10 | 11 | # set unix password 12 | echo 'oracle:'${PASS} | chpasswd 13 | 14 | # install required OS components 15 | yum install -y oracle-database-preinstall-19c.x86_64 \ 16 | perl \ 17 | tar \ 18 | unzip \ 19 | wget 20 | 21 | 22 | # environment variables (not configurable when creating a container) 23 | echo "export ORACLE_HOME=${ORACLE_HOME}" >> /.oracle_env 24 | echo "export ORACLE_BASE=${ORACLE_BASE}" >> /.oracle_env 25 | echo "export ORACLE_SID=${ORACLE_SID}" >> /.oracle_env 26 | echo "export PATH=/usr/sbin:\$PATH" >> /.oracle_env 27 | echo "export PATH=\$ORACLE_HOME/bin:\$PATH" >> /.oracle_env 28 | echo "export LD_LIBRARY_PATH=\$ORACLE_HOME/lib:/lib:/usr/lib" >> /.oracle_env 29 | echo "export CLASSPATH=\$ORACLE_HOME/jlib:\$ORACLE_HOME/rdbms/jlib" >> /.oracle_env 30 | echo "export TMP=/tmp" >> /.oracle_env 31 | echo "export TMPDIR=\$TMP" >> /.oracle_env 32 | echo "export TERM=linux" >> /.oracle_env # avoid in sqlcl: "tput: No value for $TERM and no -T specified" 33 | echo "export NLS_LANG=American_America.AL32UTF8" >> /.oracle_env 34 | chmod +x /.oracle_env 35 | 36 | # set environment 37 | . /.oracle_env 38 | cat /.oracle_env >> /home/oracle/.bash_profile 39 | cat /.oracle_env >> /home/oracle/.bashrc # .bash_profile not executed by docker 40 | cat /.oracle_env >> /root/.bash_profile 41 | cat /.oracle_env >> /root/.bashrc # .bash_profile not executed by docker 42 | 43 | # create directories and separate /u01/app/oracle/product to mount ${ORACLE_BASE} as volume 44 | mkdir -p /u01/app/oracle 45 | mkdir -p /u01/app/oracle-product 46 | mkdir -p /u01/app/oraInventory 47 | chown -R oracle:oinstall /u01 48 | ln -s /u01/app/oracle-product /u01/app/oracle/product 49 | 50 | # install gosu as workaround for su problems (see http://grokbase.com/t/gg/docker-user/162h4pekwa/docker-su-oracle-su-cannot-open-session-permission-denied) 51 | cp /files/gosu-amd64 /usr/local/bin/gosu 52 | chmod +x /usr/local/bin/gosu 53 | 54 | # extract Oracle database software 55 | cd /files 56 | chown oracle:oinstall /files/LINUX.X64_193000_db_home.zip 57 | echo "extracting Oracle database software..." 58 | gosu oracle bash -c "mkdir -p ${ORACLE_HOME}" 59 | gosu oracle bash -c "unzip -o /files/LINUX.X64_193000_db_home.zip -d ${ORACLE_HOME}" > /dev/null 60 | rm -f /files/LINUX.X64_193000_db_home.zip 61 | 62 | # install Oracle software into ${ORACLE_BASE} 63 | sed -i -E 's:#ORACLE_INVENTORY#:'${ORACLE_INVENTORY}':g' /files/db_install_19.rsp 64 | sed -i -E 's:#ORACLE_HOME#:'${ORACLE_HOME}':g' /files/db_install_19.rsp 65 | sed -i -E 's:#ORACLE_BASE#:'${ORACLE_BASE}':g' /files/db_install_19.rsp 66 | 67 | chown oracle:oinstall /files/db_install_19.rsp 68 | echo "running Oracle installer to install database software only..." 69 | gosu oracle bash -c "${ORACLE_HOME}/runInstaller -silent -force -waitforcompletion -responsefile /files/db_install_19.rsp -ignorePrereqFailure" 70 | 71 | # Run Oracle root scripts 72 | echo "running Oracle root scripts..." 73 | #/u01/app/oraInventory/orainstRoot.sh > /dev/null 2>&1 74 | echo | ${ORACLE_HOME}/root.sh > /dev/null 2>&1 || true 75 | 76 | # Creating Database 77 | echo "Creating database. SID: ${ORACLE_SID}" 78 | mv /u01/app/oracle-product/19.0.0/dbhome/dbs ${ORACLE_BASE}/dbs 79 | ln -s ${ORACLE_BASE}/dbs /u01/app/oracle-product/19.0.0/dbhome/dbs 80 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl start" 81 | gosu oracle bash -c "${ORACLE_HOME}/bin/dbca -silent -createDatabase -templateName General_Purpose.dbc \ 82 | -gdbname ${SERVICE_NAME} -sid ${ORACLE_SID} -responseFile NO_VALUE -characterSet AL32UTF8 -datafileDestination /u01/app/oracle/oradata/ \ 83 | -totalMemory $DBCA_TOTAL_MEMORY -emConfiguration NONE -sysPassword ${PASS} -systemPassword ${PASS}" 84 | echo "Configure listener." 85 | gosu oracle bash -c 'echo -e "ALTER SYSTEM SET LOCAL_LISTENER='"'"'(ADDRESS = (PROTOCOL = TCP)(HOST = $(hostname))(PORT = 1521))'"'"' SCOPE=BOTH;\n ALTER SYSTEM REGISTER;\n EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l / as sysdba' 86 | gosu oracle bash -c "${ORACLE_HOME}/bin/lsnrctl stop; ${ORACLE_HOME}/bin/lsnrctl start" 87 | 88 | # set some global database settings 89 | gosu oracle bash -c 'echo "ALTER PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA' 90 | -------------------------------------------------------------------------------- /scripts/install_ords.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | #PASSWORD=${1:-secret} 3 | 4 | create_sdw_admin_user() { 5 | echo "Creating SQL Developer Web Admin User." 6 | 7 | echo 'create user SDW_ADMIN identified by "'${PASS}'" default tablespace USERS temporary tablespace TEMP' >create_sdw_admin_user.sql 8 | echo "/" >>create_sdw_admin_user.sql 9 | echo "alter user SDW_ADMIN quota unlimited on USERS" >>create_sdw_admin_user.sql 10 | echo "/" >>create_sdw_admin_user.sql 11 | echo "grant connect, dba, pdb_dba to SDW_ADMIN;" >>create_sdw_admin_user.sql 12 | echo "/" >>create_sdw_admin_user.sql 13 | 14 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA @create_sdw_admin_user 15 | } 16 | 17 | enable_ords_sdw_admin() { 18 | echo "Enable ORDS for SQL Developer Web Admin User." 19 | 20 | echo "BEGIN" >enable_ords_sdw_admin.sql 21 | echo " ORDS.enable_schema(" >>enable_ords_sdw_admin.sql 22 | echo " p_enabled => TRUE," >>enable_ords_sdw_admin.sql 23 | echo " p_schema => 'SDW_ADMIN'," >>enable_ords_sdw_admin.sql 24 | echo " p_url_mapping_type => 'BASE_PATH'," >>enable_ords_sdw_admin.sql 25 | echo " p_url_mapping_pattern => 'sdw_admin'," >>enable_ords_sdw_admin.sql 26 | echo " p_auto_rest_auth => FALSE" >>enable_ords_sdw_admin.sql 27 | echo " );" >>enable_ords_sdw_admin.sql 28 | echo " COMMIT;" >>enable_ords_sdw_admin.sql 29 | echo "END;" >>enable_ords_sdw_admin.sql 30 | echo "/" >>enable_ords_sdw_admin.sql 31 | 32 | echo "EXIT" | ${ORACLE_HOME}/bin/sqlplus -s -l sdw_admin/${PASS} @enable_ords_sdw_admin 33 | } 34 | 35 | source /etc/profile 36 | 37 | unzip -o /files/ords*.zip -d ${ORDS_HOME} 38 | 39 | sed -i -E 's:#PASSWORD#:'${PASS}':g' /files/ords_params.properties 40 | sed -i -E 's:#ORACLE_SID#:'${ORACLE_SID}':g' /files/ords_params.properties 41 | cp -rf /files/ords_params.properties ${ORDS_HOME}/params 42 | cd ${ORDS_HOME} 43 | cd .. 44 | CURR_DIR=$(pwd) 45 | cd ${ORDS_HOME} 46 | java -jar ords.war configdir $CURR_DIR 47 | java -jar ords.war install simple 48 | 49 | # tune some ORDS default settings 50 | java -jar ords.war set-property jdbc.InitialLimit 6 51 | java -jar ords.war set-property jdbc.MinLimit 6 52 | java -jar ords.war set-property jdbc.MaxLimit 40 53 | java -jar ords.war set-property jdbc.MaxConnectionReuseCount 10000 54 | 55 | # sqldev web: ords >= 19.4 56 | if [ ${INSTALL_SQLDEVWEB} == "true" ]; then 57 | java -jar ords.war set-property feature.sdw true 58 | java -jar ords.war set-property restEnabledSql.active true 59 | java -jar ords.war set-property database.api.enabled true 60 | java -jar ords.war set-property security.verifySSL false 61 | fi 62 | 63 | chmod 777 defaults.xml 64 | 65 | # copy files 66 | cp -rf ${ORDS_HOME}/ords.war ${TOMCAT_HOME}/webapps/ 67 | cp -rf ${ORACLE_HOME}/apex/images ${TOMCAT_HOME}/webapps/i 68 | if [ ! -z "${APEX_PATCH_SET_BUNDLE_FILE}" ]; then 69 | if ls /files/apexpatch/*/images 1> /dev/null 2>&1; then 70 | cp -rf /files/apexpatch/*/images/* ${TOMCAT_HOME}/webapps/i/ 71 | fi 72 | fi 73 | 74 | # sqldev web: ords >= 19.4 75 | if [ ${INSTALL_SQLDEVWEB} == "true" ]; then 76 | cd /files 77 | create_sdw_admin_user 78 | enable_ords_sdw_admin 79 | fi 80 | -------------------------------------------------------------------------------- /scripts/install_sqlcl.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | echo "extracting SQLCL..." 4 | unzip /files/sqlcl*.zip -d /opt > /dev/null 5 | chown -R oracle:oinstall /opt/sqlcl 6 | rm -f /files/sqlcl*.zip 7 | 8 | echo "export PATH=/opt/sqlcl/bin:\$PATH" >> /home/oracle/.bash_profile 9 | echo "export PATH=/opt/sqlcl/bin:\$PATH" >> /home/oracle/.bashrc # .bash_profile not executed by docker 10 | echo "export PATH=/opt/sqlcl/bin:\$PATH" >> /root/.bash_profile 11 | echo "export PATH=/opt/sqlcl/bin:\$PATH" >> /root/.bashrc # .bash_profile not executed by docker 12 | -------------------------------------------------------------------------------- /scripts/install_ssh.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # install openssh 4 | yum install -y openssh-server 5 | 6 | # set root password 7 | echo 'root:'${PASS} | chpasswd 8 | # generate ssh keys 9 | ssh-keygen -f /etc/ssh/ssh_host_rsa_key -N '' -t rsa 10 | ssh-keygen -f /etc/ssh/ssh_host_ecdsa_key -N '' -t ecdsa 11 | ssh-keygen -f /etc/ssh/ssh_host_ed25519_key -N '' -t ed25519 12 | 13 | # SSH login fix. Otherwise user is kicked off after login 14 | echo "export VISIBLE=now" >> /etc/profile 15 | sed -i 's/UsePAM yes/UsePAM no/' /etc/ssh/sshd_config 16 | 17 | # copy keys-file, so that we can later ssh without password 18 | if [ -f /files/authorized_keys ]; then 19 | sed -i 's/#PermitRootLogin yes/PermitRootLogin without-password/' /etc/ssh/sshd_config 20 | sed -i 's/#PubkeyAuthentication yes/PubkeyAuthentication yes/' /etc/ssh/sshd_config 21 | sed -i 's/#RSAAuthentication yes/RSAAuthentication yes/' /etc/ssh/sshd_config 22 | sed -i 's/PasswordAuthentication yes/PasswordAuthentication no/' /etc/ssh/sshd_config 23 | # set authorized_keys file root 24 | mkdir /root/.ssh/ 25 | cp /files/authorized_keys /root/.ssh/ 26 | restorecon -r -vv /root/.ssh 27 | chmod 600 /root/.ssh/authorized_keys 28 | # set authorized_keys file oracle 29 | mkdir /home/oracle/.ssh/ 30 | cp /files/authorized_keys /home/oracle/.ssh/ 31 | chown -R oracle:oinstall /home/oracle/.ssh/ 32 | restorecon -r -vv /home/oracle/.ssh 33 | chmod 600 /home/oracle/.ssh/authorized_keys 34 | fi 35 | -------------------------------------------------------------------------------- /scripts/install_swagger.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | unzip_and_move(){ 4 | unzip -o swagger-ui*.zip 5 | mv swagger-ui*/dist ${TOMCAT_HOME}/webapps/swagger-ui 6 | } 7 | 8 | cleanup(){ 9 | rm -fr swagger-ui* 10 | rm -f v3.*.zip 11 | rm -f insert_apex_platform_pref.sql 12 | } 13 | 14 | insert_apex_platform_pref(){ 15 | . /home/oracle/.bash_profile 16 | 17 | APEX_SCHEMA=`sqlplus -s -l sys/${PASS} AS SYSDBA < insert_apex_platform_pref.sql 24 | echo " INSERT INTO wwv_flow_platform_prefs(id,name,value,created_on,last_updated_on,pref_desc,security_group_id)" >> insert_apex_platform_pref.sql 25 | echo " VALUES(wwv_flow_id.next_val,'SWAGGER_UI_URL','/swagger-ui',SYSDATE,SYSDATE,NULL,10);" >> insert_apex_platform_pref.sql 26 | echo " COMMIT;" >> insert_apex_platform_pref.sql 27 | echo "END;" >> insert_apex_platform_pref.sql 28 | echo "/" >> insert_apex_platform_pref.sql 29 | 30 | ${ORACLE_HOME}/bin/sqlplus -s -l sys/${PASS} AS SYSDBA < ${TOMCAT_HOME}/bin/setenv.sh 18 | echo 'export JAVA_HOME="'${JAVA_HOME}'"' >> ${TOMCAT_HOME}/bin/setenv.sh 19 | echo 'export CATALINA_OPTS="$CATALINA_OPTS -Xms256m"' >> ${TOMCAT_HOME}/bin/setenv.sh 20 | echo 'export CATALINA_OPTS="$CATALINA_OPTS -Xmx512m"' >> ${TOMCAT_HOME}/bin/setenv.sh 21 | echo 'export CATALINA_OPTS="$CATALINA_OPTS -server"' >> ${TOMCAT_HOME}/bin/setenv.sh 22 | echo 'export CATALINA_OPTS="$CATALINA_OPTS -XX:PermSize=128m"' >> ${TOMCAT_HOME}/bin/setenv.sh 23 | echo 'export CATALINA_OPTS="$CATALINA_OPTS -XX:MaxPermSize=256m"' >> ${TOMCAT_HOME}/bin/setenv.sh 24 | chmod a+x ${TOMCAT_HOME}/bin/setenv.sh 25 | 26 | # fix some tomcat settings 27 | echo 'tomcat.util.http.parser.HttpParser.requestTargetAllow=|' >> ${TOMCAT_HOME}/conf/catalina.properties 28 | sed -i -E 's/(allow=").*(")/allow=".*"/g' ${TOMCAT_HOME}/webapps/manager/META-INF/context.xml 29 | sed -i -E 's/(allow=").*(")/allow=".*"/g' ${TOMCAT_HOME}/webapps/host-manager/META-INF/context.xml 30 | 31 | # add to path 32 | echo 'export CATALINA_HOME="'${TOMCAT_HOME}'"' > ${TOMCAT_HOME}/.profile 33 | echo 'export JAVA_HOME="'${JAVA_HOME}'"' >> ${TOMCAT_HOME}/.profile 34 | chmod a+x ${TOMCAT_HOME}/.profile 35 | -------------------------------------------------------------------------------- /scripts/setenv.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # disable SELinux 4 | setenforce disabled 5 | 6 | # Prevent owner issues on mounted folders 7 | chown -R oracle:dba ${ORACLE_BASE} 8 | rm -f ${ORACLE_BASE}/product 9 | ln -s /u01/app/oracle-product ${ORACLE_BASE}/product 10 | 11 | # Set environment variables 12 | . ~/.bashrc 13 | 14 | # Create tnsnames.ora 15 | if [ -f "${ORACLE_HOME}/network/admin/tnsnames.ora" ] 16 | then 17 | echo "tnsnames.ora found." 18 | else 19 | echo "Creating tnsnames.ora" 20 | printf "${ORACLE_SID} =\n\ 21 | (DESCRIPTION =\n\ 22 | (ADDRESS = (PROTOCOL = TCP)(HOST = $(hostname))(PORT = 1521))\n\ 23 | (CONNECT_DATA = (SERVICE_NAME = ${SERVICE_NAME})))\n" > ${ORACLE_HOME}/network/admin/tnsnames.ora 24 | fi 25 | 26 | # Create listener.ora 27 | if [ -f "${ORACLE_HOME}/network/admin/listener.ora" ] 28 | then 29 | echo "listener.ora found." 30 | else 31 | echo "SID_LIST_LISTENER =" > ${ORACLE_HOME}/network/admin/listener.ora 32 | echo " (SID_LIST =" >> ${ORACLE_HOME}/network/admin/listener.ora 33 | echo " (SID_DESC =" >> ${ORACLE_HOME}/network/admin/listener.ora 34 | echo " (SID_NAME = ${ORACLE_SID})" >> ${ORACLE_HOME}/network/admin/listener.ora 35 | echo " (ORACLE_HOME = ${ORACLE_HOME})" >> ${ORACLE_HOME}/network/admin/listener.ora 36 | echo " )" >> ${ORACLE_HOME}/network/admin/listener.ora 37 | echo " )" >> ${ORACLE_HOME}/network/admin/listener.ora 38 | echo "LISTENER =" >> ${ORACLE_HOME}/network/admin/listener.ora 39 | echo " (DESCRIPTION_LIST =" >> ${ORACLE_HOME}/network/admin/listener.ora 40 | echo " (DESCRIPTION =" >> ${ORACLE_HOME}/network/admin/listener.ora 41 | echo " (ADDRESS = (PROTOCOL = TCP)(HOST = $(hostname))(PORT = 1521))" >> ${ORACLE_HOME}/network/admin/listener.ora 42 | echo " (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))" >> ${ORACLE_HOME}/network/admin/listener.ora 43 | echo " )" >> ${ORACLE_HOME}/network/admin/listener.ora 44 | echo " )" >> ${ORACLE_HOME}/network/admin/listener.ora 45 | fi 46 | 47 | # fix ownership and access rights 48 | chown oracle:dba ${ORACLE_HOME}/network/admin/tnsnames.ora 49 | chmod 664 ${ORACLE_HOME}/network/admin/tnsnames.ora 50 | chown oracle:dba ${ORACLE_HOME}/network/admin/listener.ora 51 | chmod 664 ${ORACLE_HOME}/network/admin/listener.ora 52 | -------------------------------------------------------------------------------- /scripts/validations.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | echo "......Checking Scripts......" 4 | if [ ! -f /scripts/create_ca_wallet.sh ]; then 5 | echo "/scripts/create_ca_wallet.sh not found!" 6 | exit 1 7 | fi 8 | if [ ! -f /scripts/entrypoint.sh ]; then 9 | echo "/scripts/entrypoint.sh not found!" 10 | exit 1 11 | fi 12 | if [ ! -f /scripts/image_setup.sh ]; then 13 | echo "/scripts/image_setup.sh not found!" 14 | exit 1 15 | fi 16 | if [ ! -f /scripts/install_ame.sh ]; then 17 | echo "/scripts/install_ame.sh not found!" 18 | exit 1 19 | fi 20 | if [ ! -f /scripts/install_aop.sh ]; then 21 | echo "/scripts/install_aop.sh not found!" 22 | exit 1 23 | fi 24 | if [ ! -f /scripts/install_apex.sh ]; then 25 | echo "/scripts/install_apex.sh not found!" 26 | exit 1 27 | fi 28 | if [ ! -f /scripts/install_ca_wallet.sh ]; then 29 | echo "/scripts/install_ca_wallet.sh not found!" 30 | exit 1 31 | fi 32 | if [ ! -f /scripts/install_logger.sh ]; then 33 | echo "/scripts/install_logger.sh not found!" 34 | exit 1 35 | fi 36 | if [ ! -f /scripts/install_oosutils.sh ]; then 37 | echo "/scripts/install_oosutils.sh not found!" 38 | exit 1 39 | fi 40 | if [ ! -f /scripts/install_oracle12ee.sh ]; then 41 | echo "/scripts/install_oracle12ee.sh not found!" 42 | exit 1 43 | fi 44 | if [ ! -f /scripts/install_oracle18ee.sh ]; then 45 | echo "/scripts/install_oracle18ee.sh not found!" 46 | exit 1 47 | fi 48 | if [ ! -f /scripts/install_oracle19ee.sh ]; then 49 | echo "/scripts/install_oracle19ee.sh not found!" 50 | exit 1 51 | fi 52 | if [ ! -f /scripts/install_ords.sh ]; then 53 | echo "/scripts/install_ords.sh not found!" 54 | exit 1 55 | fi 56 | if [ ! -f /scripts/install_sqlcl.sh ]; then 57 | echo "/scripts/install_sqlcl.sh not found!" 58 | exit 1 59 | fi 60 | if [ ! -f /scripts/install_ssh.sh ]; then 61 | echo "/scripts/install_ssh.sh not found!" 62 | exit 1 63 | fi 64 | if [ ! -f /scripts/install_swagger.sh ]; then 65 | echo "/scripts/install_swagger.sh not found!" 66 | exit 1 67 | fi 68 | if [ ! -f /scripts/install_tomcat.sh ]; then 69 | echo "/scripts/install_tomcat.sh not found!" 70 | exit 1 71 | fi 72 | if [ ! -f /scripts/setenv.sh ]; then 73 | echo "/scripts/setenv.sh not found!" 74 | exit 1 75 | fi 76 | # 77 | echo "......Checking Files......" 78 | if [ ! -f /files/db_install_12.rsp ]; then 79 | echo "/files/db_install_12.rsp not found!" 80 | exit 1 81 | fi 82 | if [ ! -f /files/db_install_18.rsp ]; then 83 | echo "/files/db_install_18.rsp not found!" 84 | exit 1 85 | fi 86 | if [ ! -f /files/db_install_19.rsp ]; then 87 | echo "/files/db_install_19.rsp not found!" 88 | exit 1 89 | fi 90 | if [ ! -f /files/ords_params.properties ]; then 91 | echo "/files/ords_params.properties not found!" 92 | exit 1 93 | fi 94 | if [ ! -f /files/tomcat-users.xml ]; then 95 | echo "/files/tomcat-users.xml not found!" 96 | exit 1 97 | fi 98 | if [ ! -f /files/tomcat.service ]; then 99 | echo "/files/tomcat.service not found!" 100 | exit 1 101 | fi 102 | # 103 | echo "......Checking Downloaded Files......" 104 | if ! ls /files/gosu-amd64 1> /dev/null 2>&1; then 105 | echo "GOSU not found!" 106 | exit 1 107 | fi 108 | if ! ls /files/OpenJDK11U-jdk_*.tar.gz 1> /dev/null 2>&1; then 109 | echo "Java not found!" 110 | exit 1 111 | fi 112 | if [ ${DB_INSTALL_VERSION} == "12" ]; then 113 | if ! ls /files/linuxx64_12201_database.zip 1> /dev/null 2>&1; then 114 | echo "Oracle DB 12.2.0.1 not found!" 115 | exit 1 116 | fi 117 | fi 118 | if [ ${DB_INSTALL_VERSION} == "18" ]; then 119 | if ! ls /files/LINUX.X64_180000_db_home.zip 1> /dev/null 2>&1; then 120 | echo "Oracle DB 18.0.0 not found!" 121 | exit 1 122 | fi 123 | fi 124 | if [ ${DB_INSTALL_VERSION} == "19" ]; then 125 | if ! ls /files/LINUX.X64_193000_db_home.zip 1> /dev/null 2>&1; then 126 | echo "Oracle DB 19.0.0 not found!" 127 | exit 1 128 | fi 129 | fi 130 | if [ ${INSTALL_SQLCL} == "true" ]; then 131 | if ! ls /files/sqlcl*.zip 1> /dev/null 2>&1; then 132 | echo "SQLcl not found!" 133 | exit 1 134 | fi 135 | fi 136 | if [ ${INSTALL_LOGGER} == "true" ]; then 137 | if ! ls /files/logger_*.zip 1> /dev/null 2>&1; then 138 | echo "Logger not found!" 139 | exit 1 140 | fi 141 | fi 142 | if [ ${INSTALL_OOSUTILS} == "true" ]; then 143 | if ! ls /files/oos-utils*.zip 1> /dev/null 2>&1; then 144 | echo "OOS Utils not found!" 145 | exit 1 146 | fi 147 | fi 148 | if [ ${INSTALL_APEX} == "true" ]; then 149 | if ! ls /files/apex*.zip 1> /dev/null 2>&1; then 150 | echo "APEX not found!" 151 | exit 1 152 | fi 153 | if ! ls /files/apache-tomcat*.tar.gz 1> /dev/null 2>&1; then 154 | echo "Tomcat not found!" 155 | exit 1 156 | fi 157 | if ! ls /files/ords*.zip 1> /dev/null 2>&1; then 158 | echo "ORDS not found!" 159 | exit 1 160 | fi 161 | if [ ${INSTALL_AOP} == "true" ]; then 162 | if ! ls /files/aop_cloud_v*.zip 1> /dev/null 2>&1; then 163 | echo "APEX Office Print not found!" 164 | exit 1 165 | fi 166 | fi 167 | if [ ${INSTALL_AME} == "true" ]; then 168 | if ! ls /files/ame_cloud_v*.zip 1> /dev/null 2>&1; then 169 | echo "APEX Media Extension not found!" 170 | exit 1 171 | fi 172 | fi 173 | if [ ${INSTALL_SWAGGER} == "true" ]; then 174 | if ! ls /files/swagger-ui*.zip 1> /dev/null 2>&1; then 175 | echo "Swagger-UI not found!" 176 | exit 1 177 | fi 178 | fi 179 | if [ ! -z "${APEX_PATCH_SET_BUNDLE_FILE}" ]; then 180 | if ! ls /files/${APEX_PATCH_SET_BUNDLE_FILE} 1> /dev/null 2>&1; then 181 | echo "APEX Patch Set Bundle File not found!" 182 | exit 1 183 | fi 184 | fi 185 | fi 186 | # 187 | echo "......Validations Done......" 188 | --------------------------------------------------------------------------------