Commit graph

4453 commits

Author SHA1 Message Date
6543
92614dfb1e
Agent check gRPC version against server (#1653)
close #1114

As long as the `VersionResponse` type is not changed the check will
fail/pass gracefully

example output:
```
{"level":"error","error":"GRPC version mismatch","time":"2023-03-19T19:49:09+01:00","message":"Server version next-6923e7ab does report grpc version 2 but we only understand 1"}
GRPC version mismatch
```
2023-03-19 22:42:21 +01:00
qwerty287
f582ad3159
Various enhancements in configuration (#1645)
- backends: move to cli flags instead of os.Getenv
- ssh: support 2fa with key and password
- allow to set grpc jwt secret (solves todo)
- allow to set default and max timeout (solves todo)

Closes https://github.com/woodpecker-ci/woodpecker/issues/896
Closes https://github.com/woodpecker-ci/woodpecker/issues/1131
2023-03-19 20:24:43 +01:00
6543
56e6639396
Refactor nits (#1652)
-
https://github.com/woodpecker-ci/woodpecker/pull/1641/files#r1141405630
-
ade8e6d010 (r105091268)
-
https://github.com/woodpecker-ci/woodpecker/pull/1647/files#r1141410010

---------

Co-authored-by: Anbraten <anton@ju60.de>
2023-03-19 18:32:19 +01:00
Weblate
e74c256571 Translated using Weblate (Russian)
Currently translated at 100.0% (282 of 282 strings)

Translated using Weblate (Indonesian)

Currently translated at 100.0% (282 of 282 strings)

Translated using Weblate (German)

Currently translated at 100.0% (282 of 282 strings)

Co-authored-by: Leonid Maslakov <root@lcomrade.su>
Co-authored-by: Linerly <linerly@protonmail.com>
Co-authored-by: qwerty287 <ndev@web.de>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/de/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/id/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/ru/
Translation: Woodpecker CI/UI
2023-03-19 12:53:04 +00:00
qwerty287
ade8e6d010
Various fixes and improvements (#1643)
- allow repo names to be case-insensitive
- improve backend error handling on DB get errors (record not found ->
404, else -> 500)
- replace magic numbers of http response codes
- unify the look and feel of cancel / save buttons on forms and view
them in one line

---------

Co-authored-by: Lauris BH <lauris@nix.lv>
2023-03-19 13:52:58 +01:00
qwerty287
42a115e19e
Add PR pipeline list (#1641)
Instead of viewing PR pipelines in the branches lists, add a separate
list for them. The API endpoint for PRs supports pagination (thus I
added a lot of pagination-related stuff), the UI doesn't yet though.


![wp](https://user-images.githubusercontent.com/80460567/226099133-bb4935d6-c357-4d73-8465-9157e25c0d82.png)

Closes #1619 

Extends this part of #1640

---------

Co-authored-by: Anbraten <anton@ju60.de>
2023-03-19 10:43:57 +01:00
qwerty287
37dc8a46e0
Drop coding support (#1644)
Coding support is likely broken and nobody will ever fix it. Also it
looks like nobody wants to use it, otherwise we would have get some bug
reports.

---------

Co-authored-by: 6543 <6543@obermui.de>
2023-03-19 09:36:04 +01:00
qwerty287
7ddc18348f
Only grant privileged to plugins (#1646)
Closes https://github.com/woodpecker-ci/woodpecker/issues/1525

Co-authored-by: Anbraten <anton@ju60.de>
2023-03-19 03:07:10 +01:00
Weblate
51168db9fd Translated using Weblate (Russian)
Currently translated at 100.0% (264 of 264 strings)

Translated using Weblate (Indonesian)

Currently translated at 100.0% (264 of 264 strings)

Translated using Weblate (French)

Currently translated at 100.0% (264 of 264 strings)

Translated using Weblate (German)

Currently translated at 100.0% (264 of 264 strings)

Co-authored-by: Leonid Maslakov <root@lcomrade.su>
Co-authored-by: Linerly <linerly@protonmail.com>
Co-authored-by: Michael <misc+weblatewoodp@zarb.org>
Co-authored-by: qwerty287 <ndev@web.de>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/de/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/fr/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/id/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/ru/
Translation: Woodpecker CI/UI
2023-03-18 20:49:18 +00:00
Anbraten
25e2c8055c
UI improvements (#1640) 2023-03-18 21:49:12 +01:00
Anbraten
277a839157
Add users UI for admins (#1634)
Co-authored-by: Lauris BH <lauris@nix.lv>
2023-03-18 21:21:20 +01:00
Anbraten
fa5b0fb96e
Fix linter (#1647) 2023-03-18 20:35:27 +01:00
qwerty287
af2ef30205
Fix button margin if button doesn't have text (#1642) 2023-03-18 12:00:49 +01:00
Anbraten
e98601df91
Correct pipeline loading (#1639)
closes #1583
2023-03-18 06:04:53 +01:00
6543
9945e27c01
pipeline compiler: handle nil entrys in settings list (#1626)
close #1609
2023-03-17 08:54:53 +01:00
Lukas
1b43b0bf20
Add pull request labels as environment variable (#1321)
Closes #1308 

Co-authored-by: Anbraten <anton@ju60.de>
2023-03-17 03:43:04 +01:00
6543
7e3bf2202c
Return 404 if pipeline not exist and handle 404 errors in WebUI (#1627) 2023-03-17 02:10:51 +01:00
Anbraten
1947408eba
Fix panel height (#1629) 2023-03-16 13:00:41 +01:00
6543
9c8c610cd4
Changelog v0.15.7 (#1622) (#1623)
Frontport #1622
2023-03-14 15:56:45 +01:00
Hayden
1c1c08831f
docs: update docs to include plugin repositories (#1596)
Closes #1536 

Co-authored-by: 6543 <6543@obermui.de>
2023-03-14 03:42:53 +01:00
Hayden
c60c59bd65
fix: apply permissions when flatPermissions enabled (#1603)
Closes #1582 

When `WOODPECKER_FLAT_PERMISSIONS=true` workaround is applied all
permissions are set to false (default) and query never returns any
matches.

This fixes it by always assigning Pull/Push/Admin to true when flatPermissions is enabled.
2023-03-14 03:42:11 +01:00
Alexander Matyushentsev
ee969979c6
fix: backend auto-detection should be consistent (#1618)
Closes https://github.com/woodpecker-ci/woodpecker/issues/1617

The `woodpecker exec` auto-detects the backend by iterating over a map
of backends. However, since Go 1 the runtime randomizes map iteration
order, so a random backend might be chosen during each execution.

PR changes to auto-detection to iterate over the backends list with
predefined priority: `docker`, `local`, `ssh`, `kubernetes`.

---------

Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
2023-03-13 09:07:41 +02:00
Alexander Matyushentsev
5e1171d7a7
fix: docker backend should not close 'engine.Tail' result (#1616)
Closes https://github.com/woodpecker-ci/woodpecker/issues/1615

The error described in
https://github.com/woodpecker-ci/woodpecker/issues/1615 is happening
because `Tail` method of the docker backend closes the instance of
`io.ReadCloser` it returns in `defer` function. As a result anything
that try to read data returned by `Tail` method eventually will attempt
to read from closes reader and get an error:


2171212c5a/pipeline/backend/docker/docker.go (L229)

The fix is just don't close returned reader and let the consumer of
`Tail` method do it. Good thing is that `Tail` is used only in one place
and reader is correctly closed:


2171212c5a/pipeline/pipeline.go (L231-L237)

Example of `woodpecker exec` output using pipeline from
https://github.com/woodpecker-ci/woodpecker/issues/1615 with the fix:

```
woodpecker exec .woodpecker.yaml
[step1:L0:0s] + echo step1
[step1:L1:0s] step1
[step2:L0:0s] + echo step2
[step2:L1:0s] step2
```

Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
2023-03-12 16:01:09 +01:00
Alexander Matyushentsev
9288670c61
feat: expose unprotected metrics endpoint (#1614)
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: Anbraten <anton@ju60.de>
2023-03-12 09:41:10 +01:00
Lukas
2171212c5a
Fix gitea development setup (#1613) 2023-03-11 07:08:00 +01:00
Lukasz
dc90f97524
Persist DepStatus of tasks (#1610) 2023-03-11 01:58:28 +01:00
Lauris BH
f1f722645c
Update dependencies golang/x libs (#1612) 2023-03-10 19:23:07 +01:00
Weblate
97605cfb46 Translated using Weblate (Finnish)
Currently translated at 4.5% (12 of 263 strings)

Translated using Weblate (Russian)

Currently translated at 100.0% (263 of 263 strings)

Translated using Weblate (Indonesian)

Currently translated at 100.0% (263 of 263 strings)

Translated using Weblate (French)

Currently translated at 100.0% (263 of 263 strings)

Translated using Weblate (Spanish)

Currently translated at 23.5% (62 of 263 strings)

Translated using Weblate (German)

Currently translated at 82.1% (216 of 263 strings)

Co-authored-by: Leonid Maslakov <root@lcomrade.su>
Co-authored-by: Linerly <linerly@protonmail.com>
Co-authored-by: Michael <misc+weblatewoodp@zarb.org>
Co-authored-by: Skyler Mäntysaari <sm+woodpecker-ci@skym.fi>
Co-authored-by: Yoel nunez <y.nunez@floms.com>
Co-authored-by: qwerty287 <ndev@web.de>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/de/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/es/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/fi/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/fr/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/id/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/ru/
Translation: Woodpecker CI/UI
2023-03-08 06:30:13 +00:00
Weblate
2697663180 Added translation using Weblate (Finnish)
Co-authored-by: Skyler Mäntysaari <sm+woodpecker-ci@skym.fi>
2023-03-06 08:01:25 +00:00
Weblate
94a972ef3b Translated using Weblate (Russian)
Currently translated at 100.0% (262 of 262 strings)

Translated using Weblate (Indonesian)

Currently translated at 100.0% (262 of 262 strings)

Translated using Weblate (French)

Currently translated at 100.0% (262 of 262 strings)

Co-authored-by: Leonid Maslakov <root@lcomrade.su>
Co-authored-by: Linerly <linerly@protonmail.com>
Co-authored-by: Michael <misc+weblatewoodp@zarb.org>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/fr/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/id/
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/ru/
Translation: Woodpecker CI/UI
2023-03-06 06:33:09 +00:00
Hayden
72784bc11a
Add note about docker image cleanup (#1597)
Closes #1532

Adds notes about images not being cleaned up by wood-pecker and provides
examples on how you can automate the cleanup. Also provides a warning
that these are destructive actions.

<img width="1020" alt="CleanShot 2023-03-03 at 09 36 35@2x"
src="https://user-images.githubusercontent.com/64056131/222800658-f610d488-f8ea-4aca-8ed0-f26e44be1884.png">

---------

Co-authored-by: Anbraten <anton@ju60.de>
2023-03-06 07:33:02 +01:00
Alexander Matyushentsev
d35ab57f80
Add confirm for secret deletion (#1604)
Closes https://github.com/woodpecker-ci/woodpecker/issues/1483

PR adds a confirmation dialog that warns user before deleting a secret. 


https://user-images.githubusercontent.com/426437/222985225-9e14ddac-6c5a-4aed-ac89-cc6562180ac6.mov


Using just basic
[window.Confirm](https://developer.mozilla.org/en-US/docs/Web/API/Window/confirm)
since it is used in
[other](https://github.com/search?q=repo%3Awoodpecker-ci%2Fwoodpecker+confirm%28&type=code)
places. Any objections to switch to proper dialog component in a
separate PR?

Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
2023-03-06 07:07:40 +01:00
Hayden
73c47bd2ff
Add collapsable support to panel elements (#1601)
Closes #1312

Updates the `Panel` component to support collapsing 

## Example



https://user-images.githubusercontent.com/64056131/222880570-6611fdd7-4577-4ed5-9798-fce829a4a752.mp4

---------

Co-authored-by: Anbraten <anton@ju60.de>
2023-03-05 07:50:04 +01:00
Hayden
0148151f3d
Add cancel button on secrets tab (#1599) 2023-03-04 13:03:35 +01:00
Hayden
a2f226f7f9
fix: return 404 on badge request for inactive repo (#1600)
closes #1427 with suggested edit.
2023-03-04 11:36:13 +01:00
John Olheiser
9d90b1ffb7
Update when-path for Gitea (#1598)
As title, looks like it should have been updated at the same time as the
other notice.
2023-03-03 15:43:05 -06:00
Weblate
15a50bc0a3 Translated using Weblate (Polish)
Currently translated at 97.3% (254 of 261 strings)

Co-authored-by: Marcin Puc <tranzystorek.io@protonmail.com>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/pl/
Translation: Woodpecker CI/UI
2023-03-01 17:29:37 +00:00
Anbraten
0bcbcb354f
Rename multi pipelines to workflows (#1285)
Co-authored-by: 6543 <6543@obermui.de>
2023-02-28 18:52:53 +01:00
Anbraten
c5f14180fb
Change issue template labels (#1593) 2023-02-28 18:31:40 +01:00
Anbraten
c05b51fb54
Add version notes to docs (#1592) 2023-02-28 17:30:25 +01:00
Weblate
0940223472 Translated using Weblate (Polish)
Currently translated at 87.7% (229 of 261 strings)

Co-authored-by: Marcin Puc <tranzystorek.io@protonmail.com>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/pl/
Translation: Woodpecker CI/UI
2023-02-28 15:29:36 +00:00
smainz
156b321c2d
Sort repos by org and name (#1548)
Ensure that repos are sorted in the UI after doing a search.

See #1466

Co-authored-by: Anbraten <anton@ju60.de>
2023-02-28 11:14:19 +01:00
Weblate
003773540b Translated using Weblate (Polish)
Currently translated at 84.6% (221 of 261 strings)

Co-authored-by: Marcin Puc <tranzystorek.io@protonmail.com>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/pl/
Translation: Woodpecker CI/UI
2023-02-26 20:28:52 +00:00
6543
2a7f4728a5
Move helm charts to own repo "helm" (#1589)
-> https://github.com/woodpecker-ci/helm
2023-02-23 15:22:01 +02:00
Stephen Muth
be4ce2e02d
Ensure the SharedInformerFactory closes eventually (#1585)
Otherwise it will continue to collect events in the background, consuming memory that can't be GC'd.
2023-02-16 00:54:33 +01:00
Brian King
f71e623b09
Update 15-agent-config.md (#1578)
Document DOCKER_HOST environment variable as described at
https://github.com/woodpecker-ci/woodpecker/pull/763
2023-02-10 05:05:21 +01:00
Weblate
7c4972a16f Translated using Weblate (Russian)
Currently translated at 100.0% (261 of 261 strings)

Co-authored-by: Leonid Maslakov <root@lcomrade.su>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/ru/
Translation: Woodpecker CI/UI
2023-02-07 07:29:29 +00:00
Weblate
fe97d37c92 Translated using Weblate (Russian)
Currently translated at 100.0% (261 of 261 strings)

Co-authored-by: Leonid Maslakov <root@lcomrade.su>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/ru/
Translation: Woodpecker CI/UI
2023-02-04 14:29:28 +00:00
Weblate
18ea3a3569 Translated using Weblate (French)
Currently translated at 100.0% (261 of 261 strings)

Co-authored-by: Michael <misc+weblatewoodp@zarb.org>
Translate-URL: http://translate.woodpecker-ci.org/projects/woodpecker-ci/ui/fr/
Translation: Woodpecker CI/UI
2023-02-02 20:03:50 +00:00
6543
18d3139e9e
Use modern error handling and enforce it via lint (#1327)
Co-authored-by: Anbraten <anton@ju60.de>
2023-02-02 00:08:02 +01:00