You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my local workflow, I want to double check that a user has a netrc with credentials in it so they can be authenticated to the BSR. I use this check to make sure that a docker build does not fail on their machine since we are mounting their netrc in as a secret to do client downloads from BSR.
Change I'd like to see
The buf cli could probably have something like buf registry auth status or some similar commands that could tell you that you are logged in or not. The message that it prints isn't really important (could print the auth json) the more important part would be that it exits 0 if auth'ed and exits 1 if not auth'ed.
What does my bash code look like without this feature?
echo"Checking Buf Schema Registry login..."
bsr_auth_http_code=$(curl -o /dev/null -s -w "%{http_code}" -L -n {bsr_module_url}/@v/list)if [ "$bsr_auth_http_code"-eq 200 ];thenecho"Successfully logged into BSR"elseecho"Please auth with the buf cli"exit 1
fiecho -e "Done!\n"
buf curl could also work for this.
The text was updated successfully, but these errors were encountered:
Feature
In my local workflow, I want to double check that a user has a netrc with credentials in it so they can be authenticated to the BSR. I use this check to make sure that a docker build does not fail on their machine since we are mounting their netrc in as a secret to do client downloads from BSR.
Change I'd like to see
The buf cli could probably have something like
buf registry auth status
or some similar commands that could tell you that you are logged in or not. The message that it prints isn't really important (could print the auth json) the more important part would be that it exits 0 if auth'ed and exits 1 if not auth'ed.What does my bash code look like without this feature?
buf curl
could also work for this.The text was updated successfully, but these errors were encountered: