This is a follow up on #1379 and #1381, after fixing those (I noticed
them while building a pipeline for one of my projects) I took a deep
dive into the schema, and consolidated the functionality as far as
possible.
As a reference, I matched it against
pipeline/frontend/yaml/constraint//constraints.go of the release/v0.15
branch.
The .branches while not in the pipeline uses the Type (List) and
functions of pipeline/frontend/yaml/constraint//constraints.go
Regarding the formatting i went with what was already there, since
enabling editorconfig / formatting would have changed most of the file
(not that there is too much untouched after this anyways)
Previously the schema only accepted string, this fixes#1379 and matches
the linter to the existing capabilities of the constraints.go (and
therefore server).
Secret names where matched based on their lowercase value already just the conversion to lowercase for `from_secrets` was missing.
Co-authored-by: Anbraten <anton@ju60.de>
* Allow users not logged in to access branches page
(fixes a nil pointer derefernce)
* Add Gogs support for branches
Co-authored-by: qwerty287 <80460567+qwerty287@users.noreply.github.com>
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.
Co-authored-by: Anbraten <anton@ju60.de>
hotfix #717
This comes from the agent being inactive / not sending and requesting any data if there a no pipelines waiting for him to execute. GRPC seems to only allow 2 pings without calling an actual endpoint before closing the connection. I think this will be indirectly solved in the moment we implement something like #536https://github.com/grpc/grpc/blob/master/doc/keepalive.md
Co-authored-by: Anbraten <anton@ju60.de>
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.
The old docker hub link directs you either to a login page or to your profile. I think it makes more sense to redirect the user directly to available images in the explore tab