diff --git a/lib/ansible/module_utils/redhat.py b/lib/ansible/module_utils/redhat.py index cc79f0f858..1eb6938514 100644 --- a/lib/ansible/module_utils/redhat.py +++ b/lib/ansible/module_utils/redhat.py @@ -66,7 +66,7 @@ class RegistrationBase(object): cfg.set('main', 'enabled', 1) else: cfg.set('main', 'enabled', 0) - fd = open(plugin_conf, 'rwa+') + fd = open(plugin_conf, 'w+') cfg.write(fd) fd.close()