update start/stop scripts

- use new yaml config files
- provide separate service- and pod- start/stop scripts

Change-Id: Iaff2a5b4d5a33467a9d10b10e9bd5c922eeed3aa
This commit is contained in:
Lars Kellogg-Stedman 2014-10-09 17:08:18 -04:00
parent dd16b95aa6
commit 6ccd3a9b44
6 changed files with 55 additions and 10 deletions

View File

@ -1,6 +1,6 @@
kubecfg -c ../k8s/service/mariadb-service.json create services #!/bin/sh
kubecfg -c ../k8s/service/keystone-public-service.json create services
kubecfg -c ../k8s/service/keystone-admin-service.json create services
kubecfg -c ../k8s/pod/mariadb-pod.json create pods cd $(git rev-parse --show-toplevel)
kubecfg -c ../k8s/pod/keystone-pod.json create pods
./tools/start-all-services
./tools/start-all-pods

15
tools/start-all-pods Executable file
View File

@ -0,0 +1,15 @@
#!/bin/sh
cd $(git rev-parse --show-toplevel)
pods='
rabbitmq
mariadb
keystone
glance
'
for pod in $pods; do
kubecfg -c "k8s/pod/${pod}-pod.yaml" create pods
done

17
tools/start-all-services Executable file
View File

@ -0,0 +1,17 @@
#!/bin/sh
cd $(git rev-parse --show-toplevel)
services='
glance-api
glance-registry
keystone-admin
keystone-public
mariadb
rabbitmq
'
for svc in $services; do
kubecfg -c "k8s/service/${svc}-service.yaml" create services
done

View File

@ -1,6 +1,7 @@
kubecfg delete /pods/mariadb #!/bin/sh
kubecfg delete /pods/keystone
cd $(git rev-parse --show-toplevel)
./tools/stop-all-pods
./tools/stop-all-services
kubecfg delete /services/mariadb
kubecfg delete /services/keystone-public
kubecfg delete /services/keystone-admin

6
tools/stop-all-pods Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
kubecfg list pods |
awk 'NR>2 {print $1}' |
xargs -i kubecfg delete pods/{}

6
tools/stop-all-services Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
kubecfg list services |
awk 'NR>2 {print $1}' |
xargs -i kubecfg delete services/{}