...
 
Commits (27)
This diff is collapsed.
--- /usr/share/openstack-dashboard/openstack_dashboard/dashboards/project/static/dashboard/project/workflow/launch-instance/launch-instance-model.service.js~ 2019-04-10 06:19:10.000000000 -0600
+++ /usr/share/openstack-dashboard/openstack_dashboard/dashboards/project/static/dashboard/project/workflow/launch-instance/launch-instance-model.service.js 2019-05-13 10:48:55.193282728 -0600
@@ -201,7 +201,7 @@
// REQUIRED for JS logic (image | snapshot | volume | volume_snapshot)
source_type: null,
source: [],
- create_volume_default: true,
+ create_volume_default: false,
// REQUIRED for JS logic
hide_create_volume: false,
vol_create: false,
--- /usr/lib/python2.7/dist-packages/manila/network/neutron/api.py.orig 2018-02-28 04:27:48.000000000 -0700
+++ /usr/lib/python2.7/dist-packages/manila/network/neutron/api.py 2018-06-21 10:56:50.807123424 -0600
@@ -172,14 +172,14 @@
def create_port(self, tenant_id, network_id, host_id=None, subnet_id=None,
fixed_ip=None, device_owner=None, device_id=None,
- mac_address=None, port_security_enabled=True,
+ mac_address=None, port_security_enabled=False,
security_group_ids=None, dhcp_opts=None, **kwargs):
try:
port_req_body = {'port': {}}
port_req_body['port']['network_id'] = network_id
port_req_body['port']['admin_state_up'] = True
port_req_body['port']['tenant_id'] = tenant_id
- if not port_security_enabled:
+ if port_security_enabled:
port_req_body['port']['port_security_enabled'] = (
port_security_enabled)
elif security_group_ids:
--- /usr/lib/python3/dist-packages/manila/network/neutron/api.py.orig 2018-02-28 04:27:48.000000000 -0700
+++ /usr/lib/python3/dist-packages/manila/network/neutron/api.py 2018-06-21 10:56:50.807123424 -0600
@@ -172,14 +172,14 @@
def create_port(self, tenant_id, network_id, host_id=None, subnet_id=None,
fixed_ip=None, device_owner=None, device_id=None,
- mac_address=None, port_security_enabled=True,
+ mac_address=None, port_security_enabled=False,
security_group_ids=None, dhcp_opts=None, **kwargs):
try:
port_req_body = {'port': {}}
port_req_body['port']['network_id'] = network_id
port_req_body['port']['admin_state_up'] = True
port_req_body['port']['tenant_id'] = tenant_id
- if not port_security_enabled:
+ if port_security_enabled:
port_req_body['port']['port_security_enabled'] = (
port_security_enabled)
elif security_group_ids:
--- /usr/lib/python3/dist-packages/neutron/plugins/ml2/drivers/openvswitch/agent/openflow/native/ofswitch.py~ 2019-04-10 06:22:36.000000000 -0600
+++ /usr/lib/python3/dist-packages/neutron/plugins/ml2/drivers/openvswitch/agent/openflow/native/ofswitch.py 2019-05-13 10:41:57.517394653 -0600
@@ -127,31 +127,42 @@
if table_id is None:
table_id = ofp.OFPTT_ALL
+ cookie_masks = []
if cookie == ovs_lib.COOKIE_ANY:
cookie = 0
if cookie_mask != 0:
raise Exception(_("cookie=COOKIE_ANY but cookie_mask set to "
"%s") %
cookie_mask)
+ cookies = set([f.cookie for f in self.dump_flows()]) - \
+ self.preserved_cookies
+ LOG.warning("Preserved cookies for %s: %s", self.br_name,
+ self.preserved_cookies)
+ for c in cookies:
+ cookie_masks.append((c,ovs_lib.UINT64_BITMASK))
elif cookie == COOKIE_DEFAULT:
- cookie = self._default_cookie
- cookie_mask = ovs_lib.UINT64_BITMASK
+ cookie_masks.append((self._default_cookie,ovs_lib.UINT64_BITMASK))
+ elif cookie in self.preserved_cookies:
+ return
- match = self._match(ofp, ofpp, match, **match_kwargs)
- if strict:
- cmd = ofp.OFPFC_DELETE_STRICT
- else:
- cmd = ofp.OFPFC_DELETE
- msg = ofpp.OFPFlowMod(dp,
- command=cmd,
- cookie=cookie,
- cookie_mask=cookie_mask,
- table_id=table_id,
- match=match,
- priority=priority,
- out_group=ofp.OFPG_ANY,
- out_port=ofp.OFPP_ANY)
- self._send_msg(msg, active_bundle=active_bundle)
+ for (_cookie,_mask) in cookie_masks:
+ match = self._match(ofp, ofpp, match, **match_kwargs)
+ if strict:
+ cmd = ofp.OFPFC_DELETE_STRICT
+ else:
+ cmd = ofp.OFPFC_DELETE
+ LOG.warning("Deleting flow with cookie 0x%(cookie)x",
+ {'cookie': _cookie})
+ msg = ofpp.OFPFlowMod(dp,
+ command=cmd,
+ cookie=_cookie,
+ cookie_mask=_mask,
+ table_id=table_id,
+ match=match,
+ priority=priority,
+ out_group=ofp.OFPG_ANY,
+ out_port=ofp.OFPP_ANY)
+ self._send_msg(msg, active_bundle=active_bundle)
def dump_flows(self, table_id=None):
(dp, ofp, ofpp) = self._get_dp()
--- /usr/lib/python3/dist-packages/neutron/plugins/ml2/drivers/openvswitch/agent/openflow/br_cookie.py~ 2018-11-05 23:12:44.000000000 -0700
+++ /usr/lib/python3/dist-packages/neutron/plugins/ml2/drivers/openvswitch/agent/openflow/br_cookie.py 2019-05-06 13:39:15.599229212 -0600
@@ -17,6 +17,8 @@
from neutron.agent.common import ovs_lib
+import os
+import os.path
class OVSBridgeCookieMixin(object):
'''Mixin to provide cookie retention functionality
@@ -26,6 +28,26 @@
def __init__(self, *args, **kwargs):
super(OVSBridgeCookieMixin, self).__init__(*args, **kwargs)
self._reserved_cookies = set()
+ self._preserved_cookies = set()
+
+ if not os.path.exists("/var/lib/neutron/ovs-default-flows.reserved_cookie"):
+ sc = self.request_cookie()
+ self._preserved_cookies.add(sc)
+ self._reserved_cookies.add(sc)
+ f = open("/var/lib/neutron/ovs-default-flows.reserved_cookie",'w')
+ f.write(str(sc))
+ f.close()
+ else:
+ f = open("/var/lib/neutron/ovs-default-flows.reserved_cookie",'r')
+ sc = int(f.read())
+ f.close()
+ self._preserved_cookies.add(sc)
+ self._reserved_cookies.add(sc)
+ pass
+
+ @property
+ def preserved_cookies(self):
+ return set(self._preserved_cookies)
@property
def reserved_cookies(self):
--- /usr/lib/python3/dist-packages/nova/virt/libvirt/driver.py~ 2019-04-15 03:31:35.000000000 -0600
+++ /usr/lib/python3/dist-packages/nova/virt/libvirt/driver.py 2019-05-13 10:51:25.589247320 -0600
@@ -4671,7 +4671,8 @@
if (virt_type not in ("lxc", "uml", "parallels", "xen") or
(virt_type == "xen" and guest.os_type == fields.VMMode.HVM)):
- guest.features.append(vconfig.LibvirtConfigGuestFeatureACPI())
+ if caps.host.cpu.arch != 'aarch64' or guest.os_loader_type == "pflash":
+ guest.features.append(vconfig.LibvirtConfigGuestFeatureACPI())
guest.features.append(vconfig.LibvirtConfigGuestFeatureAPIC())
if (virt_type in ("qemu", "kvm") and
@@ -4916,7 +4917,7 @@
hw_firmware_type = image_meta.properties.get('hw_firmware_type')
if caps.host.cpu.arch == fields.Architecture.AARCH64:
if not hw_firmware_type:
- hw_firmware_type = fields.FirmwareType.UEFI
+ hw_firmware_type = fields.FirmwareType.BIOS
if hw_firmware_type == fields.FirmwareType.UEFI:
if self._has_uefi_support():
global uefi_logged
--- /usr/lib/python3/dist-packages/heat_dashboard/content/stacks/forms.py~ 2019-03-20 09:37:53.000000000 -0600
+++ /usr/lib/python3/dist-packages/heat_dashboard/content/stacks/forms.py 2019-06-12 12:57:26.893245322 -0600
@@ -204,7 +204,7 @@
LOG.info('got upload %s', log_template_name)
tpl = files[upload_str].read()
- if tpl.startswith('{'):
+ if tpl.startswith(six.b('{')):
try:
json.loads(tpl)
except Exception as e:
......@@ -30,17 +30,18 @@
#
#
import six
import sys
import pwd
import getopt
import os
import re
import xmlrpclib
from M2Crypto import X509
import os.path
dirname = os.path.abspath(os.path.dirname(sys.argv[0]))
execfile("%s/test-common.py" % (dirname,))
exec(open("%s/test-common.py" % (dirname,)).read())
myprint = six.print_
#
# Convert the certificate into a credential.
......@@ -58,7 +59,7 @@ if rval:
Fatal("Could not get manifests")
pass
if len(sys.argv) < 2:
print response["value"]
myprint(response["value"])
else:
f = open("%s.xml" % (sys.argv[1],),'w')
value = response["value"]["manifests"]
......
......@@ -35,8 +35,8 @@ pc = portal.Context()
# Define *many* parameters; see the help docs in geni-lib to learn how to modify.
#
pc.defineParameter("release","OpenStack Release",
portal.ParameterType.STRING,"rocky",[("rocky","Rocky"),("queens","Queens"),("pike","Pike"),("ocata","Ocata"),("newton","Newton"),("mitaka","Mitaka"),("liberty","Liberty (deprecated)"),("kilo","Kilo (deprecated)"),("juno","Juno (deprecated)")],
longDescription="We provide OpenStack Rocky, Queens (Ubuntu 18.04), Pike, Ocata, Newton, Mitaka (Ubuntu 16.04); Liberty (Ubuntu 15.10); Kilo (Ubuntu 15.04); or Juno (Ubuntu 14.10). OpenStack is installed from packages available on these distributions.")
portal.ParameterType.STRING,"stein",[("stein","Stein"),("rocky","Rocky"),("queens","Queens"),("pike","Pike"),("ocata","Ocata"),("newton","Newton"),("mitaka","Mitaka"),("liberty","Liberty (deprecated)"),("kilo","Kilo (deprecated)"),("juno","Juno (deprecated)")],
longDescription="We provide OpenStack Stein, Rocky, Queens (Ubuntu 18.04), Pike, Ocata, Newton, Mitaka (Ubuntu 16.04); Liberty (Ubuntu 15.10); Kilo (Ubuntu 15.04); or Juno (Ubuntu 14.10). OpenStack is installed from packages available on these distributions.")
pc.defineParameter("computeNodeCount", "Number of compute nodes (at Site 1)",
portal.ParameterType.INTEGER, 1)
pc.defineParameter("osNodeType", "Hardware Type",
......@@ -448,7 +448,7 @@ for param in pc._parameterOrder:
pass
tourDescription = \
"This profile provides a highly-configurable OpenStack instance with a controller and one or more compute nodes (potentially at multiple Cloudlab sites) (and optionally a network manager node, in a split configuration). This profile runs x86, arm64, and POWER8 (Queens and up) nodes. It sets up OpenStack Rocky, Queens (Ubuntu 18.04), Pike, Ocata, Newton, or Mitaka (Ubuntu 16.04) (Liberty on 15.10, Kilo on 15.04, and Juno on 14.10 are *deprecated*) according to your choice, and configures all OpenStack services, pulls in some VM disk images, and creates basic networks accessible via floating IPs. You'll be able to create instances and access them over the Internet in just a few minutes. When you click the Instantiate button, you'll be presented with a list of parameters that you can change to control what your OpenStack instance will look like; **carefully** read the parameter documentation on that page (or in the Instructions) to understand the various features available to you."
"This profile provides a highly-configurable OpenStack instance with a controller and one or more compute nodes (potentially at multiple Cloudlab sites) (and optionally a network manager node, in a split configuration). This profile runs x86, arm64, and POWER8 (Queens and up) nodes. It sets up OpenStack Stein, Rocky, Queens (Ubuntu 18.04), Pike, Ocata, Newton, or Mitaka (Ubuntu 16.04) (Liberty on 15.10, Kilo on 15.04, and Juno on 14.10 are *deprecated*) according to your choice, and configures all OpenStack services, pulls in some VM disk images, and creates basic networks accessible via floating IPs. You'll be able to create instances and access them over the Internet in just a few minutes. When you click the Instantiate button, you'll be presented with a list of parameters that you can change to control what your OpenStack instance will look like; **carefully** read the parameter documentation on that page (or in the Instructions) to understand the various features available to you."
###if not params.adminPass or len(params.adminPass) == 0:
passwdHelp = "Your OpenStack admin and instance VM password is randomly-generated by Cloudlab, and it is: `{password-adminPass}` ."
......@@ -458,7 +458,7 @@ passwdHelp = "Your OpenStack admin and instance VM password is randomly-generate
passwdHelp += " When logging in to the Dashboard, use the `admin` user; when logging into instance VMs, use the `ubuntu` user. If you have selected Mitaka or newer, use 'default' as the Domain at the login prompt."
grafanaInstructions = ""
if params.release in [ "pike","queens","rocky" ]:
if params.release in [ "pike","queens","rocky","stein" ]:
grafanaInstructions = "You can also login to [your experiment's Grafana WWW interface](http://{host-%s}:3000/dashboard/db/openstack-instance-statistics?orgId=1) and view OpenStack statistics once you've created some VMs." % (params.controllerHost)
tourInstructions = \
......@@ -649,6 +649,9 @@ elif params.release == 'queens':
elif params.release == 'rocky':
image_os = 'UBUNTU18-64'
image_tag_rel = '-R'
elif params.release == 'stein':
image_os = 'UBUNTU18-64'
image_tag_rel = '-S'
else:
image_os = 'UBUNTU16-64'
params.fromScratch = True
......@@ -664,7 +667,7 @@ if params.fromScratch:
else:
image_tag_cn = '-OSCN'
image_tag_nm = '-OSNM'
if params.release in [ 'rocky' ]:
if params.release in [ 'rocky','stein' ]:
# See above comment; we stopped generating OSNM images at Rocky
# for x86/aarch64; and at Queens for ppc64le.
image_tag_nm = '-STD'
......@@ -687,7 +690,7 @@ if params.osNodeType == 'ibm8335':
# for x86/aarch64; and at Queens for ppc64le.
image_tag_nm = ''
if params.release not in [ 'queens','rocky' ]:
if params.release not in [ 'queens','rocky','stein' ]:
perr = portal.ParameterError(
"You can only run the Queens release, or greater, on `ibm8335` (POWER8) hardware!",
['release','osNodeType'])
......
......@@ -31,7 +31,7 @@ fi
if [ $GENIUSER -eq 1 ] ; then
echo "*** Importing GENI user keys for admin user..."
$DIRNAME/setup-user-info.py
$PYTHONBINNAME $DIRNAME/setup-user-info.py
#
# XXX: ugh, this is ugly, but now that we have two admin users, we have
......@@ -57,7 +57,7 @@ if [ $GENIUSER -eq 1 ] ; then
# Ok, do it again!
echo "*** Importing GENI user keys, for ${ADMIN_API} user..."
$DIRNAME/setup-user-info.py
$PYTHONBINNAME $DIRNAME/setup-user-info.py
fi
logtend "basic-users"
......
......@@ -82,7 +82,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password "${CEILOMETER_PASS}"
else
crudini --set /etc/ceilometer/ceilometer.conf keystone_authtoken \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/ceilometer/ceilometer.conf keystone_authtoken \
auth_url http://${CONTROLLER}:${KADMINPORT}
if [ $OSVERSION -ge $OSMITAKA -o $KEYSTONEUSEMEMCACHE -eq 1 ]; then
......
......@@ -36,7 +36,7 @@ fi
# https://review.openstack.org/#/c/256267/
#
if [ $OSVERSION -ge $OSKILO ]; then
maybe_install_packages python-oslo.service
maybe_install_packages ${PYPKGPREFIX}-oslo.service
patch -d / -p0 < $DIRNAME/etc/oslo_service-liberty-sig-MAINLOOP.patch
fi
......@@ -194,7 +194,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password "${NOVA_PASS}"
else
crudini --set /etc/nova/nova.conf keystone_authtoken \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/nova/nova.conf keystone_authtoken \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/nova/nova.conf keystone_authtoken \
......
This diff is collapsed.
......@@ -209,18 +209,18 @@ fi
## Grab our geni creds, and create a GENI credential cert
##
#
# NB: force the install of python-m2crypto if geniuser
# NB: force the install of python-cryptography if geniuser
#
if [ $GENIUSER -eq 1 ]; then
dpkg -s python-m2crypto >/dev/null 2>&1
dpkg -s python-cryptography >/dev/null 2>&1
if [ ! $? -eq 0 ]; then
apt-get $DPKGOPTS install $APTGETINSTALLOPTS python-m2crypto
apt-get $DPKGOPTS install $APTGETINSTALLOPTS python-cryptography
# Keep trying again with updated cache forever;
# we must have this package.
success=$?
while [ ! $success -eq 0 ]; do
apt-get update
apt-get $DPKGOPTS install $APTGETINSTALLOPTS python-m2crypto
apt-get $DPKGOPTS install $APTGETINSTALLOPTS python-cryptography
success=$?
done
fi
......@@ -342,6 +342,7 @@ OSOCATA=15
OSPIKE=16
OSQUEENS=17
OSROCKY=18
OSSTEIN=19
. /etc/lsb-release
#
......@@ -358,6 +359,7 @@ if [ ! "x$OSRELEASE" = "x" ]; then
if [ $OSCODENAME = "pike" ]; then OSVERSION=$OSPIKE ; fi
if [ $OSCODENAME = "queens" ]; then OSVERSION=$OSQUEENS ; fi
if [ $OSCODENAME = "rocky" ]; then OSVERSION=$OSROCKY ; fi
if [ $OSCODENAME = "stein" ]; then OSVERSION=$OSSTEIN ; fi
#
# We only use cloudarchive for LTS images!
......@@ -394,6 +396,48 @@ else
REGION="RegionOne"
fi
#
# Stop using auth_uri in favor of www_authenticate_uri at Stein.
#
AUTH_URI_KEY="auth_uri"
if [ $OSVERSION -ge $OSSTEIN ]; then
AUTH_URI_KEY="www_authenticate_uri"
fi
#
# We started using Python 3 packages at Stein.
#
PYPKGPREFIX="python"
ISPYTHON3=0
PYTHONBINNAME="python"
if [ $OSVERSION -ge $OSSTEIN ]; then
PYPKGPREFIX="python3"
ISPYTHON3=1
PYTHONBINNAME="python3"
#
# If our openstack python libs will be python3, we also need
# python3-cryptography for setup-user-info.py, because that file
# must be run by whatever python version contains the novaclient
# library. And we don't know that we need that until here, unlike
# above where we install the v2 python-cryptography.
#
if [ $GENIUSER -eq 1 ]; then
dpkg -s python-cryptography >/dev/null 2>&1
if [ ! $? -eq 0 ]; then
apt-get $DPKGOPTS install $APTGETINSTALLOPTS ${PYTHONBINNAME}-cryptography
# Keep trying again with updated cache forever;
# we must have this package.
success=$?
while [ ! $success -eq 0 ]; do
apt-get update
apt-get $DPKGOPTS install $APTGETINSTALLOPTS ${PYTHONBINNAME}-cryptography
success=$?
done
fi
fi
fi
#
# See which keystone port has the admin capabilities. This changed in
# Queens to fully drop 35357 because it's now irrelevant and not
......
......@@ -99,7 +99,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password "${NEUTRON_PASS}"
else
crudini --set /etc/neutron/neutron.conf keystone_authtoken \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/neutron/neutron.conf keystone_authtoken \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/neutron/neutron.conf keystone_authtoken \
......@@ -139,7 +139,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password "${NOVA_PASS}"
else
crudini --set /etc/neutron/neutron.conf nova \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/neutron/neutron.conf nova \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/neutron/neutron.conf nova \
......@@ -233,6 +233,12 @@ if [ -n "$fwdriver" ]; then
firewall_driver $fwdriver
fi
if [ $OSVERSION -ge $OSROCKY ]; then
crudini --set /etc/neutron/neutron.conf oslo_concurrency \
lock_path /var/lib/neutron/lock
mkdir -p /var/lib/neutron/lock/
chown neutron:neutron /var/lib/neutron/lock
fi
#
# Ok, also put our FQDN into the hosts file so that local applications can
......
......@@ -99,7 +99,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password "${NEUTRON_PASS}"
else
crudini --set /etc/neutron/neutron.conf keystone_authtoken \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/neutron/neutron.conf keystone_authtoken \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/neutron/neutron.conf keystone_authtoken \
......@@ -239,6 +239,13 @@ if [ $OSVERSION -ge $OSLIBERTY -a $OSVERSION -lt $OSNEWTON ]; then
patch -d / -p0 < $DIRNAME/etc/neutron-liberty-ovs-agent-segmentation-id-None.patch
fi
if [ $OSVERSION -ge $OSROCKY ]; then
crudini --set /etc/neutron/neutron.conf oslo_concurrency \
lock_path /var/lib/neutron/lock
mkdir -p /var/lib/neutron/lock/
chown neutron:neutron /var/lib/neutron/lock
fi
#
# Neutron depends on bridge module, but it doesn't autoload it.
#
......
......@@ -42,7 +42,7 @@ $DIRNAME/setup-network-plugin.sh
# https://review.openstack.org/#/c/256267/
#
if [ $OSVERSION -ge $OSKILO ]; then
maybe_install_packages python-oslo.service
maybe_install_packages ${PYPKGPREFIX}-oslo.service
patch -d / -p0 < $DIRNAME/etc/oslo_service-liberty-sig-MAINLOOP.patch
fi
......@@ -127,7 +127,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password ${NEUTRON_PASS}
else
crudini --set /etc/neutron/metadata_agent.ini DEFAULT \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/neutron/metadata_agent.ini DEFAULT \
auth_url http://${CONTROLLER}:${KADMINPORT}/v2.0
crudini --set /etc/neutron/metadata_agent.ini DEFAULT \
......
......@@ -71,7 +71,7 @@ fi
crudini --set /etc/manila/manila.conf keystone_authtoken \
memcached_servers ${CONTROLLER}:11211
crudini --set /etc/manila/manila.conf keystone_authtoken \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/manila/manila.conf keystone_authtoken \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/manila/manila.conf keystone_authtoken \
......@@ -177,7 +177,7 @@ else
service_network_cidr 10.133.0.0/16
crudini --set /etc/manila/manila.conf nova \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/manila/manila.conf nova \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/manila/manila.conf nova \
......@@ -198,7 +198,7 @@ else
region_name $REGION
crudini --set /etc/manila/manila.conf cinder \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/manila/manila.conf cinder \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/manila/manila.conf cinder \
......@@ -221,7 +221,7 @@ else
crudini --set /etc/manila/manila.conf neutron \
url http://${CONTROLLER}:9696
crudini --set /etc/manila/manila.conf neutron \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/manila/manila.conf neutron \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/manila/manila.conf neutron \
......
......@@ -112,7 +112,7 @@ if [ $OSVERSION -lt $OSKILO ]; then
admin_password "${CINDER_PASS}"
else
crudini --set /etc/cinder/cinder.conf keystone_authtoken \
auth_uri http://${CONTROLLER}:5000
${AUTH_URI_KEY} http://${CONTROLLER}:5000
crudini --set /etc/cinder/cinder.conf keystone_authtoken \
auth_url http://${CONTROLLER}:${KADMINPORT}
crudini --set /etc/cinder/cinder.conf keystone_authtoken \
......
......@@ -15,13 +15,14 @@ import getopt
import os
import os.path
import re
import xmlrpclib
from M2Crypto import X509
import os.path
#import keystoneclient
#import novaclient
import traceback
import logging
import six
myprint = six.print_
LOG = logging.getLogger(__name__)
# Define a default handler at INFO logging level
......@@ -35,11 +36,11 @@ KEYSTONE_OPTS = [ 'OS_PROJECT_DOMAIN_ID','OS_USER_DOMAIN_ID',
'OS_USERNAME','OS_PASSWORD','OS_AUTH_URL' ]
#'OS_IDENTITY_API_VERSION'
execfile(CLOUDLAB_SETTINGS_FILE)
execfile(CLOUDLAB_AUTH_FILE)
exec(open(CLOUDLAB_SETTINGS_FILE).read())
exec(open(CLOUDLAB_AUTH_FILE).read())
dirname = os.path.abspath(os.path.dirname(sys.argv[0]))
execfile("%s/test-common.py" % (dirname,))
exec(open("%s/test-common.py" % (dirname,)).read())
#
# Convert the certificate into a credential.
......@@ -139,7 +140,7 @@ for userdict in response['value']:
urn = userdict['urn']
login = userdict['login']
for keydict in userdict['keys']:
if not keydict.has_key('type') or keydict['type'] != 'ssh':
if not 'type' in keydict or keydict['type'] != 'ssh':
continue
key = keydict['key']
......@@ -154,7 +155,7 @@ for userdict in response['value']:
rname += 'X'
pass
if not keysdone.has_key(rname):
if not rname in keysdone:
try:
nova.keypairs.create(rname,key)
keysdone[rname] = key
......@@ -191,14 +192,14 @@ else:
# where user_id=\'${AUID}\'
cmd = 'export AAUID="`%s | awk \'/ adminapi / {print $2}\'`" ; export AUID="`%s | awk \'/ admin / {print $2}\'`" ; mysqldump -u nova --password=%s nova -t key_pairs --skip-comments --quote-names --no-create-info --no-create-db --complete-insert --compact | sed -e \'s/,[0-9]*,/,NULL,/gi\' | sed -e "s/,\'${AAUID}\',/,\'${AUID}\',/gi" | mysql -u nova --password=%s nova ; echo "update key_pairs set deleted=0" | mysql -u nova --password=%s nova' % (os_cred_stuff,os_cred_stuff,NOVA_DBPASS,NOVA_DBPASS,NOVA_DBPASS,)
#cmd = 'export OS_PASSWORD="%s" ; export OS_AUTH_URL="%s" ; export OS_USERNAME="%s" ; export OS_TENANT_NAME="%s" ; export AAUID="`keystone user-list | awk \'/ adminapi / {print $2}\'`" ; export AUID="`keystone user-list | awk \'/ admin / {print $2}\'`" ; mysqldump -u nova --password=%s nova -t key_pairs --skip-comments --quote-names --no-create-info --no-create-db --complete-insert --compact | sed -e \'s/,[0-9]*,/,NULL,/gi\' | sed -e "s/,\'${AAUID}\',/,\'${AUID}\',/gi" | mysql -u nova --password=%s nova ; echo "update key_pairs set deleted=0 where user_id=\'${AUID}\'" | mysql -u nova --password=%s nova' % (OS_PASSWORD,OS_AUTH_URL,OS_USERNAME,OS_PASSWORD,NOVA_DBPASS,NOVA_DBPASS,NOVA_DBPASS,)
print "Running adminapi -> admin key import: %s..." % (cmd,)
myprint("Running adminapi -> admin key import: %s..." % (cmd,))
os.system(cmd)
#
# Ugh, the tables are now split between nova and nova_api ... so just do this too.
#
cmd = 'export AAUID="`%s | awk \'/ adminapi / {print $2}\'`" ; export AUID="`%s | awk \'/ admin / {print $2}\'`" ; mysqldump -u nova --password=%s nova_api -t key_pairs --skip-comments --quote-names --no-create-info --no-create-db --complete-insert --compact | sed -e \'s/,[0-9]*,/,NULL,/gi\' | sed -e "s/,\'${AAUID}\',/,\'${AUID}\',/gi" | mysql -u nova --password=%s nova_api ; echo "update key_pairs set deleted=0" | mysql -u nova_api --password=%s nova' % (os_cred_stuff,os_cred_stuff,NOVA_DBPASS,NOVA_DBPASS,NOVA_DBPASS,)
print "Running adminapi -> admin key import: %s..." % (cmd,)
myprint("Running adminapi -> admin key import: %s..." % (cmd,))
os.system(cmd)
sys.exit(0)
This diff is collapsed.