BlogWikiAbout

Kyle Pericak

"It works in my environment"

Create & Terminate EC2 Instances from Python

Create & Terminate EC2 Instances from Python

Created: 2020-01-09, Modified: 2020-01-09

Launch and terminate EC2 instances from Python using boto3, with a working example covering Ubuntu AMIs, security groups, tags, and wait_until_running.

Blog code last updated on 2026-04-16: 8579f34f0a3ec5b8043d5eade8e87124d41cf83b