From d3b1bfe75ee0f6ca65f3564e0847740ea026b1f7 Mon Sep 17 00:00:00 2001 From: Benno Joy Date: Tue, 29 Aug 2017 17:03:18 +0800 Subject: [PATCH] Update win_sql_install.yml --- win_sql_install.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/win_sql_install.yml b/win_sql_install.yml index e73aea0..dcfd223 100644 --- a/win_sql_install.yml +++ b/win_sql_install.yml @@ -46,3 +46,17 @@ args: chdir: c:\sql + - name: Add or update registry for ip port + win_regedit: + path: 'HKLM:\Software\Microsoft\Microsoft SQL Server\MSSQL12.{{ sql_instance_name }}\MSSQLServer\SuperSocketNetLib\Tcp\IPAll' + name: TcpPort + data: 1433 + register: win_reg + + - name: Restart a service + win_service: + name: 'MSSQL${{ sql_instance_name }}' + force_dependent_services: yes + state: restarted + when: win_reg.changed +