一个github提交创建了多个Codebuild版本

问题描述 投票:1回答:1

我设置了一个测试环境Codebuild + Github,并且遇到了一个问题:每次我在Github中进行提交时,Codebuild都会触发3个相同的构建。

我的buildspec.yml:

version: 0.2

phases:
  pre_build:
    commands:
      # Taskfile
      - curl -sL https://taskfile.dev/install.sh | sh

  build:
    commands:
        - ./bin/task build

  post_build:
    commands:
      - zip -r trigger.zip trigger

artifacts:
  files:
    - 'trigger.zip'
  discard-paths: yes

我的代码构建配置:Codebuild Config

以及我的构建历史:Build History

一些值得注意的事情:

  1. 手动构建仅触发一个构建
  2. 这三个构建来自相同的钩子和源版本
  3. 在github中,提交仅引用3个构建中的第一个(最新的提交指向构建13,先前的提交指向构建9,依此类推。)>
  4. 我的项目只有一个分支(主)
  5. 您是否知道为什么会发生这种情况,以及如何防止这种情况再次发生?

我设置了一个测试环境Codebuild + Github,并且遇到了一个问题:每次我在Github中进行提交时,Codebuild都会触发3个相同的构建。我的buildspec.yml:版本:0.2个阶段:...

github aws-codebuild git-webhooks
1个回答
0
投票

感谢您使用AWS CodeBuild。

© www.soinside.com 2019 - 2024. All rights reserved.