Pr-requisites
- Oracle JDK Installed
- Oracle Fusion Middleware Infrastructure 12.2.1 installed
- Environment setup with bash profile
- JRF Restricted template - oracle.jrf_restricted_template.jar
- Enterprise Manager - oracle.em_wls_restricted_template.jar
- Coherence - wls_coherence_template.jar [default selected with above anyone of the template]
Lets first create the properties file:
TEMPLATE=/u01/app/oracle/fmw1221/wlserver/common/templates/wls/wls.jar MW_HOME=/u01/app/oracle/fmw1221 ADMIN_LISTEN_ADDRESS=192.168.33.100 ADMIN_PORT=8001 ADMIN_USER=weblogic ADMIN_PWD=Welcome1 DOMAIN_NAME=RestrictedJRF_Domain DOMAIN_DIR=/u01/app/oracle/domains
Note: You could modifiy the MW_HOME path
The WLST Script is as follows:
def create_prod_domain(): print "Reading base domain tempalte" readTemplate(TEMPLATE) cd('/') print "AdminServer settings" cmo.setName(DOMAIN_NAME) cd('Servers/AdminServer') cmo.setListenAddress(ADMIN_LISTEN_ADDRESS) cmo.setListenPort(int(ADMIN_PORT)) cd( '/' ) cd( 'Security/'+DOMAIN_NAME+'/User/' +ADMIN_USER) cmo.setPassword(ADMIN_PWD) cd('/') print "Production domain setup.." setOption("ServerStartMode", "prod") setOption("OverwriteDomain", "true") writeDomain( DOMAIN_DIR+'/'+DOMAIN_NAME ) print "==============================================" print "Production domain created successfully..." print "==============================================" closeTemplate() def apply_jrf2domain(): # Apply the JRF Template. print "reading domain:"+DOMAIN_NAME readDomain(DOMAIN_DIR+'/'+DOMAIN_NAME ) addTemplate(MW_HOME + '/oracle_common/common/templates/wls/oracle.jrf_restricted_template.jar') print "Adding Template :oracle.jrf_restricted_template.jar" # I'm including the EM template too. addTemplate(MW_HOME + '/em/common/templates/wls/oracle.em_wls_restricted_template.jar') print "Added Template :oracle.em_wls_restricted_template.jar" updateDomain() print "Updated the domain with Restricted JRF and Enterprise Manager templates" closeDomain() print "Close the domain" exit() def main(): print "==============================================" print "Welcome to Restricted JRF domain configuration" print "==============================================" create_prod_domain() print "Domain created successfully..." apply_jrf2domain() main()
The script execution will be as follows:
wlst -loadProperties RestrictedJRF_domain.properties create_RestrictedJRF_domain.py
Note: wlst must be aliased to the Infrastructure installation wlserver path
Restricted JRF WebLogic infrastructure domain with EM template |
- Enterprise Manager Fusion Middleware Control
- Easy to work on FW products such as SOA, OSB, and Collocated OHS etc
Start your Restricted JRF Domain and when you look into WebLogic Admin console deployments see the following:
WebLogic Restricted Domain deployment |