Skip to content

Commit

Permalink
chore: document
Browse files Browse the repository at this point in the history
  • Loading branch information
wurstbrot committed Jan 18, 2024
1 parent 0425e9f commit 902d3b3
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 7 deletions.
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,23 @@ This projects contains the DefectDojo upload client and statistics client. It is

# Entrypoints
The default entrypoint for the upload-client image is
```
```bash
"java", "-cp", "@/app/jib-classpath-file", "org.sdase.Main".
```
To use the upload validation, use
```
```bash
"java", "-cp", "@/app/jib-classpath-file", "org.sdase.uploadValidation.MainValidation".
```
To delete test products, use
```
```bash
"java", "-cp", "@/app/jib-classpath-file", "org.sdase.deleteTestProduct.MainDeleteProduct".
```


# Run as image
```bash
docker run -ti \
-e "PRODUCT_NAME_TO_DELETE=xxx" \
-e "DEFECTDOJO_URL=xxx" \
-e "DEFECTDOJO_API_KEY=xxx" \
-e "DEFECTDOJO_USERNAME=xxx" \
-v $(pwd)/delete.groovy:/delete.groovy --entrypoint="java -cp @/app/jib-classpath-file org.sdase.DeleteProducts" quay.io/sdase/defectdojo-client:4
```
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.sdase.deleteTestProduct
package org.sdase.deleteProduct

import io.securecodebox.persistence.defectdojo.config.DefectDojoConfig
import io.securecodebox.persistence.defectdojo.models.Finding
Expand Down Expand Up @@ -38,7 +38,7 @@ import io.securecodebox.persistence.defectdojo.service.ProductGroupService
import io.securecodebox.persistence.defectdojo.ScanType
import java.util.stream.Collectors

public class MainDeleteProduct {
public class DeleteProducts {
static void main(String[] args) {
String dojoUrl = System.getenv("DEFECTDOJO_URL")
if (dojoUrl == null) {
Expand Down

0 comments on commit 902d3b3

Please sign in to comment.