I have Bitbucket server setup, and I have Drone setup. Drone sees my repo and attempts to build. When it does, I get an error saying that it was unable to clone the repo.
To diagnose, I tried to run the drone/git plugin manually. I found that the following works:
docker run -e DRONE_COMMIT=$my_commit -e DRONE_COMMIT_BRANCH=master -e DRONE_REMOTE_URL=https://$my_host/scm/infra/microservice-tas-sm.git -e DRONE_NETRC_MACHINE=$my_host -e DRONE_NETRC_USERNAME=drone -e DRONE_NETRC_PASSWORD=$my_token drone/git drone/git
I then captured the env variables passed at runtime to a transient container (I assume it is the drone/git container) that was created when I hit “Restart” in the browser. This container had an empty DRONE_REMOTE_URL and an empty DRONE_NETRC_MACHINE, but it had the DRONE_NETRC_USERNAME and DRONE_NETRC_PASSWORD specific correctly.
My believe is that the clone is failing due to the missing env variables. Is this known to work? I didn’t manage to see in the code where these env variables are being set or where the drone/git is being configured and called.