File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # conflow pipeline - Full generate → validate → export
2+ version : " 1"
3+ name : " tma-mark2"
4+
5+ stages :
6+ - name : " generate"
7+ description : " Generate configuration using Nickel"
8+ tool :
9+ type : nickel
10+ command : export
11+ file : configs/config.ncl
12+ format : json
13+ input : " configs/config.ncl"
14+ output : generated/config.json
15+
16+ - name : " validate"
17+ description : " Validate against CUE schema"
18+ tool :
19+ type : cue
20+ command : vet
21+ schemas :
22+ - schemas/config.cue
23+ input :
24+ from_stage : generate
25+ depends_on :
26+ - generate
27+
28+ - name : " export"
29+ description : " Export final configuration as YAML"
30+ tool :
31+ type : cue
32+ command : export
33+ out_format : yaml
34+ input :
35+ from_stage : generate
36+ output : deploy/config.yaml
37+ depends_on :
38+ - validate
Original file line number Diff line number Diff line change 1+ # Configuration generation
2+ {
3+ name = "my-app" ,
4+ replicas =
5+ let env = "dev" in
6+ if env == "prod" then 5
7+ else if env == "staging" then 3
8+ else 1,
9+ port = 8080,
10+ env = "dev" ,
11+ }
Original file line number Diff line number Diff line change 1+ // Configuration schema
2+ package config
3+
4+ #Config : {
5+ name : string
6+ replicas : int & >= 1
7+ port : int & >= 1 & <= 65535
8+ env : string
9+ }
You can’t perform that action at this time.
0 commit comments