Skip to content
This repository has been archived by the owner on Jan 19, 2022. It is now read-only.

Commit

Permalink
Merge e4c0179 into cec3e07
Browse files Browse the repository at this point in the history
  • Loading branch information
ltsampros committed Dec 21, 2016
2 parents cec3e07 + e4c0179 commit 0bd543c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion bootstrap_cfn/fab_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,8 @@ def cfn_delete(force=False, pre_delete_callbacks=None):
iam.delete_ssl_certificate(cfn_config.ssl(), stack_name)
except AttributeError, boto.exception:
print green("SSL certificate was already deleted.")
except KeyError:
print green("SSL does not exist in cloudformation configuration file")

return True

Expand Down Expand Up @@ -704,8 +706,10 @@ def cfn_create(test=False):
print red("Deleting SSL certificates from stack")
iam.delete_ssl_certificate(cfn_config.ssl(), stack_name)
import traceback
red("Failed to create: {error}".format(error=traceback.format_exc()))
red("Deleting stack and aborting...)")
cfn_delete(True)
abort(red("Failed to create: {error}".format(error=traceback.format_exc())))
abort(red("Aborted..."))

print green("\nSTACK {0} CREATING...\n").format(stack_name)
if not env.blocking:
Expand Down

0 comments on commit 0bd543c

Please sign in to comment.