Skip to content

Instantly share code, notes, and snippets.

@aizatto
Last active October 19, 2019 12:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aizatto/29f3b349ed061a1bd41b442b08f951c8 to your computer and use it in GitHub Desktop.
Save aizatto/29f3b349ed061a1bd41b442b08f951c8 to your computer and use it in GitHub Desktop.
List custom domains in all regions

Trying to delete a certificate I keep getting the error:

Certificate is in use The certificate * (*) is in use (associated with other AWS resources) and cannot be deleted. Disassociate the certificate from each resource in the list and try again.

But I can't seem to find where the certificate is in use by, so I thought of listing all the regions, but none of it helped.

Hopefully this will be useful to someone.

brew install aws

https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.RegionsAndAvailabilityZones.html

aws apigateway get-domain-names --region us-east-1
aws apigateway get-domain-names --region us-east-2
aws apigateway get-domain-names --region us-west-1
aws apigateway get-domain-names --region us-west-2
aws apigateway get-domain-names --region ap-east-1
aws apigateway get-domain-names --region ap-south-1
aws apigateway get-domain-names --region ap-northeast-1
aws apigateway get-domain-names --region ap-northeast-2
aws apigateway get-domain-names --region ap-northeast-3
aws apigateway get-domain-names --region ap-southeast-1
aws apigateway get-domain-names --region ap-southeast-2
aws apigateway get-domain-names --region ca-central-1
aws apigateway get-domain-names --region cn-north-1
aws apigateway get-domain-names --region cn-northwest-1
aws apigateway get-domain-names --region eu-central-1
aws apigateway get-domain-names --region eu-west-1
aws apigateway get-domain-names --region eu-west-2
aws apigateway get-domain-names --region eu-west-3
aws apigateway get-domain-names --region eu-north-3
aws apigateway get-domain-names --region me-south-3
aws apigateway get-domain-names --region sa-east-3
aws apigateway get-domain-names --region us-gov-east-1
aws apigateway get-domain-names --region us-gov-east-2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment