Created
November 7, 2016 23:18
-
-
Save kjorg50/4c15c5676729792d3d69677d44935bb8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# ignore the 'tempest' projects and users since those are created by chef | |
for i in server image domain role network subnet volume keypair; do | |
echo = cleaning $i list = | |
for j in $(openstack $i list | grep tempest | awk '{print $2}'); do | |
if [ $i = 'domain' ]; then | |
openstack $i set --disable $j && openstack $i delete $j | |
else | |
openstack $i delete $j | |
fi | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment