mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Make sure we only use GetConnection if we are using a proxy salt minion
This commit is contained in:
parent
1505c5724b
commit
5fdfed1cb9
1 changed files with 2 additions and 0 deletions
|
@ -187,6 +187,8 @@ def get_service_instance(host, username, password, protocol=None, port=None):
|
|||
service_instance = GetSi()
|
||||
if service_instance:
|
||||
if service_instance._GetStub().host == ':'.join([host, str(port)]):
|
||||
if salt.utils.is_proxy():
|
||||
service_instance._GetStub().GetConnection()
|
||||
return service_instance
|
||||
Disconnect(service_instance)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue