parent
9453f6b97a
commit
cffd5601b6
1 changed files with 4 additions and 0 deletions
|
@ -20,6 +20,7 @@
|
||||||
|
|
||||||
import binascii
|
import binascii
|
||||||
import copy
|
import copy
|
||||||
|
import locale
|
||||||
import textwrap
|
import textwrap
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
|
||||||
|
@ -770,6 +771,9 @@ def main():
|
||||||
supports_check_mode = True,
|
supports_check_mode = True,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# AnsibleModule() changes the locale, so change it back to C because we rely on time.strptime() when parsing certificate dates.
|
||||||
|
locale.setlocale(locale.LC_ALL, "C")
|
||||||
|
|
||||||
cert_days = get_cert_days(module,module.params['dest'])
|
cert_days = get_cert_days(module,module.params['dest'])
|
||||||
if cert_days < module.params['remaining_days']:
|
if cert_days < module.params['remaining_days']:
|
||||||
# If checkmode is active, base the changed state solely on the status
|
# If checkmode is active, base the changed state solely on the status
|
||||||
|
|
Loading…
Reference in a new issue