-
Download node and npm: https://nodejs.org/en/download/
-
Download Postman: https://www.postman.com/downloads/
-
Download Git https://git-scm.com/downloads
-
Create a github account (if you don't already have one) https://github.com/
-
Go to the project repo: https://github.com/ajohnson10209/AOT-Fellowship and fork the repo (Slide 36).
-
Clone the repo
$ git clone https://github.com/your-repo
- Mac users, Install Java: https://www.java.com/en/download/help/mac_install.html
- If not already installed, get the AWS CLI tools following the instructions here pertaining to your OS: https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html
- Configure you aws account using the instruction here. You will need to create a new key pair if you do not already have one: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-quickstart.html
- Update the profile setting in the serverless.yml file to "default" if you only have one profile. Otherwise follow the instructions here for creating a named profile https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html
- Run the following command in your terminal
$ npm install -g serverless
- In your terminal, change your directory into the project directory
$ cd AOT-Fellowship
- Run the following command in your terminal to install all dependencies
$ npm install
- Set up local DynamoDB
$ sls dynamodb install
- Start local sever
$ sls offline start
- Use Postman to call your local server
In order to deploy the example, you need to run the following command:
$ serverless deploy
After running deploy, you should see output similar to:
Deploying aot-fellowship-demo to stage dev (us-east-1)
✔ Service deployed to stack aot-fellowship-demo-dev (112s)
functions:
showtime: aot-fellowship-demo-dev-showtime (1.5 kB)
After successful deployment, the url for your api will be in the command line
Use Postman to call your api endpoints
Once you are finished, you will send your code into your github account
- Run the following commands in your terminal
$ git add .
$ git commit -m "Add a description of your work"
$ git push origin master