diff --git a/bin/ec2-cost b/bin/ec2-cost index 3aa38e0a..a3f7ed05 100755 --- a/bin/ec2-cost +++ b/bin/ec2-cost @@ -18,6 +18,10 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . +# Exit immediately if this is not an Amazon EC2 instance, and we're not +# in debug mode +$(hostname | grep -qs "\.amazonaws\.com$") || [ -r "/tmp/ec2-cost-debug" ] +[ "$?" = "0" ] || exit 0 # Instance Cost Basis # US Europe