【问题标题】:Errors on using CodeBuild for first time首次使用 CodeBuild 时出错
【发布时间】:2019-01-06 15:49:13
【问题描述】:

当作为简单代码管道的一部分启动代码构建时,我会在几秒钟内收到以下错误。

Action execution failed
Error calling startBuild: Cannot have more than 0 builds in queue for the account (Service: AWSCodeBuild; Status Code: 400; Error Code: AccountLimitExceededException; Request ID: 80bfxxxxx

我已使用 AWS 代码管道向导创建了一个简单的构建和部署过程,因此我认为这是错误配置。

我的问题是它指的是什么队列?我是在隔离任何其他 AWS 任务的情况下运行此构建?

有关信息,这是我的 buildspec.yml,虽然我怀疑在访问它之前构建失败:

version: 0.2

env:

phases:
  install:
    commands:
      - echo Entered the install phase...
      - apt-get update -y
      - apt-get install -y maven
    finally:
      - echo This always runs even if the update or install command fails 
  pre_build:
    commands:
      - echo Entered the pre_build phase...
      - cd server/harvest
    finally:
      - echo This always runs even if the login command fails 
  build:
    commands:
      - echo Entered the build phase...
      - echo Build started on `date`
      - mvn package
    finally:
      - echo This always runs even if the install command fails
  post_build:
    commands:
      - echo Entered the post_build phase...
      - echo Build completed on `date`
artifacts:
  files:
    - target/harvest-1.0-SNAPSHOT.jar
  discard-paths: yes

【问题讨论】:

  • 我也有同样的问题。

标签: amazon-web-services aws-codepipeline aws-codebuild


【解决方案1】:

听起来像是帐户问题。此错误通常意味着您使用的帐户未激活(至少对于 CodeBuild 订阅而言不是),因此不允许在 CodeBuild 中启动任何构建。请联系 AWS 支持以激活您的账户。

【讨论】:

  • AWS 告诉我这个错误不是由于 Code Build 配置,而是我的帐户设置中的错误,一旦修复 Code Build 开始工作
  • 出了什么问题?你能告诉我们你是怎么解决的吗? @Mazerunner72
【解决方案2】:

您的帐户限制当前似乎出于某种原因设置为 0。为了提高此限制并能够使用 codebuild,您需要联系 AWS 支持。

【讨论】:

  • 这很奇怪,但这对我有用。默认帐户限制为 60,您必须要求更高。我要求加薪到 61,他们将其设置为 60,然后 CodeBuild 开始工作。
【解决方案3】:

我在网上看到很多建议致电支持的答案,这是个好主意,但实际上我自己能够解决这个问题。

作为 root 用户,我进入并输入了一张当前的信用卡。当前存在的那个已经过期了。然后我删除了我的 CodeBuild 项目并重建了它。现在我的构建工作了!我很确定 AWS 在允许我使用高级服务之前只需要一种有效的付款方式。

我的解决方案可能不适合你,但我希望它可以!

【讨论】:

    【解决方案4】:

    检查区域。您的帐户不会在当前区域设置代码构建。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-05-18
      • 2017-12-03
      • 2015-02-24
      • 2022-11-08
      • 1970-01-01
      • 2015-08-06
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多