Skip to content

Instantly share code, notes, and snippets.

@RajatGoyal
RajatGoyal / estimated_bill.sh
Last active September 7, 2018 18:21
total estimated bill aws
#!/bin/sh
from_email="from@synaptic.com"
to_email="to@synaptic.com"
max_estimated_charge_12_hour=$(aws --region us-east-1 cloudwatch get-metric-statistics \
--namespace "AWS/Billing" \
--metric-name "EstimatedCharges" \
--dimension "Name=Currency,Value=USD" \
--start-time $(date +"%Y-%m-%dT%H:%M:00" --date="-12 hours") --end-time $(date +"%Y-%m-%dT%H:%M:00") \
@jeefy
jeefy / install-rancher-compose.sh
Last active April 6, 2025 07:33
Rancher Compose Install Script
#!/bin/bash
# To run locally: ` curl -s https://gist.githubusercontent.com/jeefy/7fed19a335d5caae24639e7ee7be1b71/raw/install-rancher-compose.sh | sh `
VERSION_NUM="0.9.2"
wget https://github.com/rancher/rancher-compose/releases/download/v${VERSION_NUM}/rancher-compose-linux-amd64-v${VERSION_NUM}.tar.gz
tar zxf rancher-compose-linux-amd64-v${VERSION_NUM}.tar.gz
rm rancher-compose-linux-amd64-v${VERSION_NUM}.tar.gz
sudo mv rancher-compose-v${VERSION_NUM}/rancher-compose /usr/local/bin/rancher-compose