Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No error returned when failed to push to Dependency Track #99

Open
dmuse89 opened this issue Jan 4, 2022 · 3 comments
Open

No error returned when failed to push to Dependency Track #99

dmuse89 opened this issue Jan 4, 2022 · 3 comments

Comments

@dmuse89
Copy link

dmuse89 commented Jan 4, 2022

I am currently implementing this tool into our pipelines (kudos, btw, on creating a great all-in-one CycloneDX SBOM Generator) and the pipeline is still still passing, although an error is shown in the cdxgen tool and fails to upload to Dependency Track v4.3.6 (see attached image).

In the event of an error, the application should return an error value to the OS.

image

Command called:
cdxgen --project-name $CI_PROJECT_NAME --project-version $CI_COMMIT_REF_NAME --server-url $DT_SERVER_URL --api-key $DT_API_KEY -p -r

@prabhu
Copy link
Collaborator

prabhu commented Jan 11, 2022

@dmuse89 Could you check the value set for DT_SERVER_URL. The code is appending the argument with /api/v1/bom here

https://github.com/AppThreat/cdxgen/blob/master/index.js#L2068

@dmuse89
Copy link
Author

dmuse89 commented Jan 17, 2022

Hey @prabhu, indeed that appeared to be the issue in this case. Nevertheless, in the event that cdxgen fails, then it should return an error code to the calling application.

@prabhu
Copy link
Collaborator

prabhu commented Jan 17, 2022

@dmuse89 I agree. Will keep this ticket open and add some error checks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants