From the course: Building Dynamic Websites using AWS Lambdas

Static websites are a starting point - Amazon Web Services (AWS) Tutorial

From the course: Building Dynamic Websites using AWS Lambdas

Start my 1-month free trial

Static websites are a starting point

- [Instructor] As we get going together, I want to take just a little bit of a trip down, what may be memory lane for you, or just a quick refresher and that's beginning with the realization that a static website is just a collection of files. And if you happen to have gone through the previous course on setting up a static, serverless website, you already know this because we have put all of our HTML, CSS, JavaScript into an S3 bucket. And then we set that S3 bucket up to serve content in a way that the browser understands, and in particular, that the browser will render. But even basic websites are going to need some level of interactivity. We've become accustomed to our websites being, perhaps, static content but feeling like they're doing something more, whether that's an image carousel on the front page or menus collapsing and expanding, there's always some degree of interactivity to make a website interesting. And probably the most common example of this is to simply use JavaScript. So, taking a look at the Wisdom Pet Medicine website, which, if you followed along, we developed in the last course and if you're new to this course, will be available through the downloadable Exercise Files. This site is a static site, but it already uses some JavaScript. For instance, there's an image rotator on this first page. What we want to do is we want to press into that a little bit more and develop some additional interactivity, but do it in a way that allows us to still take advantage of a serverless framework. So, we're going to build a contact form as part of this website. It's a very simple feedback form that would allow you to rate your experience, to provide a comment, and then to submit that. And then eventually that form is going to shoot off an email using Amazon Services and provide some basic feedback to the user letting them know that their feedback has been received. Now, we're going to do this using something called AWS Lambda. Lambda is to code very similar to what you've been using S3 for in relation to HTML and CSS. It is a way to run, in this case, code without having to mess around with servers and frameworks. And Lambda can run Node code, which is a flavor of JavaScript, Python, Java, .NET, Ruby, Go, all sorts of things. Now, I give them credit for having a pretty broad set of things you can use, so if you are interested in serverless dynamic code, but don't want to use Node, don't worry about it. You can apply everything we do in this course and it's actually only a couple of videos where we're dealing with JavaScript and in those videos, you can insert your own favorite flavor of code. So, let's get going. We need to start simple. We want to take the traditional idea of a web server running code and convert it to Lambda running code and then we're going to have to wire everything together. By the end of this course, you will have set up a couple of things in AWS that allow you to focus on your code, not servers, runtimes, and patching and keeping those things up to date. Let's get into it.

Contents