问题
I believe my configuration is valid after reading the CircleCi workflow documentation but I am still getting the error below. What is wrong with my configuration?
Here is my workflow configuration:
workflows:
version: 2
build_assemble_deploy:
jobs:
- build
- assemble:
requires:
- build
filters:
branches:
only: master
- deploy:
requires:
- assemble
filters:
branches:
only: master
And here is the full error CircleCi gives me:
Build-agent version 0.1.799-f865b43f (2018-10-11T12:48:06+0000) Configuration errors: 1 error occurred:
- In step 2 definition: Invalid step structure (expected string or map, got config.StepDescription)
回答1:
The workflow configuration is fine. The issue is in the definition of step 2, in this case the definition of the assemble
job. The definition is found in the configuration under job:
> assemble:
.
In this case the issue was an extra -
character. This was the configuration:
- attach_workspace:
- at: ~/dir
The correct configuration is:
- attach_workspace:
at: ~/dir
来源:https://stackoverflow.com/questions/56773696/invalid-step-structure