(spec *swarm.Spec, flags *pflag.FlagSet, opts caOptions)
| 98 | } |
| 99 | |
| 100 | func updateSwarmSpec(spec *swarm.Spec, flags *pflag.FlagSet, opts caOptions) { |
| 101 | caCert := opts.rootCACert.Contents() |
| 102 | caKey := opts.rootCAKey.Contents() |
| 103 | opts.mergeSwarmSpecCAFlags(spec, flags, &caCert) |
| 104 | |
| 105 | spec.CAConfig.SigningCACert = caCert |
| 106 | spec.CAConfig.SigningCAKey = caKey |
| 107 | |
| 108 | if caKey == "" && caCert == "" { |
| 109 | spec.CAConfig.ForceRotate++ |
| 110 | } |
| 111 | } |
| 112 | |
| 113 | func attach(ctx context.Context, dockerCLI command.Cli, opts caOptions) error { |
| 114 | apiClient := dockerCLI.Client() |
no test coverage detected
searching dependent graphs…