{"id":51507958,"url":"https://github.com/explicit-logic/python-module-14.2","last_synced_at":"2026-07-08T02:30:43.554Z","repository":{"id":361022382,"uuid":"1251743714","full_name":"explicit-logic/python-module-14.2","owner":"explicit-logic","description":"Automate configuring EC2 Server Instances","archived":false,"fork":false,"pushed_at":"2026-05-28T21:01:26.000Z","size":865,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-28T23:06:10.989Z","etag":null,"topics":["aws","boto3","devops-bootcamp","ec2","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/explicit-logic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-27T21:51:35.000Z","updated_at":"2026-05-28T21:07:04.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/explicit-logic/python-module-14.2","commit_stats":null,"previous_names":["explicit-logic/python-module-14.2"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/explicit-logic/python-module-14.2","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/explicit-logic%2Fpython-module-14.2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/explicit-logic%2Fpython-module-14.2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/explicit-logic%2Fpython-module-14.2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/explicit-logic%2Fpython-module-14.2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/explicit-logic","download_url":"https://codeload.github.com/explicit-logic/python-module-14.2/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/explicit-logic%2Fpython-module-14.2/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35249883,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-08T02:00:06.796Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aws","boto3","devops-bootcamp","ec2","python"],"created_at":"2026-07-08T02:30:42.980Z","updated_at":"2026-07-08T02:30:43.539Z","avatar_url":"https://github.com/explicit-logic.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Module 14 - Automation with Python\n\nThis repository contains a demo project created as part of my **DevOps studies** in the [TechWorld with Nana – DevOps Bootcamp](https://www.techworld-with-nana.com/devops-bootcamp).\n\n**Demo Project:** Automate configuring EC2 Server Instances\n\n**Technologies used:** Python, Boto3, AWS\n\n**Project Description:**\n\n- Write a Python script that automates adding environment tags to all EC2 Server instances\n\n---\n\n## Prerequisites\n\nInstall Python dependencies with [uv](https://docs.astral.sh/uv/):\n\n```shell\nuv sync\n```\n\nConfigure AWS credentials at `~/.aws/credentials`:\n\n```conf\n[default]\naws_access_key_id = AKIA...\naws_secret_access_key = ...\n```\n\nAnd the default region at `~/.aws/config`:\n\n```conf\n[default]\nregion = us-east-1\n```\n\n---\n\n## Create EC2 instances manually\n\nNavigate to **AWS Dashboard → EC2 → Launch instances**.\n\n### 1. Launch 2 instances in Frankfurt\n\n- **Region:** Europe (Frankfurt) — `eu-central-1`\n- **Number of instances:** `2`\n- Leave all other settings at their defaults.\n\n![Launch instances in Frankfurt](./images/launch-instances.png)\n\n### 2. Launch 1 instance in Paris\n\n- **Region:** Europe (Paris) — `eu-west-3`\n- **Number of instances:** `1`\n- Leave all other settings at their defaults.\n\n---\n\n## Execute the Python script\n\nThe script tags Frankfurt instances as `environment=prod` and Paris instances as `environment=dev`.\n\nSource: [add-env-tags.py](./add-env-tags.py)\n\nRun:\n\n```sh\npython3 ./add-env-tags.py\n```\n\n\u003e A successful run produces no output.\n\n### Verify the tags in the EC2 dashboard\n\nFor each instance, open **Instance → Tags** and confirm the `environment` tag is set.\n\n**Frankfurt** (`environment=prod`):\n\n![Frankfurt instance tags](./images/frankfurt-tags.png)\n\n**Paris** (`environment=dev`):\n\n![Paris instance tags](./images/paris-tags.png)\n\n---\n\n## Clean up created instances\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fexplicit-logic%2Fpython-module-14.2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fexplicit-logic%2Fpython-module-14.2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fexplicit-logic%2Fpython-module-14.2/lists"}