Skip to content
DevOps · Cloud2024

A CI/CD pipeline on AWS with Jenkins, Ansible and Terraform

Infrastructure as code with Terraform and Ansible on AWS, and Jenkins pipelines that build and deploy a Python app on every GitHub change. A York University Cloud Operations project.

Client
York University · Cloud Operations
Year
2024
Role
Engineer
Stack
Terraform · Ansible · Jenkins · AWS · GitHub · Python
3
LABS
Terraform, Terraform with Ansible, and Jenkins pipelines

01 · Discover

Infrastructure by hand does not scale

Clicking servers, networks and deploys together one step at a time is slow, hard to repeat and easy to get wrong. This York University Cloud Operations project set out to automate the whole path, from the AWS infrastructure to every release of the code that runs on it.

02 · Architect

Three tools, one pipeline

  • Terraform describes the AWS infrastructure as code and provisions it
  • Ansible configures what Terraform creates
  • Jenkins builds, tests and deploys the application whenever the code changes on GitHub

03 · Build

Built in three labs

Lab 1: automating AWS infrastructure with Terraform. Instead of creating resources step by step, the infrastructure is written as Terraform code and provisioned by running it, which saves time and makes the systems on AWS easier to manage.

Lab 2: provisioning and configuring with Terraform and Ansible. Terraform and Ansible together manage a more complex set of systems on AWS: one creates the infrastructure, the other configures it.

Lab 3: Jenkins pipelines. CI/CD pipelines for a Python program build it and put it into action automatically. Every change pushed to the GitHub repository triggers the pipeline, with no manual deploy.

04 · Launch

From commit to running code

The result is a pipeline where a code change on GitHub flows through build and deploy on its own, on infrastructure that is defined, provisioned and configured as code. It is the same approach behind this site, where every push is tested, built and deployed by GitHub Actions.

Next case study

Document OCR and RAG on Amazon Bedrock