@@ -43,6 +43,7 @@ const (
43
43
flagConfigserverImage = "configserver-image"
44
44
flagRunService = "run-service"
45
45
flagDownOnError = "down-on-error"
46
+ flagCACertificates = "ca-certificates"
46
47
)
47
48
48
49
const (
@@ -128,6 +129,11 @@ func CommandUp() *cli.Command { //nolint:funlen
128
129
Usage : "Skip confirmation" ,
129
130
EnvVars : []string {"NHOST_YES" },
130
131
},
132
+ & cli.StringFlag { //nolint:exhaustruct
133
+ Name : flagCACertificates ,
134
+ Usage : "Mounts and everrides path to CA certificates in the containers" ,
135
+ EnvVars : []string {"NHOST_CA_CERTIFICATES" },
136
+ },
131
137
},
132
138
}
133
139
}
@@ -171,6 +177,7 @@ func commandUp(cCtx *cli.Context) error {
171
177
},
172
178
cCtx .String (flagDashboardVersion ),
173
179
configserverImage ,
180
+ cCtx .String (flagCACertificates ),
174
181
cCtx .StringSlice (flagRunService ),
175
182
cCtx .Bool (flagDownOnError ),
176
183
)
@@ -311,6 +318,7 @@ func up( //nolint:funlen,cyclop
311
318
ports dockercompose.ExposePorts ,
312
319
dashboardVersion string ,
313
320
configserverImage string ,
321
+ caCertificatesPath string ,
314
322
runServices []string ,
315
323
) error {
316
324
ctx , cancel := context .WithCancel (ctx )
@@ -364,6 +372,7 @@ func up( //nolint:funlen,cyclop
364
372
dashboardVersion ,
365
373
configserverImage ,
366
374
clienv .PathExists (ce .Path .Functions ()),
375
+ caCertificatesPath ,
367
376
runServicesCfg ... ,
368
377
)
369
378
if err != nil {
@@ -513,14 +522,26 @@ func Up(
513
522
ports dockercompose.ExposePorts ,
514
523
dashboardVersion string ,
515
524
configserverImage string ,
525
+ caCertificatesPath string ,
516
526
runServices []string ,
517
527
downOnError bool ,
518
528
) error {
519
529
dc := dockercompose .New (ce .Path .WorkingDir (), ce .Path .DockerCompose (), ce .ProjectName ())
520
530
521
531
if err := up (
522
- ctx , ce , appVersion , dc , httpPort , useTLS , postgresPort ,
523
- applySeeds , ports , dashboardVersion , configserverImage , runServices ,
532
+ ctx ,
533
+ ce ,
534
+ appVersion ,
535
+ dc ,
536
+ httpPort ,
537
+ useTLS ,
538
+ postgresPort ,
539
+ applySeeds ,
540
+ ports ,
541
+ dashboardVersion ,
542
+ configserverImage ,
543
+ caCertificatesPath ,
544
+ runServices ,
524
545
); err != nil {
525
546
return upErr (ce , dc , downOnError , err ) //nolint:contextcheck
526
547
}
0 commit comments