RESTful and HTTP APIs in Pyramid Transcripts
Chapter: Deploying your REST service to DigitalOcean on Ubuntu
Lecture: DigitalOcean overview

Login or purchase this course to watch this video and the rest of the course contents.
0:01 Here we are on Digital Ocean, you've maybe heard of Digital Ocean, I am a huge fan of what those guys are doing,
0:09 you probably heard of things like aws and azure, but I'm here to tell you for simpler, not extremely complicated web applications
0:18 that have to dig into all of these cloud apis, this is a better place to be;
0:23 it really is better performance and much, much cheaper, and really just simpler. We're going to use Digital Ocean to go create this Linux server.
0:30 Now, let's click really quickly on pricing, just so you guys see like what it is we're going to create,
0:35 so the pricing is really nice here, we're going to use a standard droplet and pay, we can get hourly price if we want,
0:42 but really monthly is a better human term to think about what is it going to cost us, they also have like high memory ones, and whatnot,
0:49 but we're just going to focus down on these standard ones. So we're going to use a five dollar server, and you'll see that this five dollar server
0:56 will run our api for many, many requests, I'm pretty sure we could get millions of requests per month for five dollars.
1:02 And just to indicate like what a good deal this is, last time I checked the pricing for just bandwidth alone at aws was nine cents per gigabyte,
1:12 notice you get a terabyte of bandwidth here, so 0.09 times that many gigabytes, that's 92 dollars a month
1:19 just in bandwidth value that you get with his thing, not to mention you get ssds and all sorts of goodies.
1:25 So what we're going to do is we're going to go create one of these, now, I have already created an account, so logged in here
1:31 you can see my various servers that I used to run the Talk Python and Python Bytes stuff and we're going to go and create a new droplet,
1:39 so let's go down here and and show you what you get so we can come down, we can pick a variety of different Linux distributions,
1:46 and pick different versions as well, so let's just go with this one, the standard long term support Ubuntu, there's not a real great reason
1:57 to choose a different one, I will just point out though that you can go if you want to and get it kind of pre configured, like from my Mongodb server
2:03 I just went down here and said I want Mongodb running on that version of Ubuntu
2:07 and boom, it already comes preconfigured, somewhat secure, things like that. But we're not using Mongo, so we'll use this
2:14 and pick this size, you'll see that that's plenty good we don't need block storage right now
2:22 we could get a different data center so I'm on the west coast of the US so I'll pick something in San Francisco
2:28 and then we just have to create an ssh key, we click go, give it a name, and let's call this auto service server something like that
2:38 it seems like a decent name, we can have a bunch, I don't want a bunch, I want one, and we'll get going.
2:43 So, that's how it will work, we're going to need to do things like create an ssh key,
2:47 so that we can log in and not have to worry about passwords, and things like that, but we'll do that in just a moment, right.
2:54 So Digital Ocean basically lets us create these servers and then we can go over to the networking section which we'll do afterwards
3:01 and we can basically get it's called a floating ip address, and what that means is there an ip address that kind of
3:08 we control independent of the machine and we can map our domain to that and then we can do things like hey I need to upgrade the server
3:14 I could move it over to a temporary fail over server if for some reason I want to just create a new version after six months
3:21 on a new implementation of Linux or whatever I could spin that up and get it exactly ready
3:26 and then I could just instantly flip the switch, and it will flip to that new server. So it gives you a little bit of machine independence,
3:32 with this networking section, so we're going to do that next, but first, in order to create this, we're going to create an ssh key.


Talk Python's Mastodon Michael Kennedy's Mastodon