I have a policy statement which I can add to my bucket:
const statement = new PolicyStatement({
effect: Effect.ALLOW,
principals: '*',
actions: ["s3:GetObject"],
resources: [`${bucket.bucketArn}/*`],
});
mybucket.addToResourcePolicy(statement);
However, I have a policy document which contains multiple statements:
const policy = new PolicyDocument({
statements: [// many statements ]
})
How can I attached this to my bucket?