Document how to run Shaker on Kubernetes against FuelCCP OpenStack

Change-Id: I625f8afca29c20b743996d30f69c79bb14e4565a
This commit is contained in:
Ilya Shakhat 2016-12-12 16:37:44 +04:00
parent be09a65029
commit 2dc97a6804
3 changed files with 78 additions and 0 deletions

@ -114,3 +114,30 @@ Non-OpenStack Deployment (aka Spot mode)
To run scenarios against remote nodes (``shaker-spot`` command) install shaker on the local host.
Make sure all necessary system tools are installed too. See :ref:`spot_scenarios` for more details.
Run Shaker against OpenStack deployed by Fuel-CCP on Kubernetes
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Shaker can be run in Kubernetes environment and can execute scenarios against
OpenStack deployed by Fuel-CCP tool.
Shaker app consists of *service*:
.. literalinclude:: k8s/shaker-svc.yaml
:language: yaml
and *pod*:
.. literalinclude:: k8s/shaker-pod.yaml
:language: yaml
You may need to change values for variables defined in config files:
* `SHAKER_SERVER_ENDPOINT` should point to external address of Kubernetes cluster,
and OpenStack instances must have access to it
* `OS_***` parameters describe connection to Keystone endpoint
* `SHAKER_SCENARIO` needs to be altered to run the needed scenario
* Pod is configured to write logs into /tmp on the node that hosts the pod
* `port`, `nodePort` and `targetPort` must be equal and not to conflict with
other exposed services

@ -0,0 +1,38 @@
apiVersion: v1
kind: Pod
metadata:
name: shaker
labels:
app: shaker
spec:
containers:
- args:
- --debug
- --nocleanup
env:
- name: OS_USERNAME
value: admin
- name: OS_PASSWORD
value: password
- name: OS_PROJECT_NAME
value: admin
- name: OS_AUTH_URL
value: http://keystone.ccp:5000/
- name: SHAKER_SCENARIO
value: openstack/perf_l2
- name: SHAKER_SERVER_ENDPOINT
value: 172.20.9.7:31999
image: shakhat/shaker
imagePullPolicy: Always
name: shaker
securityContext:
privileged: false
volumeMounts:
- mountPath: /artifacts
name: artifacts
dnsPolicy: ClusterFirst
restartPolicy: Never
volumes:
- name: artifacts
hostPath:
path: /tmp

@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: shaker
spec:
ports:
- nodePort: 31999
port: 31999
protocol: TCP
targetPort: 31999
selector:
app: shaker
type: NodePort