diff --git a/k6/README.md b/k6/README.md index 3b6827cd..420b01b3 100644 --- a/k6/README.md +++ b/k6/README.md @@ -61,16 +61,20 @@ This will create the image and host it. Each time you change the test code of co Next create the k6-config file in the namespace from which you want to run the tests: ``` -oc create -n configmap k6-config --from-file=./src/config/config.json +make config NAMESPACE="" ``` Lastly deploy the config from the `sso-keycloak/k6/k6-runner/openshift/k6` directory. ``` -oc -n process -f dc.yaml | oc -n apply -f - +make run_job NAMESPACE="" ``` Be sure to delete the job when done to prevent the load test from re-running in the cluster. +``` +make delete NAMESPACE="" +``` + #### Running the test locally without docker. The tests can also be run without docker, by running: diff --git a/k6/k6-runner/src/tests/helpers.js b/k6/k6-runner/src/tests/helpers.js index 377235b9..34508451 100644 --- a/k6/k6-runner/src/tests/helpers.js +++ b/k6/k6-runner/src/tests/helpers.js @@ -91,7 +91,12 @@ function generateRealms(count) { newRealm.id = `newrealm-${i}`; newRealm.realm = `newrealm-${i}`; newRealm.displayName = `New Realm ${i}`; + // When testing different hashing algorythms we deploy new realms with this type of config: + // newRealm.passwordPolicy = "hashAlgorithm(pbkdf2-sha256) and hashIterations(27500)"; + // The default hash iterations are 210000 and pbkdf2-sha512 + // newRealm.passwordPolicy = "hashIterations(210000) and hashAlgorithm(pbkdf2-sha512)"; realms.push(newRealm); + } return realms; }