
Lesson Description
The "The Growth Phase" Lesson is part of the full, Cloud Infrastructure: Startup to Scale course featured in this preview video. Here's what you'd learn in this lesson:
Erik introduces the Growth Phase. This phase will focus on infrastructure improvement that allows multiple developers to work on the application. A CI/CD pipeline with GitHub Actions to run tests and deploy the application. Database migrations will also be added.
Transcript from the "The Growth Phase" Lesson
[00:00:00]
>> Erik Reinert: We're gonna go into the growth phase now. I do feel confident that you guys had a good experience of what the startup phase feels like. So let's try and improve it a little bit, right? We do wanna make it so that we can not have so much.
[00:00:14]
We do wanna get rid of those headaches. We wanna get rid of the headaches of maybe deploying and some of the other stuff that we have to deal with. We don't wanna change everything, but just some things, right? Here's our phase scenario for phase two. So we're shipping code, right?
[00:00:30]
We have no integration process though, right? So we don't really have any way of running tests or doing tests, right? We don't have a real delivery process. We do, but it still means that we have to manually build the image ourselves to deploy things, right? When we go back to that chart, right, the computer on the right is connected directly to the resources and that's because you have to manage those resources.
[00:00:55]
So we wanna replace that. We don't wanna do that. We wanna have some kind of actual delivery process. However, we don't wanna replace anything massive. We're not ready to get out of App Runner yet, we like App Runner, it works, maybe some dev on the team's like, I hate App Runner, it's fine, it works.
[00:01:12]
We can keep moving, right? So we don't wanna really change anything on that side of things, but maybe there's other things that we can do to kind of make this move and our growth a little bit faster. The goals in this phase are we want to improve data reliability.
[00:01:32]
As you recall, we manually copy and pasted SQL statements. We weren't really doing a great job of managing our data. And when you're managing a company especially you want to manage that data. Well, right, does anyone guess or can anyone guess what I may be alluding to that we might be missing?
[00:01:55]
They've been around forever. It has relation to databases. What's the one thing we have to run whenever we make changes to?
>> Male Student 1: Migrations.
>> Erik Reinert: Migrations, exactly, yeah, so we have no migrations, right? It's just copy and paste data and run. Migrations is missing here, right? We wanna improve data reliability through that.
[00:02:13]
We wanna improve the developer experience. Again, it was a little clunky to get everything up and running and running commands and stuff. It was like, where's this? Again, that was purposeful for you guys to have to remember. I hate remembering commands [LAUGH]. Right, there's a way of solving that and I'm gonna show you how to do that.
[00:02:33]
We need to create an actual integration solution. So we want CI. We want an actual CI that we can lean on. We want also a delivery solution. We want a way of actually leaning on something that will deliver our changes as well for us, right? So again, four big takeaway or the four big goals, data reliability, developer experience, integration, and delivery, right?
[00:02:56]
Requirements for this are exactly as the other one. This is why I said it's a lot easier once we get through the first phase, cuz all the other phases build on top of it. And it's supposed to feel that way, right? It's supposed to feel like, okay, we already did this, I don't wanna have to go back and do that again, right?
[00:03:12]
So, yeah, pretty much all the same requirements. You don't need to set anything else up. You guys have all your AWS and everything working so fantastic. This is what we're gonna be building, right? Now you might look at it and say, okay, well, it looks pretty similar, and it is, as a matter of fact, the front end side of it, right?
[00:03:31]
The client experience, how App Runner works, what it talks to and what it communicates with is pretty much the same. However, you'll notice that there's space between the developers and the resources and this is purposeful, right? Once you get to a point where you get more than one developer, you need to figure out a way of separating them from the resources and the infrastructure, because that's more possibility of them breaking things or more possibility of things happening, right?
[00:04:03]
And so what we're doing and the focus of this really to grow through or to grow into the next part. Again, we're not just growing the application, we're growing the team, right? The team needs to be able to deploy things automatically. The team needs to be able to update schemas and stuff.
[00:04:19]
So with that, when we talk about growth, we're talking about the entire growth of the organization, not just the application itself. If the application itself grew, just the application itself grew, none of this would need to change. Why would it? It's just you, you know what I mean?
[00:04:34]
But when you start talking about two people, four people, ten people, 20 people, having a delivery process and something that automates all of those things for you is still pretty critical. Now, one thing you will note is that configuration is still manual, but that's always gonna be manual, right?
[00:04:51]
Somebody's gonna have to go in and update a configuration somewhere and then deploy that configuration, whether it be Vault, Secrets Manager, whatever, right? We're just using Secrets Manager as a depot for all of our configs and then our applications run from those, right? So that doesn't really change much.
[00:05:10]
But everything else for now is staying exactly or sorry, besides that staying the same, everything else is gonna kinda change and how we interact with it. So I'm gonna show you really quickly where you can find the things because honestly, we are not gonna do what we did last time.
[00:05:23]
This time I am gonna have you guys copy stuff. We are gonna move fast. So there's a few things I want you to note. The first thing that is if you go into the fem-fd-service repo, you will now see a stage-02-growth branch in here. The first thing you'll notice is we have a migrations directory now that we're gonna be adding.
[00:05:45]
And inside of that you'll actually see our first migration file. And if we click on that, hey, look at that. It's the readme stuff, right? We created our migration out of our schema in our readme, right? So we're gonna go through that. I'm gonna show you guys how many here knows what a make file is.
[00:06:06]
Okay, we've got one person who knows. So if you don't know what a makefile is, it's been around for a long time. But this is how a lot of like older system or a lot of older applications were built. But this is a file that can help you run commands effectively.
[00:06:22]
It makes it so that all the commands and all the stuff that you run locally, you can actually abstract that away and make it so that you just can run much simpler commands. And as I scroll through this, you can kind of tell there's a lot in here.
[00:06:34]
So we're gonna be doing that. We're also gonna be updating the docker file. You'll notice that this dockerfile is a little bit more intricate than the other one. And that's purposeful. We're making some changes there for specific reasons. And then the last and most important thing is you'll notice here, next to my commit, I have a little green check mark.
[00:06:53]
Well, that's because we're also going to be setting up a continuous integration and delivery pipeline with which will build our code, test it, and then optionally deploy it when ready. For all of you that have open PRs right now with your changes, go ahead and merge them for me.
[00:07:10]
So go ahead and merge that into main for me if you guys are good. So go ahead and take all your changes that you have in your branch, whether your deployment's working or not. Don't worry about it, it's just the docker file. But go ahead and take all those changes and then just merge them in your PR for me.
[00:07:25]
So you'll wanna go to your PR here. Now, I'm not gonna merge mine, but just go ahead and do that for me. You can do squash and merge. You can do whatever you want, but just go ahead and merge those changes for me.
Learn Straight from the Experts Who Shape the Modern Web
- In-depth Courses
- Industry Leading Experts
- Learning Paths
- Live Interactive Workshops