Skip to content

Commit

Permalink
add example
Browse files Browse the repository at this point in the history
  • Loading branch information
jdolitsky committed Jan 13, 2019
1 parent c807e38 commit 500cecb
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,23 @@ Install via go get:
go get -u github.com/jdolitsky/chart-scanner/cmd/chart-scanner
```

## Example

The following shows detection of the test chart `evil-1.0.0.tgz` found in this repo:

```
$ git clone git@github.com:jdolitsky/chart-scanner.git
$ cd chart-scanner
$ chart-scanner --debug --storage=local --storage-local-rootdir=$(pwd)/testdata/charts
2019/01/13 17:45:17 DEBUG org1/repo1/acs-engine-autoscaler-2.2.2.tgz is valid
2019/01/13 17:45:17 DEBUG org1/repo2/aerospike-0.1.7.tgz is valid
2019/01/13 17:45:17 DEBUG org2/repo1/apm-server-0.1.0.tgz is valid
2019/01/13 17:45:17 DEBUG org2/repo2/ark-1.2.3.tgz is valid
2019/01/13 17:45:17 ERROR org2/repo2/evil-1.0.0.tgz has bad chart name "../../../../charts/org2/repo2/evil"
$ echo $?
1
```

## Usage

Command-line storage options are identical to the ones used in ChartMuseum (the package is imported and re-used).
Expand Down

0 comments on commit 500cecb

Please sign in to comment.