Migration to Standalone
This chapter provides a guideline for migrating a nevisIDM instance with container type adnjboss (v5.1.x) or adnwildfly (v10.1.x) to a nevisIDM instance of deployment type "standalone".
There is no automated instance migration. Gather the information from the current source instance and use it to create a new target standalone instance. This document covers the most common configuration use cases and makes recommendations for their migration.
Instance parameters gathering
Server parameters
In a first step, gather all the required parameters of the current instance. See also the following table. Some parameters are only required if TLS is used.
If all the required parameters are known, you can skip the step Parameter retrieval.
| Parameter | Default | Description |
|---|---|---|
| SERVER_URL_PROTOCOL | http or https | The server protocol. In case of TLS the protocol is https. |
| SERVER_URL_SERVER | localhost | The server host name. |
| SERVER_URL_PORT | 8989 | The server port. |
| SERVER_TLS_KEYSTORE | /var/opt/neviskeybox/ default/default/node_keystore.jks | Keystore used to identify the server (sent to the client on a SSL/TLS client hello).(info) Only required for TLS. |
| SERVER_TLS_KEYSTORE_PASSWORD | Passphrase to access the server keystore.(info) Only required for TLS. | |
| SERVER_TLS_TRUSTSTORE | /var/opt/neviskeybox/ default/default/truststore.jks | Truststore used to validate client certificates.(info) Only required for TLS. |
| SERVER_TLS_TRUSTSTORE_PASSWORD | Passphrase to access the server truststore (usually not required, because the truststore contains public certificates, which do not require protection).(info) Only required for TLS. | |
| NINJA_CERT | /var/opt/neviskeybox/ default/nevis/truststore.jks | This parameter is used to configure the trust anchor for Nevis SecToken validation. It is used by the Nevis JAAS login module. |
Parameter retrieval
adnjboss
The required parameters can be retrieved as described in chapter Parameter retrieval of the Migration Guide from adnjboss to adnwildfly.
adnwildfly
The server parameters can be retrieved from security realms, security domains, interfaces and socket bindings configured in the file standalone.xml. You can access this file either with the command nevisidm <instance_name> config server, or by opening the file /var/opt/adnwildfly/instances/<new_instance_name>/standalone/configuration/standalone.xml.
The following two examples show the standalone.xml file for the protocol types HTTPS and HTTP, respectively.
HTTPS standalone.xml
<security-realms>
<security-realm name="SslRealm">
<server-identities>
<ssl>
<keystore path="${SERVER_TLS_KEYSTORE}" keystore-password="${SERVER_TLS_KEYSTORE_PASSWORD}"/>
</ssl>
</server-identities>
<authentication>
<truststore path="${SERVER_TLS_TRUSTSTORE}" keystore-password="${SERVER_TLS_TRUSTSTORE_PASSWORD}"/>
</authentication>
</security-realm>
</security-realms>
<profile>
<subsystem xmlns="urn:jboss:domain:undertow:1.2">
<buffer-cache name="default" />
<server name="default-server">
`<http-listener name="default-ssl" socket-binding="https" security-realm="SslRealm"/>
<host name="default-host" alias="${SERVER_URL_SERVER}"/>
</server>
<servlet-container name="default">
<jsp-config />
</servlet-container>
</subsystem>
<subsystem xmlns="urn:jboss:domain:security:1.2">
<security-domains>
<security-domain name="NevisSecTokenDomain" cache-type="default">
<authentication>
<login-module code="ch.nevis.ninja.jboss.auth.NinjaJbossLoginModuleImpl" flag="required" module="ch.nevis.ninja">
<module-option name="NevisSignerCertificate" value="${NINJA_CERT}"/>
<module-option name="UserGetter" value="AttributeUserGetter(source=loginId)"/>
<module-option name="AdjustIdentity" value="true"/>
<module-option name="LogDebug" value="false"/>
<module-option name="RoleGetters" value="ch.nevis.ninja.commons.mapping.StaticRoleGetter, ch.nevis.ninja.commons.mapping.TokenRoleGetter"/>
</login-module>
</authentication>
</security-domain>
</security-domains>
</subsystem>
</profile>
<interfaces>
<interface name="public">
<inet-address value="${SERVER_URL_SERVER}"/>
</interface>
</interfaces>
<socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">
<socket-binding name="https" port="${SERVER_PORT}" fixed-port="true" />
</socket-binding-group>
HTTP standalone.xml
<profile>
<subsystem xmlns="urn:jboss:domain:undertow:1.2">
<buffer-cache name="default"/>
<server name="default-server">
<http-listener name="default" socket-binding="http" redirect-socket="http"/>
<host name="default-host" alias="${SERVER_URL_SERVER}"/>
</server>
<servlet-container name="default">
<jsp-config/>
</servlet-container>
</subsystem>
<subsystem xmlns="urn:jboss:domain:security:1.2">
<security-domains>
<security-domain name="NevisSecTokenDomain" cache-type="default">
<authentication>
<login-module code="ch.nevis.ninja.jboss.auth.NinjaJbossLoginModuleImpl" flag="required" module="ch.nevis.ninja">
<module-option name="NevisSignerCertificate" value="${NINJA_CERT}"/>
<module-option name="UserGetter" value="AttributeUserGetter(source=loginId)"/>
<module-option name="AdjustIdentity" value="true"/>
<module-option name="LogDebug" value="false"/>
<module-option name="RoleGetters" value="ch.nevis.ninja.commons.mapping.StaticRoleGetter, ch.nevis.ninja.commons.mapping.TokenRoleGetter"/>
</login-module>
</authentication>
</security-domain>
</security-domains>
</subsystem>
</profile>
<interfaces>
<interface name="public">
<inet-address value="${SERVER_URL_SERVER}"/>
</interface>
</interfaces>
<socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">
<socket-binding name="http" port="${SERVER_PORT}" fixed-port="true"/>
</socket-binding-group>
Old instance stopping
Once you have gathered the required parameters, you can stop the old instance.
Use the following command:
nevisidm <instance_name> stop
Upgrade nevisIDM
The latest version of nevisIDM has deprecated the support of adnjboss. Therefore, if your old nevisIDM instance is of deployment type adnjboss, make sure to stop itbefore you upgrade nevisIDM to the latest version.
The next step is to install the latest version of nevisIDM (at least 2.72.0.x) on the server.
Standalone instance creation
The deployment type standalone is the default. To create a new standalone instance, use the following command: