lowlydba.sqlserver.tcp_port module – Sets the TCP port for the instance
Note
This module is part of the lowlydba.sqlserver collection (version 2.3.4).
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install lowlydba.sqlserver
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: lowlydba.sqlserver.tcp_port
.
New in lowlydba.sqlserver 0.10.0
Synopsis
Sets the TCP port for a SQL Server instance.
Requirements
The below requirements are needed on the host that executes this module.
dbatools PowerShell module
Parameters
Parameter |
Comments |
---|---|
Restart SQL Server and SQL Agent services automatically. Choices:
|
|
IPv4 address. |
|
Password for alternative credential to authenticate with Windows. |
|
Port for SQL Server to listen on. |
|
The SQL Server instance to modify. |
|
Password for SQL Authentication. |
|
Username for SQL Authentication. |
|
Username for alternative credential to authenticate with Windows. |
Attributes
Attribute |
Support |
Description |
---|---|---|
Support: full |
Can run in check_mode and return changed status prediction without modifying target. |
|
Platform: Windows |
Target OS/families that can be operated against. |
Examples
- name: Set the default port
lowlydba.sqlserver.tcp_port:
sql_instance: sql-01.myco.io
port: 1433
- name: Set a non-standard default port
lowlydba.sqlserver.tcp_port:
sql_instance: sql-01.myco.io
port: 1933
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
Output from the RestartRequired returned if the change requires a service restart to take effect. Returned: success, but not in check_mode. |