Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
EJBCA 6.3.1.1 on Wildfly 8.2.1
connect
/interfaces=/interface=httpspub:add(inet-address="0.0.0.0")
/interfaces=/interface=httpspriv:add(inet-address="0.0.0.0")
/subsystem=undertow/server=default-server/http-listener=default:write-attribute(name=redirect-socket, value="httpspriv")
reload
/core-service=management/security-realm=SSLRealm:add()
/core-service=management/security-realm=SSLRealm/server-identity=ssl:add(keystore-path="${jboss.server.config.dir}/keystore/keystore.jks", keystore-password="serverpwd", alias="localhost")
/core-service=management/security-realm=SSLRealm/authentication=truststore:add(keystore-path="${jboss.server.config.dir}/keystore/truststore.jks", keystore-password="changeit")
/socket-binding-group=standard-sockets/socket-binding=httpspriv:add(port="8443",interface="httpspriv")
/subsystem=undertow/server=default-server/https-listener=httpspriv:add(socket-binding=httpspriv, security-realm="SSLRealm", verify-client=REQUIRED)
/socket-binding-group=standard-sockets/socket-binding=httpspub:add(port="8442", interface="httpspub")
/subsystem=undertow/server=default-server/https-listener=httpspub:add(socket-binding=httpspub, security-realm="SSLRealm")
reload
/system-property=org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH:add(value=true)
/system-property=org.apache.catalina.connector.CoyoteAdapter.ALLOW_BACKSLASH:add(value=true)
/system-property=org.apache.catalina.connector.URI_ENCODING:add(value="UTF-8")
/system-property=org.apache.catalina.connector.USE_BODY_ENCODING_FOR_QUERY_STRING:add(value=true)
/subsystem=webservices:write-attribute(name=wsdl-host, value=jbossws.undefined.host)
/subsystem=webservices:write-attribute(name=modify-wsdl-address, value=true)
reload
connect
/subsystem=datasources/data-source=ejbcaDS:add(jndi-name=java:jboss/datasources/EjbcaDS,driver-name=h2,connection-url=jdbc:h2:file:/tmp/ejbca;DB_CLOSE_DELAY\=-1,user-name=ejbca,password=ejbca)
/subsystem=remoting/http-connector=http-remoting-connector:remove
/subsystem=remoting/http-connector=http-remoting-connector:add(connector-ref="remoting",security-realm="ApplicationRealm")
/socket-binding-group=standard-sockets/socket-binding=remoting:add(port="4447")
/subsystem=undertow/server=default-server/http-listener=remoting:add(socket-binding=remoting)
reload
/subsystem=logging/logger=org.ejbca:add
/subsystem=logging/logger=org.ejbca:write-attribute(name=level, value=DEBUG)
/subsystem=logging/logger=org.cesecore:add
/subsystem=logging/logger=org.cesecore:write-attribute(name=level, value=DEBUG)
#!/bin/sh
[ -f jboss.pid ] && kill $(cat jboss.pid)
rm jboss.pid jboss.out
rm /tmp/ejbca.h2.db
rm -rf ejbca_ce_6_3_1_1
rm -rf wildfly-8.2.1.Final
#!/bin/sh
set -e
JBOSS_PIDFILE=jboss.pid
LAUNCH_JBOSS_IN_BACKGROUND=1
export JBOSS_PIDFILE LAUNCH_JBOSS_IN_BACKGROUND
! [ -f ejbca_ce_6_3_1_1.zip ] && wget -O ejbca_ce_6_3_1_1.zip 'http://downloads.sourceforge.net/project/ejbca/ejbca6/ejbca_6_3_1_1/ejbca_ce_6_3_1_1.zip?r=&ts=1446155771&use_mirror=netix'
! [ -f wildfly-8.2.1.Final.tar.gz ] && wget http://download.jboss.org/wildfly/8.2.1.Final/wildfly-8.2.1.Final.tar.gz
unzip ejbca_ce_6_3_1_1.zip > /dev/null
tar zxf wildfly-8.2.1.Final.tar.gz
sed '/^# Default: $APPSRV_HOME/aappserver.home=/home/mad/jboss/wildfly-8.2.1.Final' ejbca_ce_6_3_1_1/conf/ejbca.properties.sample > ejbca_ce_6_3_1_1/conf/ejbca.properties
sed '/^#datasource.jndi-name=EjbcaDS/adatasource.jndi-name=jboss/datasources/EjbcaDS' ejbca_ce_6_3_1_1/conf/database.properties.sample > ejbca_ce_6_3_1_1/conf/database.properties
echo 'Starting jboss'
./wildfly-8.2.1.Final/bin/standalone.sh >> jboss.out 2>&1 &
sleep 5
./wildfly-8.2.1.Final/bin/add-user.sh -u admin -p admin
./wildfly-8.2.1.Final/bin/jboss-cli.sh --file=predeploy.jboss
(cd ejbca_ce_6_3_1_1 && ant clean deployear && ant runinstall && ant deploy-keystore)
./wildfly-8.2.1.Final/bin/jboss-cli.sh --file=postinstall.jboss
echo 'Restarting jboss'
kill $(cat jboss.pid)
./wildfly-8.2.1.Final/bin/standalone.sh >> jboss.out 2>&1 &
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.