- DevOps for Serverless Applications
- Shashikant Bangera
- 169字
- 2021-07-16 17:35:35
Resources
When we create Lambda functions, they might be dependent on many different types of infrastructure resources, such as AWS, DynamoDB or AWS S3, so we can define these resources within the serverless.yml file and deploy them. When we add these resources, they get added to the serverless.yml file, and when they are deployed, they get added to the CloudFormation stack and are executed at serverless deploy. We can look at the following example to see how these resources are defined:
resources:
Resources:
NewResource:
Type: AWS::S3::Bucket
Properties:
BucketName: my-s3-bucket
You can refer to the following link for more details on resources and to see which resources are available using only AWS Lambda: https://serverless.com/framework/docs/providers/aws/guide/resources/
Let's look at a simple example of Serverless Framework using AWS Lambda.
You will need the following prerequisites for this:
- A free AWS account needs to be created
- Nodejs 4.0 and higher must be installed on the local machine
- AWS CLI can also be installed, but this is optional
推薦閱讀
- Linux設(shè)備驅(qū)動開發(fā)詳解(第2版)
- Hands-On DevOps with Vagrant
- 新手易學(xué):系統(tǒng)安裝與重裝
- Java EE 8 Design Patterns and Best Practices
- Mobile First Design with HTML5 and CSS3
- Linux命令行大全(第2版)
- 計算機應(yīng)用基礎(chǔ)(Windows 7+Office 2016)
- Social Data Visualization with HTML5 and JavaScript
- Introduction to R for Quantitative Finance
- Linux軟件管理平臺設(shè)計與實現(xiàn)
- Learning Continuous Integration with Jenkins(Second Edition)
- OpenVZ Essentials
- Windows 8玩全不求人
- Docker for Developers
- 你必須掌握的Windows 8技巧