I am using Antora to generate a static site for our documentation. I have followed their guidance for private repository authentication but are being unsuccessful. It seems that they only support HTTPS Basic Auth for GIT over HTTPS. I have tried generating and using an Application Specific Password, GIT Cookie, OAuth token all without success. Do you have any guidance on how to provide authentication?
-
1At the moment Cloud Source Repositories doesn't support this kind of user/password pair authentication. [Here](https://github.com/GoogleCloudPlatform/google-cloud-eclipse/issues/2392) is a similar issue for eclipse. The only supported ways to authenticate at the moment are described in the [Public Documentation](https://cloud.google.com/source-repositories/docs/authentication) – Chris32 Jul 05 '20 at 17:19
-
Hello! Please if any of the answer provided helped you please consider upvoting and approving it, otherwise please let us know if you need further help! – Chris32 Aug 06 '20 at 13:37
-
Ok, I did and marked it as answered. Thank you for your help Chris32. – Justin Hartung Aug 07 '20 at 15:17
2 Answers
At the moment Cloud Source Repositories doesn't support this kind of user/password pair authentication. Here is a similar issue for eclipse.
The only supported ways to authenticate at the moment are described in the Public Documentation

- 4,716
- 2
- 18
- 30
If I understood your requirement correctly, you want to connect to GCP source code repository externally to push code. If so you need to use service account with source code repository access rights. Choose appropriate roles using below URL:
https://cloud.google.com/source-repositories/docs/reference/rest
Refer below mentioned URL for connecting to source code repository once you are authenticated and do git operations.
https://cloud.google.com/source-repositories/docs/authentication
Please let me know if this is what you are looking for.
Hope this helps.

- 659
- 1
- 8
- 29
-
The requirement is to clone code externally by software that only supports HTTPS Basic Auth. Is there a way to authenticate to CSR using a bearer token or ASP? Meaning you support git clone https://source.developers.google.com/p/PROJECT_ID/r/REPOSITORY_NAME But can you support git clone https://USERNAME:AUTH_TOKEN@source.developers.google.com/p/PROJECT_ID/r/REPOSITORY_NAME. For Github it works great with a personal access token (PAT). – Justin Hartung Jun 30 '20 at 19:34