Anbraten
70af29f9a2
fix redirect after login ( #824 )
...
if you are in buildView and login, go back to this buildView again
2022-05-14 17:45:01 +02:00
6543
d06dfc86b4
Allow gitea dev version ( #914 )
...
* update gitea sdk to latest
* As before try to autodetect gitea version, if this does not work, assume it's latest version (v1.17.0 atm)
2022-05-14 17:34:40 +02:00
6543
c350af645b
Move Badge & CCMenue into own packages ( #908 )
...
* move badge generation into own package
* move ccmenue away from models
* fix misspell
2022-05-14 14:30:09 +02:00
qwerty287
be0dfb280c
Add branches support for BitBucket ( #907 )
2022-05-12 19:31:01 +02:00
qwerty287
6568751320
Allow to change forge status messages ( #900 )
...
Allow to change the status message via template option
Closes https://github.com/woodpecker-ci/woodpecker/issues/855
2022-05-12 19:07:33 +02:00
Anbraten
bdb007e064
Auto cancel blocked pipelines ( #905 )
2022-05-11 07:45:21 +02:00
Zav Shotan
7313de2b1d
Add support for superseding runs ( #831 )
...
closes #11
Added support:
1. Environment variable `WOODPECKER_DELETE_MULTIPLE_RUNS_ON_EVENTS` (Default pull_request, push)
2. Builds will be marked as killed when they "override" another build
2022-05-09 11:26:09 +02:00
Johan Van de Wauw
8fa2a5efe4
Fix various typos ( #835 )
2022-03-09 01:44:08 +01:00
Anbraten
90dcc77870
fix secret updating ( #828 )
2022-03-03 15:24:20 +01:00
Lukas Bachschwell
59ba8538a1
Add support for pipeline configuration service ( #804 )
...
* Add configuration extension flags to server
Add httpsignatures dependency
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Add http fetching to config fetcher
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Refetch config on rebuild
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* - Ensure multipipeline compatiblity
- Send original config in http request
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Basic tests of config api
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Simple docs page
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Better flag naming
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Rename usages of the term yaml
Rename ConfigAPI struct
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Doc adjustments
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* More docs touchups
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Fix env vars in docs
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* fix json tags for api calls
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Add example config service
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Consistent naming for configService
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Docs: Change example repository location
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Fix tests after response field rename
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Revert accidential unrelated change in api hook
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
* Update server flag descriptions
Co-authored-by: Anbraten <anton@ju60.de>
Co-authored-by: Anbraten <anton@ju60.de>
2022-02-28 10:56:23 +01:00
Lukas Bachschwell
a2315fe931
Do not filter on linux/amd64 per default ( #805 )
...
* Do not filter on linux/amd64 per default & add tests
Tasks with no platform would otherwise not perform on runners with different OS/ARCH combos
Signed-off-by: Lukas Bachschwell <lukas@lbsfilm.at>
Co-authored-by: 6543 <6543@obermui.de>
2022-02-26 22:54:28 +01:00
qwerty287
ecc25395aa
Branch list enhancements ( #808 )
...
* Allow users not logged in to access branches page
(fixes a nil pointer derefernce)
* Add Gogs support for branches
2022-02-26 17:36:00 +01:00
6543
4607cf5f59
Split GRPC code of related contexts into separate files ( #798 )
2022-02-26 14:37:10 +01:00
Anbraten
52d8097290
Get Netrc machine from clone url ( #800 )
...
We previously got the machine hostname for Netrc from the url of the remote, but in cases where the clone-url does not match the api url this can lead to errors.
2022-02-26 02:54:15 +01:00
6543
8ae124d5e6
Remove unused code ( #797 )
...
* delete empty code files
* delete outdated readme
* delete unused code
* dedup license
2022-02-25 21:42:45 +01:00
qwerty287
28e96a3851
View better error if repo was deleted/renamed ( #780 )
...
If the repo was renamed, there's an issue with Gitea: it redirects the /api/v1/repos/<owner>/<repo>/hooks POST request to a GET request at the same URL.
This URL returns the list of all hooks, thus the Gitea SDK can't parse the response into a single gitea.Hook type.
A better error is also visisble if the repo was deleted.
2022-02-24 14:54:05 +01:00
6543
c4960cdd2c
Ignore items from WOODPECKER_ENVIRONMENT only containing a key and no value ( #781 )
...
* fix 761
* refactor: rename to match what it does & log ignore case
2022-02-23 08:59:52 +01:00
Zav Shotan
905350fa15
Add support for default clone image environment variable ( #769 )
...
This allows for custom clone images for deployment in air-gap systems.
Co-authored-by: Zav Shotan <zshotan@bloomberg.net>
2022-02-10 17:05:19 +01:00
Zav Shotan
f16525fae5
Add flag to always authenticate when cloning public repositories ( #760 )
...
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: https://github.com/woodpecker-ci/woodpecker/issues/473
Ref: https://github.com/woodpecker-ci/woodpecker/pull/693#issuecomment-1025771162
2022-02-08 17:55:08 +01:00
6543
0d463ca467
Let non required migration tasks fail and continue ( #729 )
2022-01-31 15:50:10 +01:00
6543
2a5159f7fe
Fix pipeline timestamps ( #730 )
...
* only calculate time on running builds
* Add updated timestamp into database and use it in frontend
* add more trace logging
* refactor (move grpc unrelated func into related package)
* fix xorm schema
* add todo
2022-01-31 15:38:39 +01:00
Anbraten
6af94d79e3
Remove unused flags / options ( #693 )
...
Some flags where unused and / or unnecessary as they are covered by alternatives implemented in PRs of milestone 0.15.0 and just complicated the setup.
closes #681
2022-01-31 15:38:00 +01:00
6543
071bd7418a
Fix tests and pipeline ( #732 )
...
* fix pipeline
* use EqualStringSlice to compare slices in tests
* full test coverage
* tests: wait for mysql/postgres to sync ...
2022-01-31 14:39:53 +01:00
6543
edbf6a3ba9
Allow to change status context again ( #674 )
...
* use flag value
* fix test
* sed -i 's/STATUS_CONTEXT/WOODPECKER_STATUS_CONTEXT/g'
* docs
* Update docs/docs/91-migrations.md
Co-authored-by: Anbraten <anton@ju60.de>
2022-01-29 20:37:36 +01:00
Anbraten
401072abb1
Support ChangedFiles for Github & Gitlab PRs and Gitlab pushes ( #697 )
2022-01-17 23:46:59 +01:00
Anbraten
2f780193b1
github tag build should not have changed files ( #698 )
2022-01-16 18:44:44 +01:00
6543
5a120db69d
remove "panic()" as much as posible from code ( #682 )
2022-01-09 23:27:30 +01:00
Anbraten
37c82b905c
Show yml config of pipeline in UI ( #649 )
...
closes #89
2022-01-09 03:59:45 +01:00
Anbraten
5e595978fa
Send decline events back to UI ( #680 )
...
and remove unused code
2022-01-09 03:47:31 +01:00
6543
8489b5bd37
Gitea: push webhook notice changed files of all related commits ( #675 )
...
* getChangedFilesFromPushHook: use all commits
* add test
2022-01-08 22:16:07 +01:00
6543
1588495b1a
Build ref link point to commit not compare if only one commit was pushed ( #673 )
...
close #401
2022-01-08 22:06:00 +01:00
6543
c186e2fa8c
Update dev-docs & improve migration code ( #670 )
2022-01-08 20:21:22 +01:00
6543
acbde30c3b
Lint code with gofumpt ( #664 )
2022-01-06 07:44:14 +01:00
6543
2f91bdd4a0
gofumpt -w -l -extra . ( #661 )
2022-01-05 21:50:23 +01:00
6543
dec0eeeed7
Use global branch filter only on events containing branch info ( #659 )
...
- close #581
- delete unused code
- simplify code
- add check to procBuilder to fail on invalid config
2022-01-05 17:54:44 +01:00
jdoubleu
abd3d1d5c3
API GetRepos() return empty list if no active repos exist ( #658 )
2022-01-03 20:31:53 +01:00
jdoubleu
132d3567f4
skip nested GitLab repositories during sync ( #656 )
...
Implements https://github.com/woodpecker-ci/woodpecker/pull/651#issuecomment-1003794674 , partly fixes #648
2022-01-03 16:35:46 +01:00
Anbraten
7e6765ce95
hotfix gitlab sub repo listing ( #652 )
2022-01-03 16:35:17 +01:00
Anbraten
f7d1451ca3
pass repo to remote perm func ( #653 )
...
* pass repo to remote perm func
* go:generate mockery
Co-authored-by: 6543 <6543@obermui.de>
2022-01-03 15:33:36 +01:00
6543
a2429eb570
Do not exclude repo owner from gated rule ( #641 )
2022-01-01 13:17:42 +01:00
6543
30c3e139d7
proc.Tree() func do not depend on sorted procs list ( #647 )
...
* proc.Tree() func do not depend on sorted procs list
* Add test case
Signed-off-by: 6543 <6543@obermui.de>
2021-12-31 17:43:09 +01:00
ktprograms
b76606308c
Add field for image list in Secrets Repo Settings (Web UI) ( #638 )
...
- Add field for image list in Secrets Repo Settings (Web UI)
Simple comma separated input field, split into images array
- validate secret images in backend
- trim spaces and filter empty list items
Signed-off-by: 6543 <6543@obermui.de>
Co-authored-by: 6543 <6543@obermui.de>
2021-12-30 07:26:36 +01:00
Anbraten
8e8f8967c3
Improve status updates ( #561 )
...
- link to specific proc (only general build before)
- set status for all procs (before: only for the whole build on some SCMs)
- set status after restart
- set status to pending after waiting for approval
- make status of gitlab, gitea & github equal
- dedupe status update code
- dedupe `PostBuild` code
close #410 , close #297 , close #459 , close #521
2021-12-28 17:02:49 +01:00
6543
0aefdc9978
Add tests framework for storage migration ( #630 )
...
* add test sqlite db
* migration tests for sqlite
* fix pipeline config
* fix tests to other dbms
* fix postgres & mysql
2021-12-20 16:15:21 +01:00
6543
b2ce1f5da5
fix sqlite migration on column drop of uncommon schemas ( #629 )
...
* fix sqlite schema normalising
* sqlite robuster alg to extract columns form schema
2021-12-20 09:59:27 +01:00
6543
ef597eca0c
Add flag for not fetching permissions (FlatPermissions) ( #491 ) ( #625 )
...
Co-authored-by: Alex Eftimie <alex.eftimie@getyourguide.com>
2021-12-19 12:04:29 +01:00
Anbraten
ed0a9fd756
Use gitlab generic webhooks instead of drone-ci-service ( #620 )
...
Benefits:
- the webhook delivery history of the drone-ci-service is broken (no way to check if a webhook was successfully delivered by Gitlab)
- drone-ci-service has limited events support (for example no comment or branch deleted event)
- independent from drone integration in general
2021-12-19 01:12:09 +01:00
Anbraten
ce462ce4ac
fix new build not published to UI if blocked mode enabled ( #619 )
2021-12-19 00:23:48 +01:00
6543
f4c73792f3
Calculate build number on creation ( #615 )
...
* Calculate build number on creation
* Delete repo.Counter (form code and database)
2021-12-18 20:37:51 +01:00
Anbraten
1f85615a5d
Improve hook errors ( #612 )
...
Fixed problems:
- `c.AbortWithError()` stops the chain, but does not return a message as http response
- only return woodpeckers own messages and hide errors from http response (could be dangerous)
- added missing returns
- log all messages send to the user (at least on debug level)
2021-12-18 14:58:01 +01:00