进行构建时配置处理错误circle-ci

时间:2020-10-22 07:50:14

标签: yaml circleci

我遇到配置处理错误(circ-ci)的问题。

我使用的材料

  • AWS云战线
  • aws s3
  • circle-ci

情况

我确实在AWS上进行了设置,并为环境变量(circle-ci)增加了价值。我确实在git上进行了提交,并在circle-ci上进行了构建,并且发生了错误,但我无法排除此错误。

这是我的repo

错误

 bin/sh -eo pipefail
     ERROR IN CONFIG FILE:
     [#/jobs] 8 schema violations found
     Any string key is allowed as job name.
     1. [#/jobs/deploy-to-aws-cloudfront] 0 subschemas matched instead of one
     |   1. [#/jobs/deploy-to-aws-cloudfront] only 1 subschema matches out of 2
     |   |   1. [#/jobs/deploy-to-aws-cloudfront] 3 schema violations found
     |   |   |   1. [#/jobs/deploy-to-aws-cloudfront] required key [steps] not found
     |   |   |   2. [#/jobs/deploy-to-aws-cloudfront/docker/0] 2 schema violations found
     |   |   |   |   1. [#/jobs/deploy-to-aws-cloudfront/docker/0] extraneous key [steps] is not permitted
     |   |   |   |   |   Permitted keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - name
     |   |   |   |   |     - entrypoint
     |   |   |   |   |     - command
     |   |   |   |   |     - user
     |   |   |   |   |     - environment
     |   |   |   |   |     - aws_auth
     |   |   |   |   |     - auth
     |   |   |   |   |   Passed keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - working_directory
     |   |   |   |   |     - steps
     |   |   |   |   2. [#/jobs/deploy-to-aws-cloudfront/docker/0] extraneous key [working_directory] is not permitted
     |   |   |   |   |   Permitted keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - name
     |   |   |   |   |     - entrypoint
     |   |   |   |   |     - command
     |   |   |   |   |     - user
     |   |   |   |   |     - environment
     |   |   |   |   |     - aws_auth
     |   |   |   |   |     - auth
     |   |   |   |   |   Passed keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - working_directory
     |   |   |   |   |     - steps
     |   2. [#/jobs/deploy-to-aws-cloudfront] expected type: String, found: Mapping
     |   |   Job may be a string reference to another job
     2. [#/jobs/deploy-to-aws-s3] 0 subschemas matched instead of one
     |   1. [#/jobs/deploy-to-aws-s3] only 1 subschema matches out of 2
     |   |   1. [#/jobs/deploy-to-aws-s3] 3 schema violations found
     |   |   |   1. [#/jobs/deploy-to-aws-s3] required key [steps] not found
     |   |   |   2. [#/jobs/deploy-to-aws-s3/docker/0] 2 schema violations found
     |   |   |   |   1. [#/jobs/deploy-to-aws-s3/docker/0] extraneous key [steps] is not permitted
     |   |   |   |   |   Permitted keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - name
     |   |   |   |   |     - entrypoint
     |   |   |   |   |     - command
     |   |   |   |   |     - user
     |   |   |   |   |     - environment
     |   |   |   |   |     - aws_auth
     |   |   |   |   |     - auth
     |   |   |   |   |   Passed keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - working_directory
     |   |   |   |   |     - steps
     |   |   |   |   2. [#/jobs/deploy-to-aws-s3/docker/0] extraneous key [working_directory] is not permitted
     |   |   |   |   |   Permitted keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - name
     |   |   |   |   |     - entrypoint
     |   |   |   |   |     - command
     |   |   |   |   |     - user
     |   |   |   |   |     - environment
     |   |   |   |   |     - aws_auth
     |   |   |   |   |     - auth
     |   |   |   |   |   Passed keys:
     |   |   |   |   |     - image
     |   |   |   |   |     - working_directory
     |   |   |   |   |     - steps
     |   2. [#/jobs/deploy-to-aws-s3] expected type: String, found: Mapping
     |   |   Job may be a string reference to another job
     
     -------
     Warning: This configuration was auto-generated to show you the message above.
     Don't rerun this job. Rerunning will have no effect.
    false

1 个答案:

答案 0 :(得分:0)

Config处理错误忽略了Circle-ci上的架构的原因。 就我而言,这是一个缩进错误。

https://github.com/CircleCI-Public/circleci-cli/issues/326

这篇文章有助于解决我的错误。