Giter Club home page Giter Club logo

woodpecker's Introduction

Woodpecker

Woodpecker


Pipeline Status Code coverage Translation status Discord chat Matrix space Go Report Card go reference GitHub release Docker pulls License: Apache-2.0 OpenSSF best practices pre-commit.ci


Woodpecker is a simple yet powerful CI/CD engine with great extensibility.

woodpecker

🫶 Support

Please consider donating and become a backer. 🙏 [Become a backer]

Open Collective backers

📖 Documentation

https://woodpecker-ci.org/

✨ Contribute

See Contributing Guide

Open in Gitpod

📣 Translate

We use an own Weblate instance at translate.woodpecker-ci.org.

Translation status

👋 Who uses Woodpecker?

Woodpecker is used by itself multiple well-known companies, organizations like Codeberg, hobbyist and many others.

Leave a comment if you're using it as well.

Also consider using the topic WoodpeckerCI in your repository, so others can learn from your config and use the hashtag #WoodpeckerCI when talking about the project on social media!

Here are some places where people mention Woodpecker:

✨ Stars over time

Stargazers over time

License

Woodpecker is Apache 2.0 licensed with the source files in this repository having a header indicating which license they are under and what copyrights apply.

Files under the docs/ folder are licensed under Creative Commons Attribution-ShareAlike 4.0 International Public License.

woodpecker's People

Contributors

6543 avatar anbraten avatar appleboy avatar benschumacher avatar bradrydzewski avatar dependabot[bot] avatar donny-dont avatar floatdrop avatar fudanchii avatar jolheiser avatar josmo avatar kvigen avatar kzaitsev avatar lafriks avatar laszlocph avatar letusfly85 avatar lukashass avatar mnutt avatar mscherer avatar oliveiradan avatar pat-s avatar qwerty287 avatar renovate[bot] avatar runephilosof-karnovgroup avatar scottferg avatar tboerger avatar ulrichschreiner avatar weblate avatar xoxys avatar zc-devs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

woodpecker's Issues

Add support to source branch to PR events

When creating steps for pull-request events, it's currently not possible to identify the name of the source branch. Currently the DRONE_BRANCH environment variable always returns master.

It would be great if we could have a way to figure out what is the actual name of the branch in the PR, not the one it points to.

It seems that drone now has this feature somewhat available harness/gitness#2222 (comment)

Superseded builds - Skip outdated builds

If a new commit arrives to a branch, cancel the older build.

Today with quickly repeated commits and pushes, the CI builds for all commits. The goal would be to cancel the build running on the older commit, since it's not relevant anymore, just holds up resources.

Cron triggers

Implement cron like triggers to enable nightly builds.

Global secrets

At one of my clients we have 50 repos in Drone and have tooling to enable repos. This tooling injects the common secrets to each repository, so users don't have to insert Docker registry credentials, bucket credentials, etc.

The task is to:

  • provide a way to add shared secrets
  • the end users should be able to see what shared secrets are available

One possible solution is to bootstrap secrets from a secrets file as a configuration parameter of the master. The UI should list these secrets as well as read only secrets on the secrets UI. But other ideas are very much welcome!

Race condiotion is detcted at TestFifoCancel

Maybe an issue maybe not, but would be nice to remove race condition from the test.

--- FAIL: TestFifoCancel (0.00s)
fifo_test.go:280: All pipelines should be cancelled

WARNING: DATA RACE
Write at 0x00c4200ca2b0 by goroutine 36:
github.com/laszlocph/woodpecker/cncd/queue.(*fifo).Resume()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo.go:202 +0x50
github.com/laszlocph/woodpecker/cncd/queue.TestFifoPause()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo_test.go:302 +0x50f
testing.tRunner()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:746 +0x16c

Previous read at 0x00c4200ca2b0 by goroutine 38:
github.com/laszlocph/woodpecker/cncd/queue.(*fifo).process()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo.go:210 +0x54

Goroutine 36 (running) created at:
testing.(*T).Run()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:789 +0x568
testing.runTests.func1()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:1004 +0xa7
testing.tRunner()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:746 +0x16c
testing.runTests()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:1002 +0x521
testing.(*M).Run()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:921 +0x206
main.main()
github.com/laszlocph/woodpecker/cncd/queue/_test/_testmain.go:66 +0x1d3

Goroutine 38 (finished) created at:
github.com/laszlocph/woodpecker/cncd/queue.(*fifo).Push()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo.go:61 +0xa8
github.com/laszlocph/woodpecker/cncd/queue.TestFifoPause()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo_test.go:300 +0x4f1
testing.tRunner()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:746 +0x16c

--- FAIL: TestFifoPause (0.02s)
testing.go:699: race detected during execution of test

WARNING: DATA RACE
Read at 0x00c4201101f0 by goroutine 45:
github.com/laszlocph/woodpecker/cncd/queue.(*fifo).process()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo.go:210 +0x54

Previous write at 0x00c4201101f0 by goroutine 44:
github.com/laszlocph/woodpecker/cncd/queue.(*fifo).Resume()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo.go:202 +0x50
github.com/laszlocph/woodpecker/cncd/queue.TestFifoPauseResume()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo_test.go:325 +0x43c
testing.tRunner()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:746 +0x16c

Goroutine 45 (running) created at:
github.com/laszlocph/woodpecker/cncd/queue.(*fifo).Push()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo.go:61 +0xa8
github.com/laszlocph/woodpecker/cncd/queue.TestFifoPauseResume()
/Users/richard/Development/woodpecker/src/github.com/laszlocph/woodpecker/cncd/queue/fifo_test.go:324 +0x42b
testing.tRunner()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:746 +0x16c

Goroutine 44 (running) created at:
testing.(*T).Run()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:789 +0x568
testing.runTests.func1()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:1004 +0xa7
testing.tRunner()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:746 +0x16c
testing.runTests()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:1002 +0x521
testing.(*M).Run()
/Users/richard/Development/common/go-1.9.7/src/testing/testing.go:921 +0x206
main.main()
github.com/laszlocph/woodpecker/cncd/queue/_test/_testmain.go:66 +0x1d3

--- FAIL: TestFifoPauseResume (0.00s)
testing.go:699: race detected during execution of test

Path condition per step

Run a step only if the git changeset contains files from the paths defined for a given step.

Version the drone-ui dependency

Today always the latest version of the drone-ui project is fetched before release. Thus builds are not reproducible. If we tag and release a new version today, and try to re-release that version later on, we can't be sure that the same version of drone-ui will be shipped.

https://github.com/laszlocph/drone-oss-08/blob/master/.drone.yml#L9
https://github.com/laszlocph/drone-oss-08/blob/master/BUILDING#L4

The task is to pull in an explicit version always so we know what version of drone-ui is part of what drone-oss release.

BUG: Advanced Yaml anchors stopped working

since the go modules change in v0.8.106 the bellow pattern cause Invalid or missing image

  slack: &slack
    image: plugins/slack
    channel: team-xx
    secrets: [ slack_webhook ]


  slack-staging-deploy:
    <<: *slack

Allow the pipeline config to be generated dynamically

It would be really cool if the drone.yml could be generated dynamically.

It could be a step that executes a docker image and then drone uses that output to run the pipeline.

This would allow users and companies to easier share templates. Like automatically setting up reviewapps without having to have a long yaml file.

This is not like jsonette as that is not dynamic either.

[drone-ui] SVG files inside programm code

Is there a way in drone-ui to use the graphics as a standalone "xxx.svg", or do they have to be in the program code?
It would be easier to maintain.

Sorry to post this here, no issues can be created in your drone-ui repo.

Pull in all cncd/* dependency

Major pieces of code is factored into the github.com/cncd/* repositories. The Docker runtime, the runtime interfaces etc.

It will ease the workflow if those packages are part of this repository.

Having them separate serves no purpose for drone-oss.

DRONE_REPO_CONFIG doesn't work

The variable DRONE_REPO_CONFIG no longer works. If DRONE_REPO_CONFIG is set to something other than ".drone.yml", then woodpecker / drone-oss-08 ignores the respective repository and its changes.

Editerconfig

There is a need for a .editorconfig

Normally JavaScript is 2 spaces, so this to deal with the unusualities 😅he

Unuseable Login

Hi Laszlo!
I can't login via web interface.
With reading the debug messages , i think the login form is missing?
Do you have any ideas, how i can fix this?

docker-compose.yml:

version: '2'

volumes:
  drone-oss-08:
    driver: local

services:
  server:
    image: laszlocloud/drone-oss-08-server:v0.8.102-alpine
    ports:
      - 8000:8000
    volumes:
      - drone-oss-08:/var/lib/drone/
    environment:
      - DRONE_DEBUG=true
      - DRONE_OPEN=true
      - DRONE_ADMIN=AkiraNorthstar
      - DRONE_ORGS=myorg
      - DRONE_HOST=http://droneserver.fritz.box
      - DRONE_GITEA=true
      - DRONE_GITEA_URL=https://gitea.fritz.box
      - DRONE_GITEA_PRIVATE_MODE=false
      - DRONE_GITEA_SKIP_VERIFY=false
      - DRONE_DATABASE_DRIVER=sqlite3
      - DRONE_DATABASE_DATASOURCE=/var/lib/drone/drone.sqlite
      - DRONE_SECRET=1234567890

Debug Message:

server_1  | time="2019-07-24T11:37:09Z" level=info ip=172.30.0.1 latency=407.133µs method=GET path="/" status=200 time="2019-07-24T11:37:09Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:09Z" level=info ip=172.30.0.1 latency=29.634µs method=GET path="/api/user/feed" status=401 time="2019-07-24T11:37:09Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:09Z" level=debug msg="user feed: connection opened" 
server_1  | time="2019-07-24T11:37:09Z" level=debug msg="user feed: connection closed" 
server_1  | time="2019-07-24T11:37:09Z" level=info ip=172.30.0.1 latency=31.846133ms method=GET path="/stream/events" status=200 time="2019-07-24T11:37:09Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:09Z" level=info ip=172.30.0.1 latency=36.788µs method=GET path="/login" status=303 time="2019-07-24T11:37:09Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:09Z" level=info ip=172.30.0.1 latency=26.597µs method=GET path="/authorize" status=303 time="2019-07-24T11:37:09Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:09Z" level=info ip=172.30.0.1 latency=154.933µs method=GET path="/login/form" status=200 time="2019-07-24T11:37:09Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:10Z" level=info ip=172.30.0.1 latency=19.807µs method=GET path="/api/user/feed" status=401 time="2019-07-24T11:37:10Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:10Z" level=debug msg="user feed: connection opened" 
server_1  | time="2019-07-24T11:37:10Z" level=debug msg="Cannot find repository login/form. sql: no rows in result set" 
server_1  | time="2019-07-24T11:37:10Z" level=info ip=172.30.0.1 latency=251.296µs method=GET path="/api/repos/login/form" status=401 time="2019-07-24T11:37:10Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0" 
server_1  | time="2019-07-24T11:37:10Z" level=debug msg="Cannot find repository login/form. sql: no rows in result set" 
server_1  | time="2019-07-24T11:37:10Z" level=info ip=172.30.0.1 latency=193.252µs method=GET path="/api/repos/login/form/builds" status=401 time="2019-07-24T11:37:10Z" user-agent="Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0"

Implement a smoke e2e test in the build process

I find myself testing the following way before merging any PR:

  • start up a server and and agent
  • find a former build and I restart it
  • wait til it's green

A smoke test could be implemented:

  • running a master and and an agent in a Docker dind setup
  • having a fixture sqlite database that has a previously running build in it
    doing like this there is no need for valid Github tokens
  • restart the build with API, token is known from the fixture
  • poll the API until the build is done

Another smoketest:

  • check if UI loads, search for a DOM element

What's the value?
For example I had a case where one of the dependencies were updated and pulling of images was not working.

But to be frank, the value may not be that much.

Migrate to Go Modules

Today govendor is used.

The task is to drop govendor and manage dependencies with Go Modules.

Multiple pipeliens per repository

Find a way that repositories can have multiple pipelines triggered in a webhook.

For shorter feedback loop back to Github.

Today in a typical linting - building - testing pipeline the result of a lint only makes back to Github if all steps are done. The goal is to be able to lint in one pipeline, build and test in another one. This way developers can see linting results way quicker.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.