Re: Git credentials not working
- From
Christian Couder <christian.couder@gmail.com>
- Date
- Oct 3, 2018, 16:03 UTC
- Message-ID
- <CAP8UFD3LEYd7RytZU_-wVcDosH+6VSdM2j3NUcnR0aQc8QfoQg@mail.gmail.com>
- In-Reply-To
- <f4f7bd2c-4c48-e749-4df1-ddf05896b337@gmail.com>
(removing git-security from CC)
On Wed, Oct 3, 2018 at 4:09 PM Dimitri Kopriwa <d.kopriwa@gmail.com> wrote:
> Git credentials in ~/.git-credentials and ~/.config/git/credentials are > being removed by git upon reading.
https://git-scm.com/docs/git-credential says:
"If the action is reject, git-credential will send the description to any configured credential helpers, which may erase any stored credential matching the description."
So maybe this is expected.
Another possibility is that your .gitlab-ci.yml might launch scripts writing into those files, like the before_script.sh script that is described on:
https://stackoverflow.com/questions/50553049/is-it-possible-to-do-a-git-push-within-a-gitlab-ci-without-ssh
Could you also check which credential helper and which options are used? For example with commands like:
$ git config -l --show-origin | grep -i cred $ git config -l --show-origin | grep -i http $ git config -l --show-origin | grep -i askpass $ env | grep -i askpass