Skip to content

http.cookiefile auth added (aka .gitcookies by Google Cloud Source Repos)#38

Open
berezins wants to merge 2 commits intopieterlange:masterfrom
berezins:master
Open

http.cookiefile auth added (aka .gitcookies by Google Cloud Source Repos)#38
berezins wants to merge 2 commits intopieterlange:masterfrom
berezins:master

Conversation

@berezins
Copy link

Allows to use with Google Cloud Source Repository

entrypoint.sh Outdated
if [[ ! -f /backup/.ssh/id_rsa ]]; then
if [[ -f /backup/.gitcookies ]]; then
git config --global http.cookiefile /backup/.gitcookies
elif [[ ! -f /backup/.ssh/id_rsa ]]; then
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please flip the logic and add gitcookies as another elif section

Copy link
Author

@berezins berezins Nov 11, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
elif [[ ! -f /backup/.ssh/id_rsa ]]; then
if [[ -f /backup/.ssh/id_rsa ]]; then
elif [[ -f /backup/.gitcookies ]]; then
git config --global http.cookiefile /backup/.gitcookies
else
git config --global credential.helper '!aws codecommit credential-helper $@'
git config --global credential.UseHttpPath true
fi

This way?

@pieterlange
Copy link
Owner

Could you add a section to the README? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants