I’m posting this so that users who may run into this can have some help debugging.
Sample error from clone step:
Initialized empty Git repository in /drone/src/.git/
+ git fetch origin +refs/heads/master:
fatal: could not read Username for 'https://git.domain.com/': No such device or address
Some starter steps to help diagnose what could be happening:
create a new repo and add the following content into a new .drone.yml
activate the repo
cause a build to trigger
look at results of debug step to see if curl can access your gitea install (if not, then it is likely a networking issue, perhaps your drone install isn’t on same network as your gitea install)
kind: pipeline
name: default
clone:
disable: true
steps:
- name: debug
image: alpine
commands:
- env
- ls -lah
- apk add --no-cache git curl
- echo $DRONE_REPO_PRIVATE
- curl -v $DRONE_GIT_HTTP_URL
Related discussions (if this post doesn’t help, then others may):
Hello,
Trying to set up a local configuration of Gogs and Drone, I am finding it difficult to make Drone fetch and clone Gogs repos during the default build procedure. I’d like to underline that all local means that the host is expected to be running without any external net connection; it will be an ‘isolated’ box with all the required docker images downloaded already. However, at now, it is connected, so that I can try different approaches.
I believe that this use case is slightly different …
This is the error I’m getting:
+ git init
Initialized empty Git repository in /go/src/192.168.1.173/git/joel/femtoman/.git/
+ git remote add origin http://192.168.173/git/joel/femtoman.git
+ git fetch --no-tags origin +refs/heads/master:
fatal: unable to access 'http://192.168.173/git/joel/femtoman.git/': Failed to connect to 192.168.173 port 80:
Operation timed out
exit status 128
As you can see, the “remote add origin” step, is adding the wrong origin address. It is missing a number in the…
Hello! I’ve been wanting to upgrade to 1.0.0-rc.4 and tried to change everything accordingly like adding DRONE_GIT_USERNAME and DRONE_GIT_PASSWORD with a set of credentials I created for drone in Gogs and toggling DRONE_GIT_ALWAYS_AUTH=true. I’m still getting this however:
Initialized empty Git repository in /drone/src/.git/
+ git fetch origin +refs/heads/master:
fatal: could not read Username for 'https://git.mydomain.com': No such device or address
Maybe it’s something related to using HTTP…
Hi,
i just started to dive in drone - but i have some issues with my gitea-server. I can authenticate without problems, fetching repo list, set webhooks and so on - everyything seems to work fine
but when i start a build, it fails on clone step:
+ git init
Initialized empty Git repository in /drone/src/username/repo/.git/
+ git remote add origin /username/repo.git
+ git fetch --no-tags origin +refs/heads/master:
fatal: '/username/repo.git' does not appear to be a git repository
fatal: Could …