1

在 PowerShell 上,我定义了两个环境变量来定义 AWS 密钥和访问密钥:

$AWS_ACCESS_KEY_ID="AAAA"
$AWS_SECRET_ACCESS_KEY="CCCC"

PS C:\Users\Obaid\serverless\helloJava> serverless deploy
Serverless: Packaging service...

Serverless Error ---------------------------------------

ServerlessError: AWS provider credentials not found.
Learn how to set up AWS provider credentials in our docs (...)

为什么无服务器会选择我的凭据?

4

1 回答 1

2

您必须像这样在powershell中设置环境变量

$env:AWS_ACCESS_KEY_ID="AAAA"
$env:AWS_SECRET_ACCESS_KEY="CCCC"
于 2018-01-30T08:51:36.510 回答