Initial commit: nult - Ansible deployment toolkit
Merged from veridion-gitea and veridion-act-runner-gitea repos. nult (Null-T) - instant teleportation from Strugatsky's Noon Universe. Like Null-T, this toolkit instantly deploys infrastructure. Roles: - gitea: Gitea server with PostgreSQL (Docker Compose) - act_runner: Gitea Actions runner Playbooks: - gitea.yml: Deploy Gitea server - act-runner.yml: Deploy Act Runner - site.yml: Deploy all services Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
53
act-runner.yml
Normal file
53
act-runner.yml
Normal file
@@ -0,0 +1,53 @@
|
||||
---
|
||||
# =============================================================================
|
||||
# Gitea Act Runner Deployment Playbook
|
||||
# =============================================================================
|
||||
#
|
||||
# Deploys and configures Gitea Act Runner on Ubuntu servers.
|
||||
#
|
||||
# Usage:
|
||||
# ansible-playbook -i inventory/hosts.yml act-runner.yml --ask-vault-pass
|
||||
#
|
||||
# Dry run:
|
||||
# ansible-playbook -i inventory/hosts.yml act-runner.yml --check --diff --ask-vault-pass
|
||||
#
|
||||
# =============================================================================
|
||||
|
||||
- name: Deploy Gitea Act Runner
|
||||
hosts: runner_servers
|
||||
become: true
|
||||
gather_facts: true
|
||||
|
||||
pre_tasks:
|
||||
- name: Validate target operating system
|
||||
ansible.builtin.assert:
|
||||
that:
|
||||
- ansible_facts['distribution'] == "Ubuntu"
|
||||
- ansible_facts['distribution_major_version'] | int >= 20
|
||||
fail_msg: >-
|
||||
This playbook requires Ubuntu 20.04 or later.
|
||||
Detected: {{ ansible_facts['distribution'] }} {{ ansible_facts['distribution_version'] }}
|
||||
|
||||
- name: Update apt package cache
|
||||
ansible.builtin.apt:
|
||||
update_cache: true
|
||||
cache_valid_time: 3600
|
||||
|
||||
roles:
|
||||
- role: act_runner
|
||||
tags: [act_runner]
|
||||
|
||||
post_tasks:
|
||||
- name: Display deployment summary
|
||||
ansible.builtin.debug:
|
||||
msg:
|
||||
- "=============================================="
|
||||
- "Gitea Act Runner - Deployment Complete"
|
||||
- "=============================================="
|
||||
- "Runner name: {{ act_runner_name }}"
|
||||
- "Gitea instance: {{ gitea_instance_url }}"
|
||||
- "Service status: {{ 'RUNNING' if act_runner_service_status.status.ActiveState == 'active' else 'NOT RUNNING' }}"
|
||||
- ""
|
||||
- "Verify in Gitea UI:"
|
||||
- " {{ gitea_instance_url }}/-/admin/actions/runners"
|
||||
- "=============================================="
|
||||
Reference in New Issue
Block a user