Disable Deployment-Scanner in JBoss

Look for the deployment-scanner config in your standalone.xml and configure the scan interval to -1 to allow deployment onyl from shell or at startup. Here is the relevant part: <subsystem xmlns=”urn:jboss:domain:deployment-scanner:1.1″> <deployment-scanner path=”deployments” relative-to=”jboss.server.base.dir” scan-interval=”-1″/> </subsystem> Or with cli: /subsystem=deployment-scanner/scanner=default:write-attribute(name=scan-interval, value=-1)  

Disable Deployment-Scanner in JBoss Read More »

Remove ExampleDS datasource in EAP6

To remove the ExampleDS datasource simply remove the relevant part from your standalone.xml: <datasource jndi-name=”java:jboss/datasources/ExampleDS” pool-name=”ExampleDS” enabled=”true” use-java-context=”true”> <connection-url>jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE</connection-url> <driver>h2</driver> <security> <user-name>sa</user-name> <password>sa</password> </security> </datasource> Or with cli: /subsystem=datasources/data-source=ExampleDS:remove  

Remove ExampleDS datasource in EAP6 Read More »

Configure Aliases in EAP6

The default configuration states localhost and example.com as aliases. To change this you have to simply change or remove the specific parts of your virtual-server config in your standalone.xml: <virtual-server name=”default-host” enable-welcome-root=”false”> <alias name=”localhost”/> </virtual-server> This would only be a single alias with value localhost (and disabled welcome root). Or to change it with cli:

Configure Aliases in EAP6 Read More »

Disable welcome-root in EAP6

To remove the default welcome page your have to change your virtual server config in your standalone.xml to state enable-welcome-root=”false”: <virtual-server name=”default-host” enable-welcome-root=”false”> <alias name=”localhost”/> </virtual-server> Or with cli: /subsystem=web/virtual-server=default-host:write-attribute(name=enable-welcome-root,value=false)  

Disable welcome-root in EAP6 Read More »

Change SERVER header in EAP6

I found no way to remove the Server header in EAP6. But there is a way to change its content. Just add the folling config to your standalone.xml: <system-properties>   <property name=”org.apache.coyote.http11.Http11Protocol.SERVER” value=”foo”/> </system-properties> Or with cli: /system-property=org.apache.coyote.http11.Http11Protocol.SERVER:add(value=foo) Then your header just is Server: foo instead.

Change SERVER header in EAP6 Read More »

Remove X_POWERED_BY Header in JBoss EAP6

First you have to disable it in standalone.xml by adding jsp-configuration x-powered-by=”false”. Here the relevant part of my config: <subsystem xmlns=”urn:jboss:domain:web:1.5″ default-virtual-server=”default-host” native=”false”> <connector name=”http” protocol=”HTTP/1.1″ scheme=”http” socket-binding=”http”/> <virtual-server name=”default-host” enable-welcome-root=”false”> <alias name=”localhost”/> </virtual-server> <configuration> <jsp-configuration x-powered-by=”false”/> </configuration> </subsystem> Or with cli: /subsystem=web/configuration=jsp-configuration:write-attribute(name=x-powered-by,value=false) In a JSF application you have to add the following context param: <context-param>

Remove X_POWERED_BY Header in JBoss EAP6 Read More »