How can I add a snyk badge to my private repository?

375 Views Asked by At

Snyk badge generator for private github repos

I want to add badges to a the readme file showing the green or red badges for the vulnerabilities detected by snyk. I am using snyk and have integrated it with my GitHub account.

Accroding to the snyk documentation, they only support badges for public repo, but here I have a solution for private repo too. The steps are specified here, but I don't know how to do that. Where to install the GO? In the GitHub app or local machine and where to set up the environment variables? In the local machine or GitHub account?

I did try installing the GO app and set the variables in local machine but the command is not working in my terminal.

1

There are 1 best solutions below

0
On

While you can do this using the open-source snyk-badge project (created by a third party, not officially maintained by Snyk), it requires you to run a web server to keep your badges active.

To get this working, you need to install Golang on a server (could be localhost), ensure you set up the environment variables properly, then keep the Go server running as long as you want the badges to work.