added a few files

This commit is contained in:
Bertrand Lanson 2023-07-27 15:11:38 +02:00
parent da1511e2e4
commit 797290d35d
5 changed files with 89 additions and 1 deletions

View File

@ -1,2 +1,30 @@
---
# defaults file for deploy_gitea_runner
# defaults file for deploy_adguard
deploy_gitea_runner_directory: /opt/adguard
deploy_gitea_runner_timezone: "Europe/Paris"
deploy_gitea_runner_start_service: false
deploy_gitea_runner_config:
log:
level: debug
runner:
file: .runner
capacity: 1
envs:
env_file: .env
timeout: 3h
insecure: false
fetch_timeout: 5s
fetch_interval: 15s
labels:
- alpine-latest:docker://node:16-alpine
- alpine-3.18:docker://node:16-alpine3.18
- alpine-3.17:docker://node:16-alpine3.17
- alpine-3.16:docker://node:16-alpine3.16
- ubuntu-latest:docker://ghcr.io/catthehacker/ubuntu:act-latest
- ubuntu-22.04:docker://ghcr.io/catthehacker/ubuntu:act-22.04
- ubuntu-20.04:docker://ghcr.io/catthehacker/ubuntu:act-20.04
cache:
enabled: false
container:
network: "gitea-actions_internal"
privileged: true

View File

2
templates/config.yaml.j2 Normal file
View File

@ -0,0 +1,2 @@
# {{ ansible_managed }}
{{ deploy_adguard_config | to_yaml }}

View File

@ -0,0 +1,45 @@
---
version: '3.9'
services:
runner:
image: gitea/act_runner:latest
configs:
- source: config_yaml
target: /config.yaml
environment:
CONFIG_FILE: /config.yaml
GITEA_INSTANCE_URL: "https://git.ednz.fr"
GITEA_RUNNER_REGISTRATION_TOKEN: "cWetxKkQT0EpdEkh5K9E7Cq5a7t0RWv5BCUnmuxP"
GITEA_RUNNER_NAME: "hs1-actions-runner"
volumes:
- data:/data
- cache:/cache
- /var/run/docker.sock:/var/run/docker.sock
ports:
- target: 1234
published: 1234
protocol: tcp
mode: ingress
networks:
- internal
networks:
internal:
driver: bridge
volumes:
data:
driver_opts:
o: bind
device: /opt/gitea-actions/data
type: none
cache:
driver_opts:
o: bind
device: /opt/gitea-actions/cache
type: none
configs:
config_yaml:
file: /opt/gitea-actions/config.yaml

View File

@ -0,0 +1,13 @@
[Unit]
Description=Free and open source, powerful network-wide ads & trackers blocking DNS server.
After=docker.service
Requires=docker.service
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/bin/bash -c "docker-compose -f {{ deploy_adguard_directory }}/docker-compose.yml up --detach"
ExecStop=/bin/bash -c "docker-compose -f {{ deploy_adguard_directory }}/docker-compose.yml down"
[Install]
WantedBy=multi-user.target