I am trying to update the host-slave.xml from a Wildfly Cluster configuration with xmlstarlet.
I am using the following statement:
xml ed -N my=urn:jboss:domain:2.2 -u "_:host/management/security-realms/security-realm[@name='UndertowRealm']/server-identities/ssl/keystore/@path" -v "test" Wildfly\wildfly-8.2.0.Final\WildFly-HOST\configuration\host-slave.xml
The namespace definition in xml:
<host name="172.16.1.11" xmlns="urn:jboss:domain:2.2" >
The part of the xml I want to change:
<security-realm name="UndertowRealm">
<server-identities>
<ssl>
<keystore path="D:\wildfly-8.2.0.Final\ssl\wildfly.keystore" keystore-password="rsaddbTsadYvvMXZ" alias="wildfly" />
</ssl>
</server-identities>
</security-realm>
But if I delete the namespace defition from the xml, and use the following statement:
xml ed -u ":host/management/security-realms/security-realm[@name='UndertowRealm']/server-identities/ssl/keystore/@path" -v "test" Wildfly\wildfly-8.2.0.Final\WildFly-HOST\configuration\host-slave.xml
It works as expected, so it is not an Issue with XPATH. As I dont know what happens to wildfly if I delete the namespace declaration, I would like to keep it.