This PS adds support for kolla 4.x containers to implement the
centos-binary-4-ceph-multi-nv gate.

Change-Id: I98917ebe58b010aff39d7d9539cb2a7cdbd460ac
This commit is contained in:
Kevin Fox 2017-04-07 11:21:21 -07:00
parent b314a187c0
commit 23e022f33b
14 changed files with 68 additions and 12 deletions

View File

@ -159,7 +159,7 @@ connection_uri = "qemu+tcp://{{ api_interface_address }}/system"
images_type = rbd
images_rbd_pool = {{ ceph_nova_pool_name }}
images_rbd_ceph_conf = /etc/ceph/ceph.conf
rbd_user = nova
rbd_user = cinder
disk_cachemodes="network=writeback"
{% if nova_hw_disk_discard != '' %}
hw_disk_discard = {{ nova_hw_disk_discard }}

View File

@ -0,0 +1,13 @@
name: nova-cell0-delete-db-job
version: 0.7.0-1
description: nova job to delete db for cell0
keywords:
- openstack
- nova
- cell0
- db
- delete
sources:
- http://github.com/openstack
engine: gotpl
#icon: A URL to an SVG or PNG image to be used as an icon (optional). make this point to the new project icons when ready

View File

@ -0,0 +1,4 @@
dependencies:
- name: kolla-common
repository: file://../../kolla-common
version: 0.7.0-1

View File

@ -0,0 +1,7 @@
{{- $searchPath := ":global.kolla.nova.cell0.delete_db.job:global.kolla.nova.cell0.delete_db.all:global.kolla.nova.cell0.all:global.kolla.nova.all:global.kolla.all" }}
{{- $resourceName := "nova-cell0" }}
{{- $serviceName := "nova" }}
{{- $podTypeBootstrap := true }}
{{- with $env := dict "resourceName" $resourceName "serviceName" $serviceName "podTypeBootstrap" $podTypeBootstrap "Values" .Values "Release" .Release "searchPath" $searchPath }}
{{- include "common_delete_db_job" $env }}
{{- end }}

View File

@ -5,6 +5,9 @@ dependencies:
- name: nova-api-delete-db-job
repository: file://../../microservice/nova-api-delete-db-job
version: 0.7.0-1
- name: nova-cell0-delete-db-job
repository: file://../../microservice/nova-cell0-delete-db-job
version: 0.7.0-1
- name: nova-delete-keystone-service-job
repository: file://../../microservice/nova-delete-keystone-service-job
version: 0.7.0-1

View File

@ -29,8 +29,8 @@ spec:
{%- endif %}
{%- if enable_ceph == "yes" %}
mkdir -p /nova/secrets/;
cp -a /secret/a/..data/data /nova/secrets/{{ rbd_secret_uuid }}.xml;
cp -a /secret/b/..data/data /nova/secrets/{{ rbd_secret_uuid }}.base64;
cp -a /secret/a/..data/data /nova/secrets/{{ cinder_rbd_secret_uuid }}.xml;
cp -a /secret/b/..data/data /nova/secrets/{{ cinder_rbd_secret_uuid }}.base64;
cp -a /config2/..data/ceph.conf /nova;
{%- endif %}
"],

View File

@ -1,8 +1,8 @@
{%- macro secret() -%}
<secret ephemeral='no' private='no'>
<uuid>{{ rbd_secret_uuid }}</uuid>
<uuid>{{ cinder_rbd_secret_uuid }}</uuid>
<usage type='ceph'>
<name>client.nova secret</name>
<name>client.cinder secret</name>
</usage>
</secret>
{%- endmacro %}

View File

@ -518,6 +518,21 @@ helm install kolla/nova-compute-daemonset --version $VERSION \
$DIR/tools/pull_containers.sh kolla
$DIR/tools/wait_for_pods.sh kolla
if [ "x$branch" != "x2" -a "x$branch" != "x3" ]; then
helm install kolla/nova-cell0-create-db-job --debug --version $VERSION \
--namespace kolla --name nova-cell0-create-db-job \
--values /tmp/general_config.yaml --values /tmp/ceph_config.yaml
$DIR/tools/wait_for_pods.sh kolla
helm install kolla/nova-api-create-simple-cell-job --debug --version $VERSION \
--namespace kolla --name nova-api-create-simple-cell-job \
--values /tmp/general_config.yaml --values /tmp/ceph_config.yaml
fi
$DIR/tools/pull_containers.sh kolla
$DIR/tools/wait_for_pods.sh kolla
#
# Brining up br-ex so keepalived could bind VIP to it
#

View File

@ -22,6 +22,8 @@ fi
user='root'
password=$(python -c 'import yaml; print yaml.safe_load(open("/etc/kolla/passwords.yml"))["database_password"]')
if [ $(kubectl exec mariadb-0 -n kolla -- mysql --user=$user --password=$password -e 'show databases;' | grep $1 | wc -l) -ne 0 ]; then
echo found:
kubectl exec mariadb-0 -n kolla -- mysql --user=$user --password=$password -e 'show databases;' | grep $1
exit -1
fi
}

View File

@ -116,6 +116,13 @@ kubectl get clusterroles -o yaml > $WORKSPACE/logs/rbac/clusterroles.yaml
kubectl get roles -o yaml > $WORKSPACE/logs/rbac/roles.yaml
kubectl get clusterrolebindings -o yaml > $WORKSPACE/logs/rbac/clusterrolebindings.yaml
kubectl get rolebindings -o yaml > $WORKSPACE/logs/rbac/rolebindings.yaml
timeout 6s nova service-list > $WORKSPACE/logs/nova-service-list.txt
timeout 6s neutron agent-list > $WORKSPACE/logs/neutron-agent-list.txt
cat /etc/nodepool/sub_nodes_private | while read line; do
ssh $line sudo iptables-save > $WORKSPACE/logs/iptables-$line-end.txt
ssh $line sudo route -n > $WORKSPACE/logs/routes-$line-end.txt
done
#
# Check power status and status of vbmc

View File

@ -43,8 +43,7 @@ ls -la /etc/kolla
crudini --set /etc/kolla/nova-compute/nova.conf libvirt virt_type qemu
crudini --set /etc/kolla/nova-compute/nova.conf libvirt cpu_mode none
crudini --set /etc/kolla/nova-compute/nova.conf libvirt rbd_user nova
UUID=$(awk '{if($1 == "rbd_secret_uuid:"){print $2}}' /etc/kolla/passwords.yml)
UUID=$(awk '{if($1 == "cinder_rbd_secret_uuid:"){print $2}}' /etc/kolla/passwords.yml)
crudini --set /etc/kolla/nova-compute/nova.conf libvirt rbd_secret_uuid $UUID
# Keystone does not seem to invalidate its cache on entry point addition.

View File

@ -21,8 +21,13 @@ if [ "x$BRANCH" == "xt" ]; then
fi
if [ "x$BRANCH" == "x3" ]; then
sed -i 's/2\.0\.2/3.0.2/g' helm/all_values.yaml
sed -i 's/2\.0\.2/3.0.2/g' tests/conf/ceph-all-in-one/kolla_config
sed -i 's/2\.0\.2/3.0.3/g' helm/all_values.yaml
sed -i 's/2\.0\.2/3.0.3/g' tests/conf/ceph-all-in-one/kolla_config
fi
if [ "x$BRANCH" == "x4" ]; then
sed -i 's/2\.0\.2/4.0.0/g' helm/all_values.yaml
sed -i 's/2\.0\.2/4.0.0/g' tests/conf/ceph-all-in-one/kolla_config
fi
if [ "x$4" == "xiscsi" ]; then

View File

@ -72,6 +72,7 @@ pip install pip --upgrade
pip install "ansible<2.1"
pip install "python-cinderclient==1.11.0"
pip install "python-openstackclient"
pip install "python-novaclient"
pip install "python-neutronclient"
pip install "selenium"
pip install -r requirements.txt

View File

@ -13,6 +13,9 @@ kubectl exec ceph-admin -c main --namespace=kolla -- /bin/bash -c \
"$str" > /tmp/$$
kubectl create secret generic ceph-client-cinder-keyring --namespace=kolla\
--from-file=ceph.client.cinder.keyring=/tmp/$$
kubectl create secret generic nova-libvirt-bin --namespace=kolla \
--from-file=data=<(awk '{if($1 == "key"){print $3}}' /tmp/$$ |
tr -d '\n')
str="ceph auth get-or-create client.nova mon 'allow r' osd 'allow "
str="$str class-read object_prefix rbd_children, allow rwx pool=volumes, "
@ -21,9 +24,6 @@ kubectl exec ceph-admin -c main --namespace=kolla -- /bin/bash -c \
"$str" > /tmp/$$
kubectl create secret generic ceph-client-nova-keyring --namespace=kolla \
--from-file=ceph.client.nova.keyring=/tmp/$$
kubectl create secret generic nova-libvirt-bin --namespace=kolla \
--from-file=data=<(awk '{if($1 == "key"){print $3}}' /tmp/$$ |
tr -d '\n')
str="ceph auth get-or-create client.kolla mon 'allow r' osd 'allow"
str="$str class-read object_prefix rbd_children, allow rwx pool=kollavolumes'"