Would like to have new 1st glass feature for generating additional "state" data based on the current state that can be generated on demand. This would be configured in app pipeline config files under the classification generators
.
cicd-contexts:
dev:
pipelines:
build:
generators:
dockerfile:
alpine:
if: "{%- 'alpine' in state.gitTag -%}true{%- endif -%}"
set:
- key: "state.build.targetImageName"
value: "{{state.gitAppName}}"
- key: "state.build.generateDockerfileCmd"
value: |
./gendockerfile.sh \
-f alpine:latest \
-x {{state.gitTag}}
centos:
if: "{%- 'centos' in state.gitTag -%}true{%- endif -%}"
set:
- key: "state.build.targetImageName"
value: "{{state.gitAppName}}"
- key: "state.build.generateDockerfileCmd"
value: |
./gendockerfile.sh \
-f centos:latest \
-x {{state.gitTag}}
cicdstatemgr \
--secrets cicdstatemgr-secrets.yaml \
--config cicdstatemgr-config.yaml \
--id cicd-context-data-id-X \
--generate pipelines.build.generators.dockerfile
Which would then yield the matching key/value pairs in the generator config into the cicdContextData state.