From 1ce6e3d691461e893d5a8bde647bbf42f0f71a0c Mon Sep 17 00:00:00 2001 From: Jesse Pretorius Date: Mon, 21 Mar 2016 18:06:38 +0000 Subject: [PATCH] Switch from MySQL-python to PyMySQL As part of the cross-project effort [1] to prepare OpenStack for Python3 as the primary Python version used, the decision has been made to switch from using MySQL-python to PyMySQL [2]. This patch switches Ironic to use the PyMySQL library. [1] https://etherpad.openstack.org/p/liberty-cross-project-python3 [2] https://review.openstack.org/184388 Change-Id: I9c6906c37213a2a48c9aab3988b392fb7397ea90 --- defaults/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/defaults/main.yml b/defaults/main.yml index 3a40c31e..f5320485 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -93,7 +93,7 @@ ironic_openstack_auth_strategy: keystone ironic_openstack_api_url: '' # Not required when we have keystone ironic_openstack_dhcp_provider: neutron ironic_openstack_sync_power_state_interval: 60 -ironic_openstack_db_connection_string: "mysql://{{ ironic_galera_user }}:{{ ironic_galera_password }}@{{ ironic_galera_address }}/ironic" +ironic_openstack_db_connection_string: "mysql+pymysql://{{ ironic_galera_user }}:{{ ironic_galera_password }}@{{ ironic_galera_address }}/ironic" # Standalone Ironic configuration ironic_standalone_driver_list: agent_ipmitool @@ -101,7 +101,7 @@ ironic_standalone_auth_strategy: noauth ironic_standalone_api_url: "api_url=http://{{ ansible_default_ipv4['address'] }}:6385/" ironic_standalone_dhcp_provider: none ironic_standalone_sync_power_state_interval: -1 -ironic_standalone_db_connection_string: "mysql://{{ ironic_galera_user }}:{{ ironic_galera_password }}@{{ ironic_galera_address }}/ironic" +ironic_standalone_db_connection_string: "mysql+pymysql://{{ ironic_galera_user }}:{{ ironic_galera_password }}@{{ ironic_galera_address }}/ironic" # Common configuration ironic_node_name: ironic @@ -127,7 +127,7 @@ ironic_requires_pip_packages: - httplib2 # for Ansible's uri module ironic_pip_packages: - - MySQL-python + - PyMySQL - ironic - python-ironicclient