jBoss 7.1설정
1. JBOSS_HOME/standalone/configuration/standalone.xml
1.1 log level설정 INFO -> DEBUG
54line
<profile>
<subsystem xmlns="urn:jboss:domain:logging:1.1">
<console-handler name="CONSOLE">
<level name="DEBUG"/>
85line
<root-logger>
<level name="DEBUG"/>
1.2 datasource 설정 ( JBOSS_HOME/modules xml파일과 jdbc드라이버설정해야함)
96line <!-- postgres 경우 -->
<datasources>
<datasource jndi-name="java:/contractDS" pool-name="contractDS1" enabled="true" use-java-context="true">
<connection-url>jdbc:postgresql://127.0.0.1/ctrtopen</connection-url>
<driver>postgresql</driver>
<security>
<user-name>ctrtopen</user-name>
<password>eds6050</password>
</security>
</datasource>
<drivers>
<driver name="postgresql" module="com.postgresql">
<xa-datasource-class>org.postgresql.Driver</xa-datasource-class>
</driver>
</drivers>
</datasources>
<!-- oracle 경우 -->
<datasources>
<datasource jndi-name="java:/contractDS" pool-name="contractDS1" enabled="true" use-java-context="true">
<connection-url>jdbc:oracle:thin:@oracle2.ejudata.co.kr:1521:oracle</connection-url>
<driver>oracle</driver>
<security>
<user-name>ehojo_ctrtopen</user-name>
<password>eds6050</password>
</security>
</datasource>
<drivers>
<driver name="oracle" module="com.oracle">
<xa-datasource-class>oracle.jdbc.OracleDriver</xa-datasource-class>
</driver>
</drivers>
</datasources>
1.3 virtual-host 설정 Context Root /WEB-INF/jboss-web.xml 에 추가
258 line
<subsystem xmlns="urn:jboss:domain:web:1.1" default-virtual-server="default-host" native="true">
<connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
<virtual-server name="default-host" enable-welcome-root="false">
<alias name="gyeyak.local.com"/>
<alias name="example.com"/>
</virtual-server>
<virtual-server name="test1.local.com" default-web-module="test1">
<alias name="test1.local.com"/>
</virtual-server>
</subsystem>
1.4 기본 port변경 8080 --> 80
295line
<socket-binding name="http" port="80"/>
1.5 deployment 설정
파일변경시 자동적용 auto-deploy-exploded="true"
JBOSS_HOME 아래가 아닌 외부경로 추가
111 line
<subsystem xmlns="urn:jboss:domain:deployment-scanner:1.1">
<deployment-scanner path="deployments" relative-to="jboss.server.base.dir" scan-interval="5000"/>
<deployment-scanner name="ctrt" path="D:/workspace/" scan-interval="5000" auto-deploy-exploded="true"/>
</subsystem>
2.1 db접속관련
JBOSS_HOME\modules\com\oracle\main\module.xml
JBOSS_HOME\modules\com\oracle\main\ojdbc6.jar
JBOSS_HOME\modules\com\oracle\main\ojdbc6.jar.index
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.0" name="com.oracle">
<resources>
<resource-root path="ojdbc6.jar"/>
<!-- Insert resources here -->
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
<module name="javax.servlet.api" optional="true"/>
</dependencies>
</module>
3.1 jboss-web.xml
-----jboss-web.xml--시작---파일내용 참고------------------------------------
<?xml version="1.0"?>
http://www.jboss.org/j2ee/dtd/jboss-web_4_0.dtd">
<jboss-web>
<context-root>/</context-root>
<virtual-host>test2.local.com</virtual-host>
</jboss-web>
-----jboss-web.xml--끝---파일내용 참고------------------------------------
'Tool > WEB,WAS' 카테고리의 다른 글
tomcat / catalina.out / 일자별 log (0) | 2021.10.05 |
---|---|
Jboss 7.1.1 as Windows service (0) | 2020.04.27 |
WAS / jboss 5.1 Administration Console password change (0) | 2020.04.24 |
nginx default.conf (0) | 2019.04.10 |
centos / nginx / install nginx on centos 7 (0) | 2019.04.10 |