summaryrefslogtreecommitdiffstats
path: root/internal (follow)
Commit message (Collapse)AuthorAgeFilesLines
* fix: use data.forgejo.org/ociEarl Warren3 days1-1/+1
| | | | Otherwise it may get rate limited in the CI verifying it works
* New "one shot" type of execution by adding a new command called one-job. (#423)cobak783 days4-0/+389
| | | | | | | | | | As commented here https://code.forgejo.org/forgejo/runner/issues/422, this PR aims to allow a new type of one shot execution compatible with autoscaling features and other job types. Co-authored-by: jaime merino <jaime.merino_mora@mail.schwarzª> Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/423 Reviewed-by: earl-warren <earl-warren@noreply.code.forgejo.org> Co-authored-by: cobak78 <cobak78@noreply.code.forgejo.org> Co-committed-by: cobak78 <cobak78@noreply.code.forgejo.org>
* expose "ForceRebuild" as a config optiongratux2024-12-294-1/+5
|
* Merge pull request 'Rebrand container prefix to Forgejo' (#377) from ↵earl-warren2024-12-151-1/+1
|\ | | | | | | | | | | | | fnetx/rebrand-prefix into main Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/377 Reviewed-by: earl-warren <earl-warren@noreply.code.forgejo.org>
| * Rebrand container prefix to ForgejoOtto Richter2024-12-091-1/+1
| |
* | feat: use FORGEJO_TOKEN as runtime tokenxtex2024-12-132-2/+6
|/ | | | Link: https://codeberg.org/forgejo/forgejo/pulls/6199
* fix: [container].docker_host = "" is now "automount"Earl Warren2024-11-273-11/+5
| | | | | | | | | | | The empty string is always replaced with "-" and there no longer is any way to specify that the docker socket is to be mounted in the container automatically. The "automount" value is introduced as a replacement. https://code.forgejo.org/forgejo/act/pulls/67 and https://code.forgejo.org/forgejo/runner/pulls/305 introduced this regression.
* fix: make container.docker_host default to - (part two)Earl Warren2024-11-152-0/+5
| | | | If --config is not specified, the default must also be "-" and not ""
* Cherry-pick gitea act_runner #543Kwonunn2024-11-032-0/+28
| | | | | | | | | | From: https://gitea.com/gitea/act_runner/commit/1735b26e66f8e81c526204c128f1bcfd7f578906 Don't log job output when debug logging is not enabled We wanted the ability to disable outputting the logs from the individual job to the console. This changes the logging so that job logs are only output to the console whenever debug logging is enabled in `act_runner`, while still allowing the `Reporter` to receive these logs and forward them to Gitea when debug logging is not enabled. Signed-off-by: Kwonunn <kwonunnx@gmail.com>
* Add simple testThorben Günther2024-11-021-0/+7
|
* Add configurable logging level for jobsThorben Günther2024-11-023-1/+16
| | | | | | This changes the default for JobLoggerLevel from "trace" to "info". Closes #298
* fix: make container.docker_host default to -Earl Warren2024-10-291-8/+8
| | | | | Otherwise containers will be running by default with a socket to the docker host which is insecure. The default must be secure.
* chore: add test for unexpected YAML type in top level envEarl Warren2024-09-151-5/+27
|
* chore: bump actions-proto-go to v0.4.0Mike Rochefort2024-07-3111-11/+11
| | | | | | | bufbuild/connect-go was archived with maintenance transferred to the ConnectRPC organization. Gitea's protobuf library for actions now uses the ConnectRPC dependency as of v0.4.0, removing the need to continue using the dead package.
* Add report_interval option to configLennart Austenfeld2024-07-275-13/+22
|
* Fix typo in create-runner-file help text (Frogejo -> Forgejo)9pfs2024-06-281-1/+1
|
* wait for jobs to complete when stopping the runnerEarl Warren2024-06-076-31/+371
| | | | | | | | | | | | | | | | When receiving a signal (INT or TERM) wait for running jobs to complete instead of terminating them right away. The new shutdown_timeout configuration setting can be used to force the termination after a grace delay. If not specified or zero it will shutdown immediately, for backward compatibility. It will be the case with existing configuration files or when a configuration file is not specified. The config.yml created with the generate-config subcommand will however default shutdown_timeout to 3h (same as timeout) because it is likely what a new admin would expect: shutting down waits for jobs to complete and not abort them.
* Upgrade the default container to node:20Earl Warren2024-06-074-7/+6
| | | | Fixes: https://code.forgejo.org/forgejo/runner/issues/168
* Add support for workflow inputsMai-Lapyst2024-05-241-0/+8
| | | | | | | | | This is a somewhat "hacky" way; it copies the inputs from the "event" object's "inputs" field when the event is a "workflow_dispatch". But this way we do not need to change the protobuf powered runner protocol to also include the inputs. Espc. since they're also present inside the event anyway.
* typo in error messageAndreas Wachter2024-05-031-1/+1
|
* Update testsMai-Lapyst2024-04-201-2/+2
|
* Handle group commandsMai-Lapyst2024-04-201-4/+5
| | | | | Add handling of the `::group::` and `::endgroup::` command to produce github like results.
* replace Nil with NoErrorTheFox0x72024-04-101-3/+2
|
* added simple test to label updateTheFox0x72024-04-101-0/+38
|
* add label change post runner creationTheFox0x72024-04-102-1/+5
|
* after reading labels, load them into registrationTheFox0x72024-04-101-0/+1
|
* daemon: improve error messagesFrank Villaro-Dixon2024-04-101-3/+3
| | | | Signed-off-by: Frank Villaro-Dixon <frank@villaro-dixon.eu>
* Support cloning remote actions from insecure Gitea instances (#508)Earl Warren2024-03-111-0/+1
| | | | (cherry picked from commit 75006a59cc4e6d18653926ec2578de5072ba6c32)
* Set the status of steps to `skipped` if job is skipped (#500)sillyguodong2024-03-111-0/+3
| | | | | | | | | | | If a job is detected as skipped, its steps should also be `skipped`. Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/500 Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: sillyguodong <gedong_1994@163.com> Co-committed-by: sillyguodong <gedong_1994@163.com> (cherry picked from commit 45270656dfb7a0c8b382df3a9e8a212dbe5615d8)
* Add ACTIONS_RESULTS_URL to env (#473)Christopher Homberger2024-03-111-0/+1
| | | | | | | | | | | | | actions/upload-artifact@v4 and actions/download-artifact@v4 depend on this variable BaseUrl in a url are ignored by the nodejs code of the new actions, so this change doesn't append the path of the older `ACTIONS_RUNTIME_URL`. Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/473 Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: Christopher Homberger <christopher.homberger@web.de> Co-committed-by: Christopher Homberger <christopher.homberger@web.de> (cherry picked from commit e14f42c40ac91d032c6a7c3e912646e55b2031a8)
* Use artifacts v4 jwt if available (#471)Christopher Homberger2024-03-112-2/+9
| | | | | | | | | | | | | | Needs https://github.com/go-gitea/gitea/pull/28885 to provide jwt if sent by server Could fix #459, but that has not been verified. Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/471 Reviewed-by: delvh <dev.lh@web.de> Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: Christopher Homberger <christopher.homberger@web.de> Co-committed-by: Christopher Homberger <christopher.homberger@web.de> (cherry picked from commit e6630e2e369f41fc9d9f9e570610611da18dda1d)
* Sanitize UFT-8 content in logs (#453)hakito2024-03-112-2/+2
| | | | | | | | | | | | | | | | I accidently closed my previous PR #384 This PR replaces invalid UTF-8 character in a stream with `?` character. On Windows Server 2019 other characters are replaced by `?` as well so it's consistent. fixes #452 Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/453 Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com> Reviewed-by: Jason Song <i@wolfogre.com> Co-authored-by: hakito <hakito@noreply.gitea.com> Co-committed-by: hakito <hakito@noreply.gitea.com> (cherry picked from commit daf52d0e628d2d57b9f50a2556e404a3f05c34aa)
* Fix #404: nil map error when reading env file (#405)infinoid2024-03-111-0/+3
| | | | | | | | | Co-authored-by: Mark Glines <mark@glines.org> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/405 Reviewed-by: Jason Song <i@wolfogre.com> Co-authored-by: infinoid <infinoid@noreply.gitea.com> Co-committed-by: infinoid <infinoid@noreply.gitea.com> (cherry picked from commit 934471813a41efabf6a9b5d5b22a2a5770ff12ce)
* Increase fetch interval for CodebergGusted2024-01-213-0/+49
| | | | | | Increase the fetch interval to at least 30 seconds if the runner is configured to be used with Codeberg. This avoids it being rate limited when they do actual work and reduces load on Codeberg.
* chore: make fmts3lph2023-11-151-24/+24
|
* feat(docker): Add flag to enable IPv6 in auto-created networkss3lph2023-11-144-52/+60
|
* [FORGEJO] add support for the lxc:// schemeEarl Warren2023-11-091-1/+4
|
* [FORGEJO] add the create-runner-fileEarl Warren2023-08-234-1/+285
|
* [FORGEJO] no double / in WorkDir, it would fail local actionsEarl Warren2023-08-231-1/+1
|
* [FORGEJO] default labels to a single dockerEarl Warren2023-08-231-4/+1
|
* [FORGEJO] brandingEarl Warren2023-08-234-14/+14
|
* [FORGEJO] look for workflows in the .forgejo/workflows directoryEarl Warren2023-08-231-2/+2
|
* [FORGEJO] GITHUB_SERVER_URL is always the runner registration addrEarl Warren2023-08-231-0/+7
|
* change podman socket path (#341)TheFox0x72023-08-211-1/+2
| | | | | | | | | | port of https://github.com/nektos/act/pull/1961 closes gitea/act_runner#274 Reviewed-on: https://gitea.com/gitea/act_runner/pulls/341 Reviewed-by: Jason Song <i@wolfogre.com> Co-authored-by: TheFox0x7 <thefox0x7@gmail.com> Co-committed-by: TheFox0x7 <thefox0x7@gmail.com>
* Add ForcePull option (#339)Gianni Angelozzi2023-08-173-1/+4
| | | | | | | | | | | Close #271 What it does: instead of forcing the value of `ForcePull` to false, the user can now configure it on the runner yaml Reviewed-on: https://gitea.com/gitea/act_runner/pulls/339 Reviewed-by: Jason Song <i@wolfogre.com> Co-authored-by: Gianni Angelozzi <gianni@sistema3.it> Co-committed-by: Gianni Angelozzi <gianni@sistema3.it>
* Reduce unnecessary DB queries for Actions tasks (#219)sillyguodong2023-07-251-5/+23
| | | | | | | | | | | | | | | | | | implement: https://github.com/go-gitea/gitea/issues/24544 Changes: - Add a global variable `tasksVersion` to store the lastest version number which returned by Gitea. - Pass `tasksVersion` to Gitea when invoking `FetchTask`. - If there is no task in the `FetchTask` response, store the version from the `FetchTask` response into `tasksVersion` variable. - If there is a task in the `FetchTask` response, set `tasksVersion` to zero to focre query db in next `FetchTask` request. Related: - Protocol: https://gitea.com/gitea/actions-proto-def/pulls/10 - Gitea side: https://github.com/go-gitea/gitea/pull/25199 Reviewed-on: https://gitea.com/gitea/act_runner/pulls/219 Co-authored-by: sillyguodong <gedong_1994@163.com> Co-committed-by: sillyguodong <gedong_1994@163.com>
* fix endless loop (#306)caicandong2023-07-241-13/+13
| | | | | | | | | | fix endless loop in poll relate #305 Co-authored-by: CaiCandong <1290147055@qq.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/306 Co-authored-by: caicandong <caicandong@noreply.gitea.com> Co-committed-by: caicandong <caicandong@noreply.gitea.com>
* Catch the panic and print the error (#305)caicandong2023-07-241-11/+23
| | | | | | | | | | refactor # 215 Catch the panic and print the error close #215 Co-authored-by: CaiCandong <1290147055@qq.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/305 Co-authored-by: caicandong <caicandong@noreply.gitea.com> Co-committed-by: caicandong <caicandong@noreply.gitea.com>
* Add tips in config file (#297)Jason Song2023-07-201-0/+3
| | | | Reviewed-on: https://gitea.com/gitea/act_runner/pulls/297
* ci(lint): refactor code for clarity and linting compliance (#289)Bo-Yi Wu2023-07-135-18/+16
| | | | | | | | | | | | | | | | - Removed `deadcode`, `structcheck`, and `varcheck` linters from `.golangci.yml` - Fixed a typo in a comment in `daemon.go` - Renamed `defaultActionsUrl` to `defaultActionsURL` in `exec.go` - Removed unnecessary else clause in `exec.go` and `runner.go` - Simplified variable initialization in `exec.go` - Changed function name from `getHttpClient` to `getHTTPClient` in `http.go` - Removed unnecessary else clause in `labels_test.go` Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/289 Co-authored-by: Bo-Yi Wu <appleboy.tw@gmail.com> Co-committed-by: Bo-Yi Wu <appleboy.tw@gmail.com>