简体   繁体   中英

How to get builds badge image from Gitlab CI

I would like to get the build badge image on my project from Gitlab CI. I know the url ( documentation ) :

http://example.gitlab.com/namespace/project/badges/branch/build.svg

But my project is a private project, and the link require authentification and I don't know how to be authenticated with this url. Thank you for your help.

Your project/repository's README.md should be able to show your badge as it's already in an authenticated session with your/the Gitlab server. If your trying to show the badge on a different, non-Gitlab page on the same server, you could symlink the build.svg to a location in your www root and ensure that your other webserver to follow symlinks.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM