Simple hard coded Gemfire SecurityManager implementation
username = admin password = xyz1234
- Clone the project and build it using mvn
mvn clean package
- Create a directory for the jar
mkdir /opt/security-manager
- Copy target/gemfire-security-manager-0.1.0-SNAPSHOT.jar to the created directory
cp target/gemfire-security-manager-0.1.0-SNAPSHOT.jar /opt/security-manager
- Change to the gemfire installation root
cd /opt/pivotal-gemfire-9.10.5
- Add gemfire bin to path
export PATH=$PATH:/opt/pivotal-gemfire-9.10.5/bin
- Launch the gfsh shell
gfsh
- Start the locator
gfsh> start locator --name=locator1 \
--J=-Dgemfire.security-manager=com.github.dhoard.SimpleSecurityManager \
--classpath=/opt/security-manager/gemfire-security-manager-0.1.0-SNAPSHOT.jar
- Start the server
gfsh> start server --name=server1 \
--locators=gemfire.address.cx[10334] --server-port=40411 \
--J=-Dgemfire.security-manager=com.github.dhoard.SimpleSecurityManager \
--classpath=/opt/security-manager/gemfire-security-manager-0.1.0-SNAPSHOT.jar \
--user=admin --password=xyz1234
- Connect
gfsh> connect --locator=gemfire.address.cx[10334] \
--user=admin --password=xyz1234
- List members
gfsh> list members
Example output...
Member Count : 2
Name | Id
-------- | ------------------------------------------------------------------
locator1 | 192.168.100.173(locator1:9670:locator)<ec><v0>:41000 [Coordinator]
server1 | 192.168.100.173(server1:10139)<v1>:41001
- Query the region to check for data
gfsh> query --query="select * from /check"
Example output...
Result : true
Limit : 100
Rows : 1
Result
-----------------------------------------------
test-value-9564bbcd-11d3-450a-9b22-6b18b40ac7a9