官术网_书友最值得收藏!

Prerequisites 

First of all, you need an AWS account. If you don't have an account, you can sign up for an account at https://aws.amazon.com/:

While clicking on the Create a Free Account and then following the onscreen instructions will give you 12 months' free access to several services, you will still need to provide credit or debit card details and it is possible that you could incur costs.

For more information on the AWS free tier, please see https://aws.amazon.com/free/. This page lets you know which instance sizes and services are covered by the 12 months of free service, as well as letting you know about non-expiring offers on other services, which include AWS Lambda.

Once you have your AWS account, you should create a user using the AWS Identity and Access Management (IAM) service. This user can have administrator privileges and you should use that user to access both the AWS Console and the API.

For more details on creating an IAM user, see the following pages:

Using your AWS root account to launch services and access the API is not recommended; if the credentials fall into the wrong hands you can lose all access to your account. Using an IAM rather than your root account, which you should also lock down using multi-factor authentication, means that you will always have access to your AWS account.

The final prerequisite is that you need access to the AWS command-line client, where I will be using macOS, but the client is also available for Linux and Windows. For information on how to install and configure the AWS command-line client, please see:

When configuring the AWS CLI, make sure you configure the default region as the one you will be accessing in the AWS web console, as there is nothing more confusing than running a command using the CLI and then not seeing the results in the web console.

Once installed, you can test that you can access AWS Lambda from the command-line client by running:

$ aws lambda list-functions

This should return an empty list of functions like the one shown in the following screenshot:

Now that we have an account set up, created, and logged in using a non-root user, and we have the AWS CLI installed and configured, we can look at launching our first serverless function.

主站蜘蛛池模板: 凤翔县| 乐清市| 自治县| 平陆县| 汝城县| 内江市| 新龙县| 南澳县| 马关县| 天等县| 资中县| 金乡县| 和平区| 旬邑县| 大姚县| 娱乐| 宜宾市| 苍梧县| 汤原县| 大丰市| 图木舒克市| 玉屏| 泽普县| 荔浦县| 于田县| 南岸区| 新河县| 永顺县| 阿拉善左旗| 泸州市| 哈尔滨市| 韩城市| 中超| 女性| 桓台县| 宜州市| 伊吾县| 闽侯县| 雅安市| 仁怀市| 永平县|