Refactor instance2ami.py to use configs, delete old AMIs.