This role will install and configure act-runner, the runner for Gitea Actions, Gitea's built-in CI/CD system, and register it on a Gitea instance.
You can configure it to run workflows in rootless podman containers, docker containers, or directly on the host.
See meta/main.yml
# playbook.yml
- hosts: my.CHANGEME.org
roles:
- nodiscc.xsrv.podman # if using gitea_act_runner_container_engine: "podman" (the default)
- nodiscc.xsrv.docker # if using gitea_act_runner_container_engine: "docker"
- nodiscc.xsrv.gitea # (optional) gitea git service (can also be deployed to a different host)
- nodiscc.xsrv.gitea_act_runner
# required variables
# host_vars/my.CHANGEME.org/my.CHANGEME.org.yml
gitea_act_runner_gitea_instance_fqdn: "git.CHANGEME.org" # required if the runner and gitea instance are on different hosts
gitea_act_runner_gitea_instance_hostname: "my2.CHANGEME.org" # required if the runner and gitea instance are on different hosts
See defaults/main.yml for all configuration variables.
The gitea instance you want to register the runner on, must be managed by the same ansible playbook/project - at least, the hostname must be present in the inventory, and its become
credentials in the corresponding host_vars/vault file, as they are used for automatically creating the runner token and register it on the instance.
See Gitea actions quickstart. Gitea actions use the same workflow syntax as Github actions.
Note that base images/environments in which Gitea actions are run are different from Github actions environments. Getting Github actions workflows to run in Gitea actions may require some adjustments.
To force re-registering the runner, open a shell on the host (xsrv shell default my.example.org
) and run sudo rm /var/lib/act-runner/.runner
before re-running the playbook/gitea_act_runner
role/tag.
There is no data worth backing up.
gitea_act_runner - setup gitea CI/CD runner (act-runner)