2017-09-21 13:01:01 +00:00
|
|
|
embed-server --server-config=standalone-ha.xml
|
|
|
|
|
|
|
|
echo **** Begin ****
|
|
|
|
|
|
|
|
echo *** Update jgoups subsystem ***
|
|
|
|
/subsystem=jgroups/stack=udp/transport=UDP:write-attribute(name=site, value=${jboss.site.name})
|
|
|
|
|
|
|
|
echo *** Update infinispan subsystem ***
|
|
|
|
/subsystem=infinispan/cache-container=keycloak:write-attribute(name=module, value=org.keycloak.keycloak-model-infinispan)
|
|
|
|
|
2017-10-13 19:32:16 +00:00
|
|
|
echo ** Add remote socket binding to infinispan server **
|
|
|
|
/socket-binding-group=standard-sockets/remote-destination-outbound-socket-binding=remote-cache:add(host=${remote.cache.host:localhost}, port=${remote.cache.port:11222})
|
|
|
|
|
2017-09-21 13:01:01 +00:00
|
|
|
echo ** Update replicated-cache work element **
|
2017-10-13 19:32:16 +00:00
|
|
|
/subsystem=infinispan/cache-container=keycloak/replicated-cache=work/store=remote:add( \
|
2017-09-21 13:01:01 +00:00
|
|
|
passivation=false, \
|
|
|
|
fetch-state=false, \
|
|
|
|
purge=false, \
|
|
|
|
preload=false, \
|
2017-10-13 19:32:16 +00:00
|
|
|
shared=true, \
|
|
|
|
remote-servers=["remote-cache"], \
|
|
|
|
cache=work, \
|
|
|
|
properties={ \
|
2017-09-21 13:01:01 +00:00
|
|
|
rawValues=true, \
|
2017-10-13 19:32:16 +00:00
|
|
|
marshaller=org.keycloak.cluster.infinispan.KeycloakHotRodMarshallerFactory \
|
2017-09-21 13:01:01 +00:00
|
|
|
} \
|
|
|
|
)
|
|
|
|
|
|
|
|
/subsystem=infinispan/cache-container=keycloak/replicated-cache=work:write-attribute(name=statistics-enabled,value=true)
|
|
|
|
|
|
|
|
echo ** Update distributed-cache sessions element **
|
2017-10-13 19:32:16 +00:00
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=sessions/store=remote:add( \
|
2017-09-21 13:01:01 +00:00
|
|
|
passivation=false, \
|
|
|
|
fetch-state=false, \
|
|
|
|
purge=false, \
|
|
|
|
preload=false, \
|
2017-10-13 19:32:16 +00:00
|
|
|
shared=true, \
|
|
|
|
remote-servers=["remote-cache"], \
|
|
|
|
cache=sessions, \
|
|
|
|
properties={ \
|
|
|
|
rawValues=true, \
|
|
|
|
marshaller=org.keycloak.cluster.infinispan.KeycloakHotRodMarshallerFactory \
|
2017-09-21 13:01:01 +00:00
|
|
|
} \
|
|
|
|
)
|
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=sessions:write-attribute(name=statistics-enabled,value=true)
|
|
|
|
|
|
|
|
echo ** Update distributed-cache offlineSessions element **
|
2017-10-13 19:32:16 +00:00
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=offlineSessions/store=remote:add( \
|
2017-09-21 13:01:01 +00:00
|
|
|
passivation=false, \
|
|
|
|
fetch-state=false, \
|
|
|
|
purge=false, \
|
|
|
|
preload=false, \
|
2017-10-13 19:32:16 +00:00
|
|
|
shared=true, \
|
|
|
|
remote-servers=["remote-cache"], \
|
|
|
|
cache=offlineSessions, \
|
|
|
|
properties={ \
|
|
|
|
rawValues=true, \
|
|
|
|
marshaller=org.keycloak.cluster.infinispan.KeycloakHotRodMarshallerFactory \
|
2017-09-21 13:01:01 +00:00
|
|
|
} \
|
|
|
|
)
|
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=offlineSessions:write-attribute(name=statistics-enabled,value=true)
|
|
|
|
|
|
|
|
echo ** Update distributed-cache loginFailures element **
|
2017-10-13 19:32:16 +00:00
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=loginFailures/store=remote:add( \
|
2017-09-21 13:01:01 +00:00
|
|
|
passivation=false, \
|
|
|
|
fetch-state=false, \
|
|
|
|
purge=false, \
|
|
|
|
preload=false, \
|
2017-10-13 19:32:16 +00:00
|
|
|
shared=true, \
|
|
|
|
remote-servers=["remote-cache"], \
|
|
|
|
cache=loginFailures, \
|
|
|
|
properties={ \
|
|
|
|
rawValues=true, \
|
|
|
|
marshaller=org.keycloak.cluster.infinispan.KeycloakHotRodMarshallerFactory \
|
2017-09-21 13:01:01 +00:00
|
|
|
} \
|
|
|
|
)
|
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=loginFailures:write-attribute(name=statistics-enabled,value=true)
|
|
|
|
|
|
|
|
echo ** Update distributed-cache actionTokens element **
|
2017-10-13 19:32:16 +00:00
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=actionTokens/store=remote:add( \
|
2017-09-21 13:01:01 +00:00
|
|
|
passivation=false, \
|
|
|
|
fetch-state=false, \
|
|
|
|
purge=false, \
|
2017-10-13 19:32:16 +00:00
|
|
|
preload=false, \
|
|
|
|
shared=true, \
|
|
|
|
cache=actionTokens, \
|
|
|
|
remote-servers=["remote-cache"], \
|
|
|
|
properties={ \
|
|
|
|
rawValues=true, \
|
|
|
|
marshaller=org.keycloak.cluster.infinispan.KeycloakHotRodMarshallerFactory \
|
2017-09-21 13:01:01 +00:00
|
|
|
} \
|
|
|
|
)
|
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=actionTokens:write-attribute(name=statistics-enabled,value=true)
|
|
|
|
|
|
|
|
echo ** Update distributed-cache authenticationSessions element **
|
|
|
|
/subsystem=infinispan/cache-container=keycloak/distributed-cache=authenticationSessions:write-attribute(name=statistics-enabled,value=true)
|
|
|
|
|
|
|
|
echo *** Enable debug logging ***
|
|
|
|
/subsystem=logging/logger=org.keycloak.cluster.infinispan:add(level=DEBUG)
|
|
|
|
|
|
|
|
/subsystem=logging/logger=org.keycloak.connections.infinispan:add(level=DEBUG)
|
|
|
|
|
|
|
|
/subsystem=logging/logger=org.keycloak.models.cache.infinispan:add(level=DEBUG)
|
|
|
|
|
|
|
|
/subsystem=logging/logger=org.keycloak.models.sessions.infinispan:add(level=DEBUG)
|
|
|
|
|
|
|
|
echo *** Update undertow subsystem ***
|
|
|
|
/subsystem=undertow/server=default-server/http-listener=default:write-attribute(name=proxy-address-forwarding,value=true)
|
|
|
|
|
|
|
|
echo **** End ****
|