Advertisement
Guest User

InstancesEnvironment

a guest
Oct 21st, 2019
2,101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.41 KB | None | 0 0
  1. {
  2. "Version": "2012-10-17",
  3. "Statement": [
  4. {
  5. "Effect": "Allow",
  6. "Action": [
  7. "ssm:StartSession"
  8. ],
  9. "Resource": [
  10. "arn:aws:ec2:*:*:instance/*"
  11. ],
  12. "Condition": {
  13. "StringLike": {
  14. "ssm:resourceTag/Environment": [
  15. "Development"
  16. ]
  17. }
  18. }
  19. },
  20. {
  21. "Effect": "Allow",
  22. "Action": [
  23. "ssm:DescribeSessions",
  24. "ssm:GetConnectionStatus",
  25. "ssm:DescribeInstanceProperties",
  26. "ec2:DescribeInstances"
  27. ],
  28. "Resource": "*"
  29. },
  30. {
  31. "Effect": "Allow",
  32. "Action": [
  33. "ssm:GetDocument"
  34. ],
  35. "Resource": [
  36. "arn:aws:ssm:*:*:document/SSM-SessionManagerRunShell"
  37. ],
  38. "Condition": {
  39. "BoolIfExists": {
  40. "ssm:SessionDocumentAccessCheck": "true"
  41. }
  42. }
  43. },
  44. {
  45. "Effect": "Allow",
  46. "Action": [
  47. "ssm:TerminateSession"
  48. ],
  49. "Resource": [
  50. "arn:aws:ssm:*:*:session/${aws:username}-*"
  51. ]
  52. }
  53. ]
  54. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement