From 1887e1cca6e988786c600660f2e1090bf69cbf2e Mon Sep 17 00:00:00 2001 From: Johannes Stoelp Date: Sat, 26 Aug 2023 23:22:18 +0200 Subject: git: add runner to mirror github projects --- roles/git/tasks/main.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'roles/git/tasks/main.yml') diff --git a/roles/git/tasks/main.yml b/roles/git/tasks/main.yml index 75dec39..2d0e065 100644 --- a/roles/git/tasks/main.yml +++ b/roles/git/tasks/main.yml @@ -9,6 +9,7 @@ loop: - gitolite-cgit - runner-zola + - runner-mirror - name: Build gitolite cgit image containers.podman.podman_image: @@ -63,3 +64,22 @@ # Use 'z' to shared-ly relable selinux contexts. - "{{ DATA_ROOT }}/nginx/www:/www:z" recreate: "{{ runner_zola_build.changed }}" + +- name: Build mirror runner image + containers.podman.podman_image: + name: runner-mirror + path: "{{ DATA_ROOT }}/git/runner-mirror" + force: true + register: runner_mirror_build + +- name: Start mirror runner + containers.podman.podman_container: + name: runner-mirror + image: runner-mirror + network: "{{ NETWORK }}" + volumes: + # Use 'z' to shared-ly relable selinux contexts. + - "{{ DATA_ROOT }}/git/repos/projects.list:/projects.list:ro,z" + # Use 'Z' to privately relable selinux contexts. + - "{{ DATA_ROOT }}/git/runner-mirror/mirror.key:/mirror.key:ro,Z" + recreate: "{{ runner_mirror_build.changed }}" -- cgit v1.2.3