mirror of
https://github.com/outbackdingo/patroni.git
synced 2026-08-25 14:53:37 +00:00
get rid of yaml module, since AWS instance-identity natively sends JSON.
This commit is contained in:
+1
-3
@@ -1,8 +1,6 @@
|
||||
import logging
|
||||
import re
|
||||
import requests
|
||||
from requests.exceptions import RequestException
|
||||
import yaml
|
||||
import boto.ec2
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -27,7 +25,7 @@ class AWSConnection:
|
||||
return
|
||||
if r.ok:
|
||||
try:
|
||||
content = yaml.load(r.content)
|
||||
content = r.json()
|
||||
self.instance_id = content['instanceId']
|
||||
self.region = content['region']
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user