mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-06 22:24:23 -07:00
Blanks Errors
This commit is contained in:
parent
db1ac68cbf
commit
bccf55ba98
1 changed files with 7 additions and 13 deletions
|
@ -71,11 +71,9 @@ import hashlib
|
|||
|
||||
def get_exports(module, output_format, file_path="/etc/exports"):
|
||||
|
||||
|
||||
IP_ENTRY_PATTERN = re.compile(r'(\d+\.\d+\.\d+\.\d+)\(([^)]+)\)')
|
||||
MAIN_LINE_PATTERN = re.compile(r'\s*(\S+)\s+(.+)')
|
||||
|
||||
|
||||
file_digests = {}
|
||||
hash_algorithms = ['sha256', 'sha1', 'md5']
|
||||
|
||||
|
@ -105,7 +103,6 @@ def get_exports(module, output_format, file_path="/etc/exports"):
|
|||
|
||||
exports = {}
|
||||
|
||||
|
||||
output_lines = []
|
||||
if file_content_bytes:
|
||||
output_lines = file_content_bytes.decode('utf-8', errors='ignore').splitlines()
|
||||
|
@ -147,9 +144,6 @@ def get_exports(module, output_format, file_path="/etc/exports"):
|
|||
|
||||
except Exception as e:
|
||||
module.fail_json(msg="Error while processing exports: {}".format(e))
|
||||
|
||||
|
||||
|
||||
def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue