Skip to content

Instantly share code, notes, and snippets.

@bashtoni
bashtoni / gist:995c0683bb18fd19eaefdc296a9401d8
Created July 4, 2018 10:48
Find ARN for ACM certificate for a given domain name
aws acm us-east-1 list-certificates --query CertificateSummaryList[].[CertificateArn,DomainName] \
--output text | grep example.com | cut -f1
@ricjcosme
ricjcosme / dump-restore
Created September 13, 2017 17:33
DUMP / RESTORE PostgreSQL Kubernetes
DUMP
// pod-name name of the postgres pod
// postgres-user database user that is able to access the database
// database-name name of the database
kubectl exec [pod-name] -- bash -c "pg_dump -U [postgres-user] [database-name]" > database.sql
RESTORE
// pod-name name of the postgres pod
// postgres-user database user that is able to access the database
// database-name name of the database