Yaniv Bronhaim has uploaded a new change for review. Change subject: Adding to vds_static table vars to persist ssh authentication fields ......................................................................
Adding to vds_static table vars to persist ssh authentication fields This patch adds ssh_username and ssh_port to vds_static Change-Id: Idc14b05bb964c2cbe76d80a87a529ab3a2a02496 Signed-off-by: Yaniv Bronhaim <[email protected]> --- M backend/manager/dbscripts/create_views.sql A backend/manager/dbscripts/upgrade/03_03_0290_add_vds_username.sql M backend/manager/dbscripts/upgrade/post_upgrade/0010_add_object_column_white_list_table.sql M backend/manager/dbscripts/vds_sp.sql 4 files changed, 11 insertions(+), 7 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/95/16095/1 diff --git a/backend/manager/dbscripts/create_views.sql b/backend/manager/dbscripts/create_views.sql index fc02d39..e618768 100644 --- a/backend/manager/dbscripts/create_views.sql +++ b/backend/manager/dbscripts/create_views.sql @@ -630,7 +630,7 @@ as SELECT vds_groups.vds_group_id as vds_group_id, vds_groups.name as vds_group_name, vds_groups.description as vds_group_description, vds_groups.selection_algorithm as selection_algorithm, vds_static.vds_id as vds_id, vds_static.vds_name as vds_name, vds_static.ip as ip, vds_static.vds_unique_id as vds_unique_id, - vds_static.host_name as host_name, vds_static.port as port, vds_static.vds_strength as vds_strength, vds_static.server_SSL_enabled as server_SSL_enabled, vds_static.vds_type as vds_type, + vds_static.host_name as host_name, vds_static.port as port, vds_static.username as username, vds_static.vds_strength as vds_strength, vds_static.server_SSL_enabled as server_SSL_enabled, vds_static.vds_type as vds_type, vds_static.pm_type as pm_type, vds_static.pm_user as pm_user, vds_static.pm_password as pm_password, vds_static.pm_port as pm_port, vds_static.pm_options as pm_options, vds_static.pm_enabled as pm_enabled, vds_static.pm_proxy_preferences as pm_proxy_preferences,vds_static.pm_secondary_ip as pm_secondary_ip, @@ -671,7 +671,7 @@ as SELECT vds_groups.vds_group_id, vds_groups.name AS vds_group_name, vds_groups.description AS vds_group_description, vds_groups.selection_algorithm, vds_static.vds_id, vds_static.vds_name, vds_static.ip, vds_static.vds_unique_id, - vds_static.host_name, vds_static.port, vds_static.vds_strength, vds_static.server_SSL_enabled, vds_static.vds_type, + vds_static.host_name, vds_static.port, vds_static.username, vds_static.vds_strength, vds_static.server_SSL_enabled, vds_static.vds_type, vds_static.pm_type, vds_static.pm_user, vds_static.pm_password, vds_static.pm_port, vds_dynamic.hw_product_name, vds_dynamic.hw_version, vds_dynamic.hw_serial_number, vds_dynamic.hw_uuid, vds_dynamic.hw_family, vds_static.pm_options, vds_static.pm_enabled, vds_static.pm_proxy_preferences as pm_proxy_preferences, diff --git a/backend/manager/dbscripts/upgrade/03_03_0290_add_vds_username.sql b/backend/manager/dbscripts/upgrade/03_03_0290_add_vds_username.sql new file mode 100644 index 0000000..9257784 --- /dev/null +++ b/backend/manager/dbscripts/upgrade/03_03_0290_add_vds_username.sql @@ -0,0 +1 @@ +select fn_db_add_column('vds_static', 'username', 'VARCHAR(255)'); diff --git a/backend/manager/dbscripts/upgrade/post_upgrade/0010_add_object_column_white_list_table.sql b/backend/manager/dbscripts/upgrade/post_upgrade/0010_add_object_column_white_list_table.sql index 9232e72..8fe6eaf 100644 --- a/backend/manager/dbscripts/upgrade/post_upgrade/0010_add_object_column_white_list_table.sql +++ b/backend/manager/dbscripts/upgrade/post_upgrade/0010_add_object_column_white_list_table.sql @@ -39,7 +39,7 @@ where table_name = 'vds' and column_name in ( 'vds_group_id', 'vds_group_name', 'vds_group_description', 'selection_algorithm', - 'vds_id', 'vds_name', 'ip', 'vds_unique_id', 'host_name', 'port', 'vds_strength', + 'vds_id', 'vds_name', 'ip', 'vds_unique_id', 'host_name', 'port', 'username', 'vds_strength', 'server_ssl_enabled', 'vds_type', 'pm_type', 'pm_user', 'pm_port', 'pm_options', 'pm_enabled', 'pm_proxy_preferences', 'pm_secondary_ip', 'pm_secondary_type', 'pm_secondary_user', 'pm_secondary_port', 'pm_secondary_options', 'pm_secondary_concurrent', 'vds_spm_priority', 'hooks', 'status', 'cpu_cores', diff --git a/backend/manager/dbscripts/vds_sp.sql b/backend/manager/dbscripts/vds_sp.sql index d20120f..4a5751b 100644 --- a/backend/manager/dbscripts/vds_sp.sql +++ b/backend/manager/dbscripts/vds_sp.sql @@ -343,6 +343,7 @@ v_ip VARCHAR(255) , v_vds_unique_id VARCHAR(128) , v_port INTEGER, + v_username VARCHAR(255), v_vds_group_id UUID, v_vds_name VARCHAR(255), v_server_SSL_enabled BOOLEAN , @@ -371,7 +372,7 @@ BEGIN IF v_vds_unique_id IS NULL OR NOT EXISTS(SELECT vds_name FROM vds_static WHERE vds_unique_id = v_vds_unique_id) then BEGIN - INSERT INTO vds_static(vds_id,host_name, ip, vds_unique_id, port, vds_group_id, vds_name, server_SSL_enabled, + INSERT INTO vds_static(vds_id,host_name, ip, vds_unique_id, port, username, vds_group_id, vds_name, server_SSL_enabled, vds_type,vds_strength,pm_type,pm_user,pm_password,pm_port,pm_options,pm_enabled, pm_proxy_preferences, pm_secondary_ip, pm_secondary_type, pm_secondary_user, pm_secondary_password, pm_secondary_port, pm_secondary_options, pm_secondary_concurrent, @@ -395,6 +396,7 @@ v_ip VARCHAR(255) , v_vds_unique_id VARCHAR(128), v_port INTEGER, + v_username VARCHAR(255), v_vds_group_id UUID, v_vds_id UUID, v_vds_name VARCHAR(255), @@ -428,7 +430,7 @@ BEGIN UPDATE vds_static SET host_name = v_host_name,ip = v_ip,vds_unique_id = v_vds_unique_id, - port = v_port,vds_group_id = v_vds_group_id,vds_name = v_vds_name,server_SSL_enabled = v_server_SSL_enabled, + port = v_port, username = v_username, vds_group_id = v_vds_group_id,vds_name = v_vds_name,server_SSL_enabled = v_server_SSL_enabled, vds_type = v_vds_type, _update_date = LOCALTIMESTAMP,vds_strength = v_vds_strength, pm_type = v_pm_type,pm_user = v_pm_user,pm_password = v_pm_password, @@ -678,6 +680,7 @@ v_ip VARCHAR(40) , v_vds_unique_id VARCHAR(128) , v_port INTEGER, + v_username VARCHAR(255), v_vds_group_id UUID, v_vds_name VARCHAR(255), v_server_SSL_enabled BOOLEAN , @@ -704,12 +707,12 @@ BEGIN BEGIN - INSERT INTO vds_static(vds_id,host_name, ip, vds_unique_id, port, vds_group_id, vds_name, server_SSL_enabled, + INSERT INTO vds_static(vds_id,host_name, ip, vds_unique_id, port, username, vds_group_id, vds_name, server_SSL_enabled, vds_type,vds_strength,pm_type,pm_user,pm_password, pm_port, pm_options, pm_enabled, pm_secondary_ip, pm_secondary_type, pm_secondary_user, pm_secondary_password, pm_secondary_port, pm_secondary_options, pm_secondary_concurrent, pm_proxy_preferences, vds_spm_priority, console_address) - VALUES(v_vds_id,v_host_name, v_ip, v_vds_unique_id, v_port, v_vds_group_id, v_vds_name, v_server_SSL_enabled, + VALUES(v_vds_id,v_host_name, v_ip, v_vds_unique_id, v_port, v_username, v_vds_group_id, v_vds_name, v_server_SSL_enabled, v_vds_type, v_vds_strength,v_pm_type,v_pm_user,v_pm_password,v_pm_port, v_pm_options, v_pm_enabled, pm_secondary_ip, pm_secondary_type, pm_secondary_user, pm_secondary_password, pm_secondary_port, pm_secondary_options, pm_secondary_concurrent,v_pm_proxy_preferences, -- To view, visit http://gerrit.ovirt.org/16095 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Idc14b05bb964c2cbe76d80a87a529ab3a2a02496 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
