build/gerrit
Heschi Kreinick 644dfced84 cmd/relui,gerrit: use application default creds for Gerrit auth
relui needs to use its service account to access the private security
repository, and while I'm at it it might as well use it for the public
repo too. Add support to the gerrit package and use it in relui.

I adapted this code from the Gerrit team's auth daemon:
https://gerrit.googlesource.com/gcompute-tools/+/refs/heads/master/git-cookie-authdaemon
There may be better ways to do it but this works on my machine.

For golang/go#53799.

Change-Id: Iec302f4e4e336c21258019b0c20898280e249380
Reviewed-on: https://go-review.googlesource.com/c/build/+/417215
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Run-TryBot: Heschi Kreinick <heschi@google.com>
Auto-Submit: Heschi Kreinick <heschi@google.com>
2022-07-13 22:33:46 +00:00
..
README.md all: add or change GoDoc badge to pkg.go.dev with update-readmes.go 2020-12-15 04:52:31 +00:00
auth.go cmd/relui,gerrit: use application default creds for Gerrit auth 2022-07-13 22:33:46 +00:00
auth_test.go gerrit: Add support for Digest Authorization 2017-03-25 20:05:26 +00:00
demo.go all: go fmt ./... 2021-02-20 03:31:12 +00:00
example_test.go gerrit: switch to use std context package, require Go 1.7+ 2017-04-18 05:16:09 +00:00
gerrit.go cmd/relui,gerrit: use application default creds for Gerrit auth 2022-07-13 22:33:46 +00:00
gerrit_test.go gerrit: switch to a generic NotExist error 2022-06-14 17:31:15 +00:00

README.md

Go Reference

golang.org/x/build/gerrit

Package gerrit contains code to interact with Gerrit servers.