-
-
Notifications
You must be signed in to change notification settings - Fork 354
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gitea git fetch always fatal #473
Comments
woodpecker docker-compose.ymlversion: '3'
services:
woodpecker-server:
image: woodpeckerci/woodpecker-server:latest
ports:
- 192.168.192.2:11491:8000
volumes:
- ./data:/var/lib/drone/
environment:
- WOODPECKER_OPEN=true
- WOODPECKER_HOST=https://ci.example.com
- WOODPECKER_AGENT_SECRET=example_secret
- WOODPECKER_GITEA=true
- WOODPECKER_GITEA_URL=https://git.example.com
- WOODPECKER_GITEA_CLIENT=example_gitea_client
- WOODPECKER_GITEA_SECRET=example_gitea_secret
- WOODPECKER_GIT_ALWAYS_AUTH=true
woodpecker-agent:
image: woodpeckerci/woodpecker-agent:latest
command: agent
restart: always
depends_on:
- woodpecker-server
volumes:
- /var/run/docker.sock:/var/run/docker.sock
environment:
- WOODPECKER_SERVER=woodpecker-server:9000
- WOODPECKER_AGENT_SECRET=example_secret Drone docker-compose.ymlversion: "3.6"
services:
drone:
image: drone/drone:2
ports:
- 192.168.192.2:11380:80
environment:
DRONE_GITEA_SERVER: "https://git.example.com"
DRONE_GITEA_CLIENT_ID: "example_gitea_clientid"
DRONE_GITEA_CLIENT_SECRET: "example_gitea_secret"
DRONE_RPC_SECRET: "example_secret"
DRONE_SERVER_HOST: "ci.example.com"
DRONE_SERVER_PROTO: "https"
DRONE_USER_CREATE: "username:foo,admin:true,token:bar"
DRONE_GIT_ALWAYS_AUTH: "true"
volumes:
# attach a directory relative to the directory containing this compose file
- ./data:/data
restart: always Drone Agent docker-compose.ymlversion: "3.6"
services:
drone:
image: drone/drone-runner-docker:1
ports:
- 192.168.192.2:18182:18182
environment:
DRONE_HTTP_BIND: "18182"
DRONE_RUNNER_CAPACITY: "1"
DRONE_RUNNER_NAME: "Example-Docker"
DRONE_RPC_SECRET: "example_secret"
DRONE_RPC_HOST: "ci.example.com"
DRONE_RPC_PROTO: "https"
restart: always
volumes:
- /var/run/docker.sock:/var/run/docker.sock |
@cubesky is the repo you like to fetch from private? |
Yes, it is internal repo. |
Ok you got hit by: woodpecker-ci/plugin-git#4 TLD: my bad - it is a known issue that still need a fix The drone "fix" is just a workaround you could "do" via secrets, but i would not recommend to use your own account |
So i propose: create an "clone" account with read permissions only and add credentials (user+token) to secrets & pass it to the git plugin If you have matrix/discord we can chat how to do there too :) |
I think use user's permission to clone repo is better than using a "clone" user. |
-> #479 |
As a developer using an custom git server (e.g. Github Enterprise) I would like to be able to authenticate the user on repositories which are marked as public. See issue: #473 Ref: #693 (comment)
Component
server, agent, other
Describe the bug
Git fetch always fatal using Gitea OAuth.
This happens on DroneCI too, but add
DRONE_GIT_ALWAYS_AUTH=true
can solve this problem. It there any similar solution for woodpecker?WOODPECKER_GIT_ALWAYS_AUTH
doesn't work.System Info
Additional context
Woodpecker and Gitea is on the same host with docker.
Validations
The text was updated successfully, but these errors were encountered: