を通じてS3Bucketsを作成することができません私は単にリソースセクションに新しいS3Bucketを追加しようとスタックはもう建設されていません。はserverless.yml
resources:
Resources:
myBucket:
Type: AWS::S3::Bucket
Properties:
BucketName: prefix-${self:custom.env.myvar}-myBucket
と私は取得していますエラーは、あまりにも支援していませんずっと: テンプレートのフォーマットエラー:未解決のリソースの依存関係 []で何が起こっているか
任意のアイデアをテンプレート(何を探すべきかを示すことができる[]の間に何もない)のリソースブロックで?
私は、サーバーレスv1.5.0デベロッパーに
serverless.yml
service: myService
frameworkVersion: "=1.5.0"
custom:
env: ${file(./.variables.yml)}
provider:
name: aws
runtime: nodejs4.3
stage: ${opt:stage, self:custom.env.stage}
region: ${self:custom.env.region}
profile: myProfile-${opt:stage, self:custom.env.stage}
memorySize: 128
iamRoleStatements:
- Effect: "Allow"
Action:
- "lambda:InvokeFunction"
Resource: "*"
- Effect: "Allow"
Action:
- "s3:ListBucket"
Resource: { "Fn::Join" : ["", ["arn:aws:s3:::", { "Ref" : "ServerlessDeploymentBucket" } ] ] }
- Effect: "Allow"
Action:
- "s3:PutObject"
Resource:
Fn::Join:
- ""
- - "arn:aws:s3:::"
- "Ref" : "ServerlessDeploymentBucket"
- "Ref" : ""
functions:
myFunction:
handler: functions/myFunction.handler
name: ${opt:stage, self:custom.env.stage}-myFunction
resources:
Resources:
myBucket:
Type: AWS::S3::Bucket
Properties:
BucketName: myService-${opt:stage, self:custom.env.myVar}-myBucket
'serverless.yml'全体を入力してください。設定ファイルのどこかでエラーが発生している可能性が非常に高いです。また、元のエラーでは、 '[]'の間にテキストがありましたか? – wjordan
私はその考えも持っていましたが、ブロックを削除するとすべてが問題なくなりました。これが唯一の新しい追加機能で、エラーの原因となっています。とにかくserverless.ymlで質問を更新します – YOBB