How to configure Alexa ask-cli with a valid AWS profile?

梦想的初衷 提交于 2019-12-04 02:34:56
Naveen Kumar

You need to first download and install aws CLI on your local machine. You can download aws CLI from below link.

http://docs.aws.amazon.com/cli/latest/userguide/installing.html

If you are working with your root account user then you have to generate your access ID and secret key else you have to create new IAM user with lambda execute permission.

You can generate root user access ID and secret key from below link. https://console.aws.amazon.com/iam/home

Then click on Manage Security credential as shown in below image and after ignoring the warnings you can process and click Access Key ID and secret key link and generate new one and copy them.

Run aws configure command to configure your aws account and it will ask for Access ID and secret key that you generated and will setup your aws account.

aws configure

After aws configure, you can run again ask init command again to configure account.

ask init

Well, you don't need to setup an aws-cli when you already have an ask-cli installed.

Instead you can run below command to setup AWS credentials and link to an ASK profile, if somehow aws credentials are not setup.

ask init --aws-setup

Then, you will be prompted to enter your profile name, your access key, and your secret access key. You can use profile name as default if you have not created multiple ASK profiles. This will automatically create an aws credentials file at %USERPROFILE%.aws\credentials location. Now every time you try to deploy/access lambda code through ask-cli, it will access the credentials from this file.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!