Skip to content

Commit

Permalink
更改trivy工具包结构
Browse files Browse the repository at this point in the history
  • Loading branch information
cnlkl committed Mar 22, 2023
1 parent 80e02cf commit 4108f94
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 9 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

[trivy使用文档](https://github.com/TencentBlueKing/ci-repoAnalysis/tree/master/trivy)

[dependency-check使用文档](https://github.com/TencentBlueKing/ci-repoAnalysis/tree/master/dependency-check)

### 接入新的工具

工具接入参考[开发文档](https://github.com/TencentBlueKing/ci-repoAnalysis/tree/master/docs/development.md)
Expand Down
4 changes: 2 additions & 2 deletions trivy/cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ package main

import (
"github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang/framework"
"github.com/TencentBlueKing/ci-repoAnalysis/trivy/cmd"
"github.com/TencentBlueKing/ci-repoAnalysis/trivy/pkg"
)

func main() {
framework.Analyze(cmd.TrivyExecutor{})
framework.Analyze(pkg.TrivyExecutor{})
}
2 changes: 1 addition & 1 deletion trivy/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ module github.com/TencentBlueKing/ci-repoAnalysis/trivy

go 1.18

require github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang v0.0.11
require github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang v0.0.12
4 changes: 2 additions & 2 deletions trivy/go.sum
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang v0.0.11 h1:Y1kw75IWG/cLgx154SRSnZ6sWUlpQTnr4bUqMV/YeqI=
github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang v0.0.11/go.mod h1:8fgb+y0YWqULX/oVg4dsWAq6ftsVZfFrXQjCKXwAE1Q=
github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang v0.0.12 h1:Pb8Y0QqLJ2Z0ZI4oN7hdh3yXROdIOD6ZXTwuIB+IOZ8=
github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang v0.0.12/go.mod h1:8fgb+y0YWqULX/oVg4dsWAq6ftsVZfFrXQjCKXwAE1Q=
File renamed without changes.
4 changes: 2 additions & 2 deletions trivy/cmd/output.go → trivy/pkg/output.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package cmd
package pkg

import (
"github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang/object"
"github.com/TencentBlueKing/ci-repoAnalysis/trivy/constant"
"github.com/TencentBlueKing/ci-repoAnalysis/trivy/pkg/constant"
"strings"
"time"
)
Expand Down
4 changes: 2 additions & 2 deletions trivy/cmd/scan_executor.go → trivy/pkg/scan_executor.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package cmd
package pkg

import (
"archive/tar"
Expand All @@ -9,7 +9,7 @@ import (
"fmt"
"github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang/object"
"github.com/TencentBlueKing/ci-repoAnalysis/analysis-tool-sdk-golang/util"
"github.com/TencentBlueKing/ci-repoAnalysis/trivy/constant"
"github.com/TencentBlueKing/ci-repoAnalysis/trivy/pkg/constant"
"io"
"net/http"
"os"
Expand Down

0 comments on commit 4108f94

Please sign in to comment.