We have a Jenkins pipeline that checks out the code from https://bitbucket.org/company/repo.git. This has been working fine for the last 3-4 years, but started failing over the weekend with the error "fatal: could not read Username for 'https://bitbucket.org': No such device or address".
The issue does not occur during checkout, that seems fine, but instead when we run the command "git fetch --prune --prune-tags origin" on the checked out workspace.
We found a solution to include the username and password in the URL, which is fine, it seems to work, but various posts on here seem to suggest switching to SSH keys instead.
- Why did it break? We did not update any software.
- Is the https://user:pass@bitbucket.org/company/repo.git a good solution, or should we be looking to move to SSH for longevity?
Thanks,
Stuart