openstack tempest cleanup
#!/bin/bash
# cleanup tempest
neutron port-list --all-tenants | grep tempest | awk '{print $2}' | xargs -i neutron port-delete {}
neutron subnet-list --all-tenants | grep tempest | awk '{print $2}' | xargs -i neutron subnet-delete {}
neutron subnet-list --all-tenants | grep "100.FIXME" | awk '{print $2}' | xargs -i neutron subnet-delete {}
neutron net-list --all-tenants | grep tempest | awk '{print $2}' | xargs -i neutron net-delete {}
neutron net-list --all-tenants | grep snat-si-left_snat_ | awk '{print $2}' | xargs -i neutron net-delete {}
neutron security-group-list --all-tenants | grep tempest | awk '{print $2}' | xargs -i neutron security-group-delete {}
neutron router-list --all-tenants | grep tempest | awk '{print $2}' | xargs -i neutron router-delete {}
keystone user-list | grep tempest | awk '{print $2}' | xargs -i keystone user-delete {}
keystone tenant-list | grep tempest | awk '{print $2}' | xargs -i keystone tenant-delete {}
glance image-list | grep tempest | awk '{print $2}' | xargs -i glance image-delete {}