1
Fork 0
mirror of https://github.com/RealOrangeOne/notes.git synced 2024-12-22 19:05:59 +00:00

Improve wording for bucket transfer note

This commit is contained in:
Jake Howard 2022-09-20 17:23:59 +01:00
parent 312b5f0c10
commit dac716e745
Signed by: jake
GPG key ID: 57AFB45680EDD477

View file

@ -6,8 +6,10 @@ link: https://aws.amazon.com/premiumsupport/knowledge-center/cross-account-acces
emoji: 🪣 emoji: 🪣
--- ---
1. Create S3 bucket in account A To copy bucket contents from bucket in account A to bucket in account B:
2. Create IAM role / user in account B
1. Create new S3 bucket in account B
2. Create IAM role / user in account B, with access to destination bucket
3. Add IAM inline policy to user: 3. Add IAM inline policy to user:
```json ```json
@ -16,14 +18,17 @@ emoji: 🪣
"Statement": [ "Statement": [
{ {
"Effect": "Allow", "Effect": "Allow",
"Action": "*", "Action": "s3:*",
"Resource": "arn:aws:s3:::<bucket>/*" "Resource": [
"arn:aws:s3:::<source_bucket>/*",
"arn:aws:s3:::<source_bucket>"
]
} }
] ]
} }
``` ```
4. Add policy to bucket 4. Add policy to source bucket
```json ```json
{ {
@ -34,8 +39,8 @@ emoji: 🪣
"Principal": { "Principal": {
"AWS": "arn:aws:iam::<account_id>:user/<user>" "AWS": "arn:aws:iam::<account_id>:user/<user>"
}, },
"Action": "*", "Action": "s3:*",
"Resource": ["arn:aws:s3:::<bucket>/*"] "Resource": ["arn:aws:s3:::<source_bucket>/*", "arn:aws:s3:::<source_bucket>"]
} }
] ]
} }