summaryrefslogtreecommitdiffstats
path: root/performanceTests/Makefile
diff options
context:
space:
mode:
authorpawel <pawel.kasperkiewicz@nokia.com>2020-06-01 14:23:03 +0200
committerPawel <pawel.kasperkiewicz@nokia.com>2020-06-01 14:23:31 +0200
commit36e09e63f779b5ebec4391f1a444ef214850e2fe (patch)
treeab7144ec266732f0490d2259871a29011867244f /performanceTests/Makefile
parentd5c7cf6980a4e017324dde4cd041ba9496d67bf8 (diff)
Add JMeter to performance tests environment
Add influxdb as datasource, add JMeter with example test scenario Issue-ID: DCAEGEN2-608 Signed-off-by: Pawel <pawel.kasperkiewicz@nokia.com> Change-Id: I55656588d8c1f6f373fd3d04a52f39834a396c81
Diffstat (limited to 'performanceTests/Makefile')
-rw-r--r--performanceTests/Makefile23
1 files changed, 21 insertions, 2 deletions
diff --git a/performanceTests/Makefile b/performanceTests/Makefile
index 5583a613..30a3d2ea 100644
--- a/performanceTests/Makefile
+++ b/performanceTests/Makefile
@@ -1,10 +1,14 @@
-all: copy-performanceTests run-performanceTests
+all: copy-performanceTests run-performanceTests copy-jmeter
RKE_NODE_USER_AND_HOSTNAME = <RKE_USER>@<RKE_IP> # for example ubuntu@10.183.36.205
RKE_PRIVATE_KEY = <PEM_PRIVATE_KEY_FILE_PATH> # for example ~/.ssh/onap-5802.pem
PERFORMANCE_TESTS_DIRECTORY = vesPerformanceTestsEnv
-RKE_KUBECONFIG_FILE_PATH = <KUBECONFIG_FILE_PATH_ON_RKE> # for example /home/ubuntu/.kube/config.onap
+RKE_KUBECONFIG_FILE_PATH = /home/ubuntu/.kube/config.onap
+
+#Configuration for jMeter
+JMETER_VM_USER_AND_HOSTNAME = <RKE_USER>@<VM_IP> # for example root@10.183.36.50
+JMETER_VM_PRIVATE_KEY = <PEM_PRIVATE_KEY_FILE_PATH> # for example ~/.ssh/onap-5802.pem
copy-performanceTests:
@echo "\n##### Copy performance tests directory to lab environment #####"
@@ -24,4 +28,19 @@ clear-performanceTests:
remove-performanceTests:
@echo "\n##### Remove performance tests #####"
ssh -i $(RKE_PRIVATE_KEY) $(RKE_NODE_USER_AND_HOSTNAME) 'bash -c "export KUBECONFIG=$(RKE_KUBECONFIG_FILE_PATH) && rm -rf $(PERFORMANCE_TESTS_DIRECTORY)"'
+ @echo "##### DONE #####"
+
+copy-jmeter:
+ @echo "\n##### Copy JMeter #####"
+ scp -r -i $(JMETER_VM_PRIVATE_KEY) ./k8s/testScenario $(JMETER_VM_USER_AND_HOSTNAME):$(PERFORMANCE_TESTS_DIRECTORY)
+ @echo "##### DONE #####"
+
+run-jmeter:
+ @echo "\n##### Run test scenario #####"
+ ssh -i $(JMETER_VM_PRIVATE_KEY) $(JMETER_VM_USER_AND_HOSTNAME) '/bin/bash ./$(PERFORMANCE_TESTS_DIRECTORY)/run_jmeter.sh'
+ @echo "##### DONE #####"
+
+remove-jmeter:
+ @echo "\n##### Remove JMeter #####"
+ ssh -i $(JMETER_VM_PRIVATE_KEY) $(JMETER_VM_USER_AND_HOSTNAME) 'rm -rf $(PERFORMANCE_TESTS_DIRECTORY)'
@echo "##### DONE #####" \ No newline at end of file