https://docs.aws.amazon.com/codecommit/latest/userguide/notification-rule-create.html

或者用命令行工具生成notificaiton rule

aws codestar-notifications create-notification-rule --generate-cli-skeleton > rule.json

编辑rule.json

  

{
    "Name": "MyNotificationRule",
    "EventTypeIds": [
        "codecommit-repository-branches-and-tags-created"
    ],
    "Resource": "arn:aws:codecommit:us-east-1:123456789012:MyDemoRepo",
    "Targets": [
        {
            "TargetType": "SNS",
            "TargetAddress": "arn:aws:sns:us-east-1:123456789012:MyNotificationTopic"
        }
    ],
    "Status": "ENABLED",
    "DetailType": "FULL"
}

 

notification和trigger的区别?-------我暂时还没搞明白

 

 

posted on 2021-12-27 17:01  吃鱼高手  阅读(36)  评论(0)    收藏  举报