Hey. I want to have option to manual trigger builds with UI when I am using dynamic config.
I have monorepo with X apps but I’m simplifying the config here.
So here’s the .circleci/config.yml
:
version: 2.1
setup: true
parameters:
build:
type: boolean
default: false
orbs:
path-filtering: circleci/path-filtering@1.2.0
workflows:
select-builds:
when:
not: << pipeline.parameters.build >>
jobs:
- path-filtering/filter:
base-revision: master
config-path: .circleci/no-updates.yml
mapping: |
.* config-commands true .circleci/config.commands.yml
.* config-common-jobs true .circleci/config.common.jobs.yml
.* config-executors true .circleci/config.executors.yml
code/.* build true .circleci/workflow.yml
manual-build:
when: << pipeline.parameters.build >>
jobs:
- path-filtering/filter:
base-revision: master
config-path: .circleci/no-updates.yml
mapping: |
.* config-commands true .circleci/config.commands.yml
.* config-common-jobs true .circleci/config.common.jobs.yml
.* config-executors true .circleci/config.executors.yml
.* build << pipeline.parameters.build >> .circleci/workflow.yml
And in my .circleci/workflow.yml
I also have build
parameter as without it the whole thing fails.
---
version: 2.1
parameters:
build:
type: boolean
default: false
orbs:
aws-cli: circleci/aws-cli@5.2.0
aws-ecr: circleci/aws-ecr@9.5.0
jobs:
workflows:
This workflow works when there is a new push to repository without any issues.
But when I am using manual trigger with UI I get
{"message":"Conflicting pipeline parameters."}
Is there any reason why this is happening ? Is there any option to fix this ?
Oh and I tried to change the name in config.yml
to build-ui
or something but then I get error in CircleCI Unexpected argument(s): build-ui
.