Skip to content

Commit

Permalink
Add helpful message after success. Remove ssl warning when disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
myoung34 committed May 15, 2018
1 parent 2170dbc commit 9ff149f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fedcred/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,3 +169,5 @@ def write_credentials(profile, creds):
with open(aws_creds_path, 'w') as configfile:
config.write(configfile)
print('Credentials successfully written to %s' % (aws_creds_path))
print('To make this work by default, run "export AWS_DEFAULT_PROFILE={}"'.format(profile))

3 changes: 3 additions & 0 deletions fedcred/providers/adfs.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ def __init__(self, config):
try:
self.sslverification = self.config.getboolean(
common.DEFAULT_CONFIG_SECTION, 'sslverify')
if not self.sslverification:
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
self.idpurl = self.config.get('adfs', 'url')
self.domain = self.config.get('adfs', 'domain')
try:
Expand Down

0 comments on commit 9ff149f

Please sign in to comment.