mirror of
https://github.com/ansible/awx.git
synced 2026-04-08 19:49:22 -02:30
Cleaning up some parts of the logging branch
* Fixing some flake8 warnings * Removing some superflous print statements
This commit is contained in:
@@ -15,9 +15,9 @@ def parse_config_file():
|
|||||||
|
|
||||||
project_id, access_token, api_domain = _parse_config_file_impl(filename)
|
project_id, access_token, api_domain = _parse_config_file_impl(filename)
|
||||||
|
|
||||||
if project_id is not None\
|
if project_id is not None \
|
||||||
and access_token is not None\
|
and access_token is not None \
|
||||||
and api_domain is not None:
|
and api_domain is not None:
|
||||||
return project_id, access_token, api_domain
|
return project_id, access_token, api_domain
|
||||||
|
|
||||||
else:
|
else:
|
||||||
@@ -54,4 +54,4 @@ def _parse_config_file_impl(filename):
|
|||||||
def get_config_from_env():
|
def get_config_from_env():
|
||||||
return (os.environ.get('SPLUNK_PROJECT_ID', None),
|
return (os.environ.get('SPLUNK_PROJECT_ID', None),
|
||||||
os.environ.get('SPLUNK_ACCESS_TOKEN', None),
|
os.environ.get('SPLUNK_ACCESS_TOKEN', None),
|
||||||
os.environ.get('SPLUNK_API_DOMAIN', None))
|
os.environ.get('SPLUNK_API_DOMAIN', None))
|
||||||
|
|||||||
@@ -53,8 +53,6 @@ class FactBrokerWorker(ConsumerMixin):
|
|||||||
return (module, facts)
|
return (module, facts)
|
||||||
|
|
||||||
def process_fact_message(self, body, message):
|
def process_fact_message(self, body, message):
|
||||||
print body
|
|
||||||
print type(body)
|
|
||||||
hostname = body['host']
|
hostname = body['host']
|
||||||
inventory_id = body['inventory_id']
|
inventory_id = body['inventory_id']
|
||||||
facts_data = body['facts']
|
facts_data = body['facts']
|
||||||
|
|||||||
Reference in New Issue
Block a user