Add underscore and period to regex for hostname prompt (#30612)
* Add _ and . to regex (#30396)
Adding underscore and period to the nxos regex for determining the prompt for hostnames with underscores and periods in the hostname.
(cherry picked from commit 33b8d7069f)
* Add change log
This commit is contained in:
@ -17,6 +17,7 @@ Ansible Changes By Release
|
||||
* Fixed docs for 'password' lookup
|
||||
* Corrected and added missing feature and porting docs for 2.4
|
||||
* Fix for Ansible.ModuleUtils.CamelConversion to handle empty lists and lists with one entry
|
||||
* Fix nxos terminal regex to parse username correctly.
|
||||
|
||||
<a id="2.4"></a>
|
||||
|
||||
|
||||
@ -28,8 +28,8 @@ from ansible.errors import AnsibleConnectionFailure
|
||||
class TerminalModule(TerminalBase):
|
||||
|
||||
terminal_stdout_re = [
|
||||
re.compile(br'[\r\n]?[a-zA-Z]{1}[a-zA-Z0-9-]*[>|#|%](?:\s*)$'),
|
||||
re.compile(br'[\r\n]?[a-zA-Z]{1}[a-zA-Z0-9-]*\(.+\)#(?:\s*)$')
|
||||
re.compile(br'[\r\n]?[a-zA-Z]{1}[a-zA-Z0-9-_.]*[>|#|%](?:\s*)$'),
|
||||
re.compile(br'[\r\n]?[a-zA-Z]{1}[a-zA-Z0-9-_.]*\(.+\)#(?:\s*)$')
|
||||
]
|
||||
|
||||
terminal_stderr_re = [
|
||||
|
||||
Reference in New Issue
Block a user