Skip to content

Commit

Permalink
Simplify cluster config
Browse files Browse the repository at this point in the history
Simplify how the cluster config is setup using ccm.

Pass an absolute path for the keystore, fixes apache#345
  • Loading branch information
Zariel committed Apr 7, 2015
1 parent e9eb915 commit 4ba6bba
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion integration.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,30 @@ function run_tests() {
local clusterSize=3
local version=$1

local keypath="$(pwd)/testdata/pki"

local conf=(
"client_encryption_options.enabled: true"
"client_encryption_options.keystore: $keypath/.keystore"
"client_encryption_options.keystore_password: cassandra"
"client_encryption_options.require_client_auth: true"
"client_encryption_options.truststore: $keypath/.truststore"
"client_encryption_options.truststore_password: cassandra"
"concurrent_reads: 2"
"concurrent_writes: 2"
"rpc_server_type: sync"
"rpc_min_threads: 2"
"rpc_max_threads: 2"
"write_request_timeout_in_ms: 5000"
"read_request_timeout_in_ms: 5000"
)

ccm create test -v binary:$version -n $clusterSize -d --vnodes
ccm updateconf "${conf[@]}"

sed -i '/#MAX_HEAP_SIZE/c\MAX_HEAP_SIZE="256M"' ~/.ccm/repository/$version/conf/cassandra-env.sh
sed -i '/#HEAP_NEWSIZE/c\HEAP_NEWSIZE="100M"' ~/.ccm/repository/$version/conf/cassandra-env.sh

ccm updateconf 'client_encryption_options.enabled: true' 'client_encryption_options.keystore: testdata/pki/.keystore' 'client_encryption_options.keystore_password: cassandra' 'client_encryption_options.require_client_auth: true' 'client_encryption_options.truststore: testdata/pki/.truststore' 'client_encryption_options.truststore_password: cassandra' 'concurrent_reads: 2' 'concurrent_writes: 2' 'rpc_server_type: sync' 'rpc_min_threads: 2' 'rpc_max_threads: 2' 'write_request_timeout_in_ms: 5000' 'read_request_timeout_in_ms: 5000'
ccm start -v
ccm status
ccm node1 nodetool status
Expand Down

0 comments on commit 4ba6bba

Please sign in to comment.