this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

palomar: CLI arg to skip SSL cert validation (for dev)

+11
+11
cmd/palomar/main.go
··· 2 2 3 3 import ( 4 4 "context" 5 + "crypto/tls" 5 6 "encoding/json" 6 7 "fmt" 7 8 "log/slog" ··· 42 43 Name: "elastic-cert-file", 43 44 Usage: "certificate file path", 44 45 EnvVars: []string{"ES_CERT_FILE", "ELASTIC_CERT_FILE"}, 46 + }, 47 + &cli.BoolFlag{ 48 + Name: "elastic-insecure-ssl", 49 + Usage: "if true, disable SSL cert validation", 50 + EnvVars: []string{"ES_INSECURE_SSL"}, 45 51 }, 46 52 &cli.StringFlag{ 47 53 Name: "elastic-username", ··· 349 355 cert = b 350 356 } 351 357 358 + insecure := cctx.Bool("elastic-insecure-ssl") 359 + 352 360 cfg := es.Config{ 353 361 Addresses: addrs, 354 362 Username: cctx.String("elastic-username"), ··· 356 364 CACert: cert, 357 365 Transport: &http.Transport{ 358 366 MaxIdleConnsPerHost: 20, 367 + TLSClientConfig: &tls.Config{ 368 + InsecureSkipVerify: insecure, 369 + }, 359 370 }, 360 371 } 361 372