Skip to content

Instantly share code, notes, and snippets.

@UtahCampusD
Created November 28, 2016 21:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save UtahCampusD/0ff7ebe7eaad9a2229012eb50aeb49b8 to your computer and use it in GitHub Desktop.
Save UtahCampusD/0ff7ebe7eaad9a2229012eb50aeb49b8 to your computer and use it in GitHub Desktop.
----------
ID: clientaliveinterval
Function: file.line
Name: /etc/ssh/sshd_config
Result: False
Comment: An exception occurred in this state: Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/salt/state.py", line 1733, in call
**cdata['kwargs'])
File "/usr/lib/python2.7/site-packages/salt/loader.py", line 1652, in wrapper
return f(*args, **kwargs)
File "/usr/lib/python2.7/site-packages/salt/states/file.py", line 2724, in line
backup=backup, quiet=quiet, indent=indent)
File "/usr/lib/python2.7/site-packages/salt/modules/file.py", line 1491, in line
mode = mode and mode.lower() or mode
AttributeError: 'list' object has no attribute 'lower'
Started: 07:45:13.950771
Duration: 3.542 ms
Changes:
----------
ID: clientalivecountmax
Function: file.line
Name: /etc/ssh/sshd_config
Result: False
Comment: An exception occurred in this state: Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/salt/state.py", line 1733, in call
**cdata['kwargs'])
File "/usr/lib/python2.7/site-packages/salt/loader.py", line 1652, in wrapper
return f(*args, **kwargs)
File "/usr/lib/python2.7/site-packages/salt/states/file.py", line 2724, in line
backup=backup, quiet=quiet, indent=indent)
File "/usr/lib/python2.7/site-packages/salt/modules/file.py", line 1491, in line
mode = mode and mode.lower() or mode
AttributeError: 'list' object has no attribute 'lower'
Started: 07:45:13.954523
Duration: 0.544 ms
Changes:
# Client Alive Interval
clientaliveinterval:
file.line:
- name: /etc/ssh/sshd_config
- content: ClientAliveInterval 900
- match: ^#ClientAliveInterval
- mode:
- ensure
- backup: True
# Client Alive Count Max
clientalivecountmax:
file.line:
- name: /etc/ssh/sshd_config
- content: ClientAliveCountMax 0
- match: ^#ClientAliveCountMax
- mode:
- ensure
- backup: True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment