Skip to content

Commit

Permalink
Merge branch 'main' into bugfix/341-add-postgresql-credentials
Browse files Browse the repository at this point in the history
  • Loading branch information
ptzianos authored Sep 12, 2024
2 parents d28484e + dc1862a commit 98a64dc
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions components/consumers/dependency-track/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ var (
client *dtrack.Client
ownerAnnotation string
// used for debugging, turns off certificate and enables debug
debugDT bool
debugDTConnection string
debugDT bool
)

func main() {
Expand All @@ -37,7 +38,7 @@ func main() {
flag.StringVar(&projectName, "projectName", "", "dependency track project name")
flag.StringVar(&projectUUID, "projectUUID", "", "dependency track project name")
flag.StringVar(&projectVersion, "projectVersion", "", "dependency track project version")
flag.BoolVar(&debugDT, "debugDependencyTrackConnection", false, "setup client with no tls and enable debug")
flag.StringVar(&debugDTConnection, "debugDependencyTrackConnection", "false", "setup client with no tls and enable debug")
flag.StringVar(
&ownerAnnotation,
"ownerAnnotation",
Expand Down Expand Up @@ -65,7 +66,10 @@ func main() {
if projectVersion == "" {
log.Fatal("project version is mandatory for dependency track")
}

if debugDTConnection == "true" {
debugDT = true
slog.Info("running in debug mode, skipping certificate verification and printing requests and responses")
}
c, err := dtrack.NewClient(
authURL,
dtrack.WithHttpClient(
Expand Down

0 comments on commit 98a64dc

Please sign in to comment.