Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickbaber committed Jan 30, 2023
1 parent 22a6ceb commit caf8a47
Showing 1 changed file with 1 addition and 24 deletions.
25 changes: 1 addition & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ Docker image with useful CI/CD tools
- git
- openssl
- rsync
- Sonnar Scanner
- sshpass
- trivy

Expand Down Expand Up @@ -44,35 +43,13 @@ container_scan:
- schedule
script:
- |
trivy \
--quiet \
trivy --quiet image \
--severity CRITICAL \
--auto-refresh \
--ignore-unfixed \
--exit-code 1 \
registry.gitlab.com/your-repository-path/your-image-name:your-tag
```

### Run Sonar Scanner

Make sure to add an `analysis` stage to your `stages`. Add a scheduled pipeline with the variable `SCHEDULE_ANALYSE` so it will be run on a regular basis. Store your credentials in the environment variables `SONAR_PROJECT_KEY`, `SONAR_HOST` and `SONAR_LOGIN` (**Settings → CI/CD → Variables**).

```yaml
sonarqube:
stage: analysis
only:
variables:
- $SCHEDULE_ANALYSE
refs:
- schedules
script:
- |
sonar-scanner \
-Dsonar.projectKey=$SONAR_PROJECT_KEY \
-Dsonar.host.url=$SONAR_HOST \
-Dsonar.login=$SONAR_LOGIN
```

## Contributing

To release a new version on Docker Hub run:
Expand Down

0 comments on commit caf8a47

Please sign in to comment.