--- # Copyright 2017, Rackspace US, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. - name: Playbook for deploying upgrade benchmarking hosts: localhost user: root tasks: - name: Install locust pip: name: "{{ item }}" with_items: - locustio - pyzmq - name: Drop benchmarking config files template: src: "{{ item.src }}" dest: "{{ item.dest }}" owner: "root" group: "root" mode: "0644" with_items: - { src: "auth.json" , dest: "/opt/auth.json" } - { src: "locustfile.py" , dest: "/opt/locustfile.py" } - name: Run locust command: locust -f /opt/locustfile.py --no-web --clients=1 --only-summary --host={{ keystone_service_publicuri }} --logfile=/var/log/locust.log async: 1000 poll: 0 register: locust_benchmark vars_files: - common/test-vars.yml