Can't run `repo bootstrap` with Bitbucket Server
consal opened this issue · comments
Our company has an on-prem Bitbucket deployment. I created an HTTP token in my Bitbucket user profile with the necessary permissions and exported it as GIT_TOKEN
When running the command, I get the error authentication required
.
export GIT_REPO="https://bitbucket.company.com/scm/~myuser/argocd-autopilot.git"
argocd-autopilot repo bootstrap --provider bitbucket-server
INFO cloning repo: https://bitbucket.company.com/scm/~myuser/argocd-autopilot.git
FATAL authentication required
Things I tried:
- Adding
--provider bitbucket-server
or--provider bitbucket
- Adding
--git-user myuser
- Using ssh git repo URL
- Adding
log-level debug
doesn't show the actual command that is used to clone the repo
Without success. Can it work with an on-prem bitbucket?
You need to create a app password not access token.
Go to: https://bitbucket.org/account/settings/ and copy USERNAME
then go to: https://bitbucket.org/account/settings/app-passwords/ and create a app password
export GIT_TOKEN="THE APP PASSWORD TOKEN"
export GIT_REPO="https://bitbucket.org/YOURUSER/YOUR_REPO.git"
export GIT_USER="USERNAME"
argocd-autopilot repo bootstrap --provider bitbucket
if it's on prem provider should be --provider bitbucket-server probably
Yes bitbucket-server
would be the right one to use. https://argocd-autopilot.readthedocs.io/en/stable/commands/argocd-autopilot_repo_bootstrap/#options
@consal were you able to get it working?