![]() ![]() Please let us know if you were able to have any success using the approach Fernando or I suggested.CircleCI is a modern continuous integration and continuous delivery (CI/CD) platform. I added it as a pre-step so that deploy.yml is available in the set-up container. The checkout step is defined within the orb source for the continuation/continue job, but for some reason was not executing. ![]() Both the parameter I am passing in with the API and the other parameter I am passing in with the orb jobs had to be declared in deploy.yml.The parameter I am passing in ( my-pipeline-param-api) had to be different than the name of the parameter I am passing in with the continuation/continue job.There were a couple of things I had to adjust for when using both orbs: This approach uses both of the orbs in the config.yml file. Where $CIRCLECI_TOKEN is my user api token. header "Circle-Token: $CIRCLECI_TOKEN" \ run: echo $'Ī sample curl api request I used to test: curl -location -request POST '' \ This gets passed into the continuation config. With a yml-file parameter that contains the string main.yml. You’ll notice that I have pipeline parameters defined in this config at the top. So for example I have this setup config.yml: version: 2.1Ĭontinuation: "THIS IS A SETUP CONFIG PARAM"Ĭonfiguration_path: ".circleci/continue/>"Īnd in this folder I have two continuation configs. This lets you call the same pipeline from an existing pipeline, and then uses a different continuation config file to modify the result of the new pipeline. Hopefully someone who understands this better can provide an improved answer. Check out the continuation orb example as that may make this easier for you and remove the need craft your own API calls. This post here may help break down what you need to do for continuing the pipeline. If you’re trying to launch a completely separate pipeline then you would use the API pipeline endpoint in your original post, but I think the parameters would need to be defined in your config.yml. If you’re trying to continue the pipeline and call new workflows from the setup workflow you should use the continue API endpoint above. You can see it has some input for the parameters that you have defined in your deploy.yml. ![]() Check out the API docs are here for the endpoint. The endpoint to continue a pipeline and trigger more workflows from within the setup workflow is different. So I think it would be expecting the parameters you’ve defined to be in your setup config rather than the generated config. ![]() This would trigger a completely separate pipeline, rather than continuing the pipeline from your setup workflow. In your initial example, you’re trying to kick off a pipeline using the endpoint. I think it’s the endpoint that you’re calling from within the setup workflow. Somedir/somefile.yml my-pipeline-param true Here is a minimal example of how my CircleCI project is set up: Then in the CircleCI pipeline UI I get a build error of the form: Unexpected argument(s): my-pipeline-paramĬan these two features not be used together? When I send this, I get a setup-pending response. header 'Content-Type: application/json' \ header 'Circle-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxx' \ Now we want to use the API to also trigger workflows from this project, with: curl -location -request POST '' \ We have a project that uses dynamic configs and the orb to do conditional builds in a monorepo. ![]()
0 Comments
Leave a Reply. |