Richtlinie zur Aktivierung der Automatisierung in Ihrer gesamten Organisation - AWS SDK-Codebeispiele

Weitere AWS SDK-Beispiele sind im GitHub Repo AWS Doc SDK Examples verfügbar.

Die vorliegende Übersetzung wurde maschinell erstellt. Im Falle eines Konflikts oder eines Widerspruchs zwischen dieser übersetzten Fassung und der englischen Fassung (einschließlich infolge von Verzögerungen bei der Übersetzung) ist die englische Fassung maßgeblich.

Richtlinie zur Aktivierung der Automatisierung in Ihrer gesamten Organisation

Das folgende Codebeispiel zeigt, wie Sie mit dieser berechtigungsbasierten Richtlinie die Automatisierung in Ihrer gesamten Organisation aktivieren

JSON
{ "Version":"2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "iam:CreateServiceLinkedRole", "Resource": "arn:aws:iam::*:role/aws-service-role/aco-automation.amazonaws.com/AWSServiceRoleForComputeOptimizerAutomation", "Condition": {"StringLike": {"iam:AWSServiceName": "aco-automation.amazonaws.com"}} }, { "Effect": "Allow", "Action": [ "iam:PutRolePolicy", "iam:AttachRolePolicy" ], "Resource": "arn:aws:iam::*:role/aws-service-role/aco-automation.amazonaws.com/AWSServiceRoleForComputeOptimizerAutomation" }, { "Effect": "Allow", "Action": "aco-automation:UpdateEnrollmentConfiguration", "Resource": "*" }, { "Effect": "Allow", "Action": "aco-automation:AssociateAccounts", "Resource": "*" }, { "Effect": "Allow", "Action": "aco-automation:DisassociateAccounts", "Resource": "*" }, { "Effect": "Allow", "Action": "aco-automation:ListAccounts", "Resource": "*" } ] }