<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Seun Okegbola on Medium]]></title>
        <description><![CDATA[Stories by Seun Okegbola on Medium]]></description>
        <link>https://medium.com/@seun.okegbola?source=rss-54d8a16cd12e------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*dmbNkD5D-u45r44go_cf0g.png</url>
            <title>Stories by Seun Okegbola on Medium</title>
            <link>https://medium.com/@seun.okegbola?source=rss-54d8a16cd12e------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 03 Dec 2026 13:32:55 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@seun.okegbola/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How I Built a Production-Grade CI/CD Pipeline to AWS EKS — A Complete DevSecOps Project]]></title>
            <link>https://medium.com/@seun.okegbola/how-i-built-a-production-grade-ci-cd-pipeline-to-aws-eks-a-complete-devsecops-project-83b95d76d110?source=rss-54d8a16cd12e------2</link>
            <guid isPermaLink="false">https://medium.com/p/83b95d76d110</guid>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[cicd]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Seun Okegbola]]></dc:creator>
            <pubDate>Thu, 27 Aug 2026 13:44:32 GMT</pubDate>
            <atom:updated>2026-08-27T13:44:32.654Z</atom:updated>
            <content:encoded><![CDATA[<p><em>A security-scanned, self-healing Kubernetes deployment with its own monitoring stack — built, broken, and fixed.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sl04Ct9kQZ6yuUlXl8mDnw.png" /><figcaption><em>The finished product: a Disney+ Hotstar clone, live at </em><a href="https://seunhotstar.selearning.uk,/"><em>https://seunhotstar.selearning.uk,</em></a><em> served through Kubernetes on AWS EKS.</em></figcaption></figure><p>CloudBoosta handed me a project brief: deploy a Disney+ Hotstar clone to Kubernetes, in front of a full CI/CD pipeline. Reading it was one thing — actually running it on my own AWS account, against my own domain, with no tutorial safety net once something broke in a way the brief never mentioned, was another. What follows is the real account: what got built, in what order, and every error that had to be fixed along the way.</p><h3>The Goal</h3><p>Push code, and let the pipeline do everything else: static analysis, dependency and image vulnerability scanning, a container build, and a deployment to a live Kubernetes cluster — watched over by a separately provisioned monitoring stack reporting uptime and response time in real time.</p><p>The chain, end to end: <strong>GitHub → Jenkins → SonarQube / OWASP Dependency-Check / Trivy → Docker Hub → AWS EKS → Cloudflare.</strong> Running in parallel, on its own pipeline: <strong>Terraform → an EC2 monitoring server → Prometheus, Grafana, and the Blackbox Exporter.</strong></p><p><strong>Tools/services used:</strong> Jenkins, SonarQube, OWASP Dependency-Check, Trivy, Docker, AWS EKS/Kubernetes (via eksctl), Terraform, Prometheus, Grafana, Cloudflare.</p><h3>Setting Up the Build Server and Tool chain</h3><p>Everything runs off a single EC2 instance — seun+hotstar, t3.xlarge, Ubuntu 24.04 — with a security group opened up front for every port the tool chain would eventually need: 22 (SSH), 80/443 (HTTP/HTTPS), 8080 (Jenkins), 9000 (SonarQube), and 587/465 (Gmail SMTP). Port 3000, for the app container itself, got added later once it was actually needed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8i5rngEAwMhUu1bu0RX25Q.png" /><figcaption><em>The build server instance — t3.xlarge, Ubuntu 24.04, key pair cba-keypair3.</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WSAC76Fft_j4bPv8U8VPAQ.png" /><figcaption><em>Every port the tool chain would need, opened from the start.</em></figcaption></figure><p>The project’s own install scripts handled the rest: jenkins.sh, docker.sh, kubectl.sh, awscli.sh, trivy.sh, terraform.sh, eksctl.sh, and grafana.sh, ran in sequence. SonarQube went in as a Docker container rather than a native install — docker run -d --name sonar -p 9000:9000 sonarqube:lts-community — which mattered later when the container needed a restart policy.</p><p>For source control, the application code was cloned into a new repository under my own GitHub account, created public at first and switched to private via Settings → Danger Zone once everything was in place. A classic Personal Access Token (scopes: repo, write:packages, admin:repo_hook) was generated and stored as a Jenkins credential — the pipeline never touches a raw password.</p><h3>Wiring Together the CI/CD Pipeline</h3><p>The heart of the project is a Jenkins pipeline (hotstar-seun) with a confirmed stage order — checked directly against the Blue Ocean view: clean workspace → checkout from Git → SonarQube analysis → quality gate → install dependencies → OWASP Dependency-Check → Trivy filesystem scan → Docker build &amp; push → Trivy image scan → local deploy-to-container smoke test → email notification, pass or fail.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LyYXJfzarpeqrJjIFSYiwg.png" /><figcaption><em>Blue Ocean view of the first fully green, end-to-end run — every stage from checkout through deploy, in 8m43s.</em></figcaption></figure><p>A few deliberate design choices worth calling out:</p><ul><li><strong>The quality gate is non-blocking</strong> (abortPipeline: false), so a SonarQube warning doesn’t halt the pipeline. In a real production setting I’d flip that to blocking above low severity; here it stayed informational so one finding wouldn’t stop the demonstration.</li><li><strong>No secret ever appears in the Jenkinsfile.</strong> GitHub access uses a stored credential ID, Docker Hub push uses a stored Docker credential, and the OWASP scan’s NVD API key is injected as an environment variable.</li><li><strong>A second, entirely separate Jenkins job</strong> (monitoringserver) runs the Terraform apply/destroy described further down — kept isolated from the main app pipeline since it manages different infrastructure entirely.</li><li><strong>A local smoke test runs before Kubernetes ever sees the image</strong> — the built image is deployed as a plain Docker container on the build server itself first, purely as a sanity check.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fyIO1dQBJlbhlQiMSUdgew.png" /><figcaption><em>The app running from the local smoke-test container, reachable directly on the build server before touching the cluster.</em></figcaption></figure><h3>Getting It Onto Kubernetes — and Proving It Heals Itself</h3><p>Spinning up the actual Kubernetes cluster came down to one command: eksctl create cluster --name seun-hotstar-cluster --region eu-west-2 --node-type t2.medium --zones eu-west-2a,eu-west-2b. eksctl is a tool built specifically for creating EKS clusters — it handles all the underlying AWS setup on its own, rather than me writing and maintaining that setup myself the way I did with Terraform for the monitoring server below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LTK7Np-C2rA6gQ4JoZatnw.png" /><figcaption><em>seun-hotstar-cluster — Active, Kubernetes 1.34, eu-west-2.</em></figcaption></figure><p>With the cluster live and kubectl auto-configured, kubectl apply -f manifest.yml deployed the application as a Kubernetes Deployment with 2 replicas behind a Load Balancer Service.</p><p><strong>Then came the part the whole project was really about: proving Kubernetes actually self-heals, not just claiming it does.</strong> I deleted a running pod directly with kubectl delete pod and watched what happened next.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v_wn83tL9chsi_V7QUFJCg.png" /><figcaption><em>kubectl delete pod, then kubectl get pods — a brand-new pod, 29 seconds old, has already replaced the deleted one. Replica count restored to 2, automatically, with no redeploy and no manual intervention.</em></figcaption></figure><p>That’s the resilience guarantee this whole pipeline exists to make trustworthy — not a theoretical one, watched happen in real time.</p><h3>Building an Independent Monitoring Stack</h3><p>Monitoring runs on its own EC2 instance, provisioned entirely separately from the app cluster — this is the one piece of the project actually built with Terraform, run through the dedicated monitoringserver Jenkins pipeline, parameterized for apply or destroy.</p><p>Prometheus’ Blackbox Exporter probes three targets: a public reference site, the app’s direct container endpoint, and the live custom domain over HTTPS. Grafana turns that into a live dashboard using the community “Blackbox Exporter (HTTP prober)” dashboard (grafana.com ID 13659), imported against my own Prometheus data source.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uRJXP3yGm2HELpwxPpHXmg.png" /><figcaption><em>The imported dashboard — all three targets up, HTTP 200, valid TLS 1.3 on the HTTPS targets</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5gwbWEXg_wSw_p5hLuCH5Q.png" /><figcaption><em>Per-target probe duration and phase breakdown — DNS, connect, TLS, transfer — for every monitored endpoint, live.</em></figcaption></figure><h3>Putting a Real Domain and HTTPS in Front of It</h3><p>A CNAME record in Cloudflare points the custom domain at the EKS LoadBalancer’s DNS name, with Cloudflare’s proxy enabled. Since the AWS-provisioned load balancer only serves plain HTTP, Cloudflare’s SSL/TLS mode is set to <strong>Flexible</strong> — HTTPS terminates at Cloudflare’s edge while the connection to the origin load balancer stays plain HTTP behind the scenes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*E5sxi6wLXKa1J4Uk_p5jbA.png" /><figcaption><em>seunhotstar.selearning.uk resolving through the Cloudflare-proxied CNAME.</em></figcaption></figure><h3>The Real Errors I Hit (and How I Actually Fixed Them)</h3><p><strong>Error 1 — GitHub authentication failure.</strong> The first Jenkins checkout attempt failed with Password authentication is not supported for Git operations — GitHub dropped password auth over HTTPS years ago. Fixed by generating a Personal Access Token and storing it as a Jenkins credential.</p><p><strong>Error 2 — A tool name that didn’t match itself.</strong> The Jenkinsfile’s tools block referenced a NodeJS installation named node, but Global Tool Configuration had it registered as nodejs.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OEk8FWwYpxXznH07ZkV8ag.png" /><figcaption><em>The exact Groovy compilation error, before the pipeline ever started running.</em> Renamed the tool installation to match, and the next build ran clean through checkout, analysis, and the quality gate.</figcaption></figure><p><strong>Error 3 — SonarQube’s container quietly died.</strong> It had been launched without a restart policy and was killed the moment an SSH session dropped. docker update --restart unless-stopped fixed it permanently.</p><p><strong>Error 4 — A key pair that existed — just not in the region Jenkins thought it was in.</strong> Terraform failed creating the monitoring instance with InvalidKeyPair.NotFound for a key pair that genuinely existed, in eu-west-2, in both AWS and my local main.tf.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*X8HvlV7b9F9o1UtORV0vEw.png" /><figcaption><em>Terraform apply failing on a key pair AWS reported as not found.</em> The GitHub-hosted main.tf that Jenkins actually built from still carried the region setting inherited from the original tutorial repo — the local fix simply hadn’t been pushed yet. Committing and pushing the corrected file resolved it.</figcaption></figure><p><strong>Error 5 — Disk space quietly took the build server to the edge.</strong> Docker images, npm installs, and vulnerability database caches ate through a 15GB root volume.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xQow0zsio8gbXp5wHUOnSg.png" /><figcaption><em>Jenkins’ built-in node monitor — free disk, swap, and temp space all in the red.</em> Resized the EBS volume to 30GB and extended the filesystem live with growpart and resize2fs — no reboot required.</figcaption></figure><p><strong>Error 6 — The deploy manifest was still pointing at someone else’s image.</strong> manifest.yml as pulled from the repo still referenced the original tutorial author’s Docker Hub image rather than the one actually built and pushed. Nothing errored — Kubernetes just ran the wrong container. Caught on a second read, corrected to himora22/seun-hotstar:latest, and re-applied.</p><p><strong>Error 7 — HTTP vs HTTPS, more than once.</strong> Trying https:// against an endpoint with no TLS listener hangs rather than failing clearly. Solved for the public domain by letting Cloudflare terminate HTTPS at its edge instead.</p><p><strong>Error 8 — A Prometheus config edit broke YAML indentation, then the file got root-owned.</strong> A single indentation mistake broke prometheus.yml while adding a fourth scrape job, and the file separately ended up root-owned during editing, blocking further saves.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0JFyq55efq4lTjHGPc3GQw.png" /><figcaption><em>promtool check config passing clean after both issues were fixed, right before the restart.</em></figcaption></figure><h3>What’s Actually Live</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*E5sxi6wLXKa1J4Uk_p5jbA.png" /><figcaption><em>seunhotstar.selearning.uk, served over HTTPS.</em></figcaption></figure><ul><li>A Disney+ Hotstar clone, publicly reachable over HTTPS at a custom domain</li><li>A fully automated pipeline where every push runs through static analysis, dependency scanning, and image scanning before anything deploys</li><li>Kubernetes self-healing, proven live, not just claimed</li><li>A separately provisioned, Terraform-managed monitoring stack with real-time Grafana dashboards</li><li>Real scan output, not just “a scanner ran”: the Trivy file system scan alone flagged 146 vulnerabilities across the dependency tree — 5 critical, 66 high, 61 medium, 14 low — including a critical RCE CVE in @babel/traverse and a high-severity SSRF CVE in axios</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=83b95d76d110" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Built a Three-Tier AWS App With Fully Automated CI/CD — Here’s Everything That Broke Along the…]]></title>
            <link>https://medium.com/@seun.okegbola/i-built-a-three-tier-aws-app-with-fully-automated-ci-cd-heres-everything-that-broke-along-the-805f7c0a0c44?source=rss-54d8a16cd12e------2</link>
            <guid isPermaLink="false">https://medium.com/p/805f7c0a0c44</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[ci-cd-pipeline]]></category>
            <dc:creator><![CDATA[Seun Okegbola]]></dc:creator>
            <pubDate>Sun, 19 Jul 2026 14:22:57 GMT</pubDate>
            <atom:updated>2026-07-19T14:22:57.790Z</atom:updated>
            <content:encoded><![CDATA[<h3>I Built a Three-Tier AWS App With Fully Automated CI/CD — Here’s Everything That Broke Along the Way</h3><p><em>A hands-on walkthrough of deploying a React + Node.js app on AWS with CodePipeline, CodeBuild, and CodeDeploy — built as part of a Cloudboosta project — and the five bugs that taught me more than the tutorial did.</em></p><p>There’s a version of this project that would take an afternoon: launch two EC2 instances, point a load balancer at them, call it done. That’s not what I built, and it’s not what I wanted to build.</p><p>This is a Cloudboosta project — the brief was to design and deploy a three-tier CI/CD pipeline on AWS using CodePipeline, CodeBuild, and CodeDeploy. I wanted a project where a git push actually meant something — where pushing to my tracked branch, aws-codepipeline-ec2, set off a chain reaction that built, tested, and deployed code to production without me ever touching a server. So I built a three-tier architecture on AWS — a React frontend, a Node.js/Express API, and a Multi-AZ MySQL database — each tier isolated in its own subnet, load-balanced, auto-scaling, and wired into two independent CI/CD pipelines with CodePipeline, CodeBuild, and CodeDeploy.</p><p>It’s live right now at selearning.uk, served over HTTPS through CloudFront with a certificate from ACM and DNS through Cloudflare — both well beyond what the original brief asked for.</p><p>This is the story of building it — what each piece does, why it’s there, and the five bugs that actually taught me how AWS networking and IAM work, which no amount of watching a tutorial would have.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cIhm3zPEggBWvVBAUDLg9A.png" /></figure><h3>The Shape of the Thing</h3><p>Picture a restaurant. The dining room is what customers interact with — that’s my presentation tier, a React app served by nginx. The kitchen does the actual work — that’s my application tier, a Node/Express API. The pantry holds the ingredients — that’s RDS MySQL. Customers never walk into the kitchen or the pantry directly; they deal with the dining room, and the dining room talks to the kitchen on their behalf.</p><p>That’s the whole philosophy of a three-tier architecture: each layer only talks to the layer next to it, nothing is exposed that doesn’t need to be, and any one layer can scale independently of the others.</p><p>Concretely, inside a custom VPC (10.0.0.0/16) spanning two Availability Zones:</p><ul><li><strong>Presentation tier</strong> — React app on nginx, EC2 instances in an Auto Scaling Group, behind an internet-facing Application Load Balancer, fronted by CloudFront.</li><li><strong>Application tier</strong> — Node.js/Express API, EC2 instances in a private-subnet Auto Scaling Group, behind an <em>internal</em> ALB reachable only from the presentation tier.</li><li><strong>Data tier</strong> — RDS MySQL, Multi-AZ, private subnets, reachable only from the app tier and a bastion host.</li></ul><p>A bastion host sits in a public subnet as the single controlled SSH entry point into everything private. No application server or database is ever directly reachable from the internet.</p><h3>Wiring the Pipeline</h3><p>Two CodePipelines — one for the frontend, one for the backend — each run Source → Build → Deploy, triggered automatically by a GitHub push via AWS CodeConnections (the current GitHub App-based integration, not the deprecated OAuth webhook flow from a few years back).</p><p>CodeBuild reads a buildspec.yml per tier: install dependencies, pull database secrets from SSM Parameter Store instead of hardcoding them anywhere, build the React production bundle or package the Node app, and hand off a deployable artifact. CodeDeploy then picks that artifact up and runs it through an appspec.yml lifecycle — BeforeInstall stops the old process cleanly, AfterInstall places the new files, ApplicationStart relaunches under PM2 (backend) or reloads nginx (frontend). Deployment groups target the Auto Scaling Groups directly, so instances that come and go through scaling events stay in sync with whatever&#39;s currently deployed.</p><p>Here’s the dashboard, live, pulling real data from RDS through the internal ALB, the first time the whole stack worked end to end:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*oOWRRTnMis0Vj0a21BnNtA.png" /></figure><p>To prove the pipeline was actually automatic and not a lucky one-time run, I made a trivial CSS change — removed a background color — committed it, and pushed. That’s it. No manual trigger.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*99dTzwA-O0mYJK0DDz9z8w.png" /></figure><p>The webhook fired, both pipelines ran end to end:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*7yBl97LVqQoJphRwJggKoA.png" /></figure><p>And the live site updated within about a minute, with zero manual deployment steps taken:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*kq_KGiwt0-RgQ4qZp4lO2A.png" /></figure><p>That, more than anything else in the project, is the payoff: a developer never has to touch a server for a routine release.</p><h3>Where It Actually Got Interesting</h3><p>Tutorials make everything look smooth. Real infrastructure doesn’t. Here are the bugs that taught me the most.</p><h3>The 504 That Wasn’t the API’s Fault</h3><p>The frontend loaded fine. Every call to /api/books hung for about a minute and then died with a 504 Gateway Timeout.</p><p>My first instinct was to blame the app. I checked the application-tier target group — healthy. I SSH’d through the bastion host into the app instance and ran curl localhost:3200/api/books directly — instant, correct response. The application itself was fine. So the fault had to be somewhere in the network path between the presentation tier and the application tier.</p><p>It turned out the application-tier ALB’s security group allowed inbound traffic from the <em>presentation-tier ALB’s</em> security group. But nginx runs on the presentation-tier EC2 instances themselves — it’s those instances, not that ALB, that actually make the call to the application tier. The real source of the traffic was never on the allow list, so every request just sat there until it timed out.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*4COn7rygqWcRspce0TC8pw.png" /></figure><p>The fix was one line: change the inbound rule’s source from the presentation-tier ALB’s security group to the presentation-tier <em>instances’</em> security group. The lesson stuck with me more than the fix did — “traffic that looks like it comes from a tier” and “traffic that actually originates from that tier’s load balancer versus its instances” are not the same thing.</p><h3>IAM Failing One Door at a Time</h3><p>I built the service roles for CodeBuild and CodePipeline with scoped, minimal permissions rather than broad managed policies. The tradeoff is that failures show up one at a time, exactly when each new AWS-to-AWS call is attempted for the first time.</p><p>First: CodeBuild’s webhook registration failed with Access Denied on the CodeConnections ARN — needed codeconnections:UseConnection added to its role. Fixed it, moved on. Then CodePipeline&#39;s Build stage failed with &quot;not authorized to perform: codebuild:StartBuild&quot; — needed that action (plus BatchGetBuilds and StopBuild) added to <em>its</em> role. Fixed it, moved on. Then the Deploy stage failed with &quot;not authorized to perform: codedeploy:CreateDeployment&quot; — same pattern, different role, different action.</p><p>Three failures, three fixes, each one narrower than a “just attach AdministratorAccess and move on” shortcut would have been. That incremental failure pattern is actually a sign least-privilege IAM is working as designed, not a sign something is badly configured.</p><h3>A Broken SSH Tunnel That Was Actually a Network MTU Bug</h3><p>Plain SSH into the bastion host worked fine. But opening an SSH tunnel through it for MySQL Workbench, and then actually pulling real data through that tunnel, failed with client_loop: send disconnect: Broken pipe.</p><p>Authentication wasn’t the issue — the tunnel established. AllowTcpForwarding wasn&#39;t disabled — the tunnel just failed once real payload flowed through it, not on connection. That pattern — fine at small message sizes, breaks at real data volume — pointed at MTU/fragmentation rather than auth or a firewall rule. WSL2&#39;s virtual network adapter had an MTU mismatch with the actual path out. One command fixed it:</p><pre>sudo ip link set eth0 mtu 1400</pre><h3>PM2’s Empty Process List</h3><p>After a deployment, pm2 list on the app instance showed nothing — an empty table — even though the API was clearly running and answering requests.</p><p>PM2 keeps a separate process list <em>per Linux user</em>. The deployment had started the app under root’s PM2 daemon; I was checking as ec2-user, which has its own, completely separate, empty PM2 namespace. sudo pm2 list showed the truth immediately: the process was there, online, healthy. It had been the whole time.</p><h3>A Fast 500 vs. a Slow 504</h3><p>Later, after intentionally stopping and restarting RDS to test failover behavior, the API started returning 500 errors — but fast ones, around 150ms, nothing like the minute-long 504 from earlier.</p><p>The app process itself hadn’t crashed. It had been running <em>before</em> RDS restarted, and its connection pool was still holding references to now-invalid connections — the process was fine, it was just talking to a database endpoint that had changed underneath it. sudo pm2 restart nodeapp-backend forced it to open fresh connections and the errors disappeared.</p><p>The shape of an error is itself a clue: a fast failure points at something breaking immediately in-process, a slow one points at something that never responds at all.</p><h3>Going Past the Assignment</h3><p>Cloudboosta’s brief stopped at a working CI/CD pipeline behind a load balancer. It didn’t require a custom domain or a CDN, but a raw ALB URL isn’t something you’d actually ship, so I added both. CloudFront sits in front of the presentation-tier ALB, serving the app over HTTPS with edge caching. The TLS certificate came from ACM — requested specifically in us-east-1, which is a non-negotiable requirement for any certificate CloudFront uses, no matter what region the rest of the infrastructure lives in. DNS runs through Cloudflare, with the validation and origin records kept in &quot;DNS only&quot; mode rather than proxied, so AWS could complete certificate validation and CloudFront could resolve traffic correctly instead of Cloudflare&#39;s own proxy getting in the way.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*Rg3YLCUAEnbKDSwTp2KUKQ.png" /></figure><h3>What It Actually Taught Me</h3><p>The tools themselves — CodePipeline, CodeBuild, CodeDeploy, ALBs, ASGs — are all well documented. What isn’t well documented is the reasoning that connects them: why traffic sources need to match the real network hop and not just the conceptual tier, why least-privilege IAM fails incrementally rather than all at once, why a database restart can break a process that never crashed.</p><p>None of that shows up by watching someone else build it. It shows up when your own 504 doesn’t match the video’s, and you have to actually go find out why.</p><p>The project is live at selearning.uk. The code, and the rest of the debugging notes, are one git log away.</p><p>Thanks to Cloudboosta for the brief that pushed me to actually build this rather than just read about it — the assignment gave me the destination, but the bugs along the way taught me the map.</p><p><em>If you’re working through a similar build and hit a wall, I’d genuinely like to hear about it — some of the best debugging insight I got on this project came from comparing notes with other people mid-troubleshoot, not from the tutorial itself.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=805f7c0a0c44" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>