diff --git a/doc/source/scale_deployment.rst b/doc/source/scale_deployment.rst index 07cc8787c7..2c702a8e8f 100644 --- a/doc/source/scale_deployment.rst +++ b/doc/source/scale_deployment.rst @@ -284,7 +284,7 @@ The original file from A looks like: [DEFAULT] ... - sql_connection = mysql://root:admin@127.0.0.1/heat?charset=utf8 + sql_connection = mysql+pymysql://root:admin@127.0.0.1/heat?charset=utf8 rabbit_host = localhost ... [heat_api] @@ -300,7 +300,7 @@ After the changes for B, it looks like: [DEFAULT] ... - sql_connection = mysql://root:admin@10.0.0.1/heat?charset=utf8 + sql_connection = mysql+pymysql://root:admin@10.0.0.1/heat?charset=utf8 rabbit_host = 10.0.0.1 ... [heat_api] diff --git a/install.sh b/install.sh index 657ecdf767..822580937a 100755 --- a/install.sh +++ b/install.sh @@ -73,7 +73,7 @@ basic_configuration() { if echo $conf_path | grep ".conf$" >/dev/null 2>&1 then iniset $target DEFAULT auth_encryption_key `hexdump -n 16 -v -e '/1 "%02x"' /dev/random` - iniset $target database connection "mysql://heat:heat@localhost/heat" + iniset $target database connection "mysql+pymysql://heat:heat@localhost/heat" BRIDGE_IP=127.0.0.1 iniset $target DEFAULT heat_metadata_server_url "http://${BRIDGE_IP}:8000/" diff --git a/test-requirements.txt b/test-requirements.txt index 489d5e1a2e..fd2d78ebdd 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -8,7 +8,7 @@ coverage>=3.6 discover mock>=1.0 mox>=0.5.3 -MySQL-python +PyMySQL>=0.6.2 # MIT License oslosphinx>=2.5.0 # Apache-2.0 oslotest>=1.5.1 # Apache-2.0 paramiko>=1.13.0 diff --git a/tox.ini b/tox.ini index c817c32b85..3b2396644e 100644 --- a/tox.ini +++ b/tox.ini @@ -7,6 +7,7 @@ skipsdist = True # Note the hash seed is set to 0 until heat can be tested with a # random hash seed successfully. setenv = VIRTUAL_ENV={envdir} + OS_TEST_DBAPI_ADMIN_CONNECTION=mysql+pymysql://openstack_citest:openstack_citest@localhost/;postgresql://openstack_citest:openstack_citest@localhost/postgres;sqlite:// PYTHONHASHSEED=0 usedevelop = True install_command = pip install {opts} {packages}