public inbox for kdevops@lists.linux.dev
 help / color / mirror / Atom feed
* [RFC PATCH 1/3] linux-mirror: Add Fedora-specific tasks
@ 2024-05-01 14:03 cel
  2024-05-01 14:03 ` [RFC PATCH 2/3] get-distro-default-bridge.sh: Remove "http://" cel
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: cel @ 2024-05-01 14:03 UTC (permalink / raw)
  To: kdevops; +Cc: Chuck Lever

From: Chuck Lever <chuck.lever@oracle.com>

To get mirroring to work on Fedora, I had to install the git-daemon
package, because on Fedora, git-daemon is not included in the
git-core package.

Also, Fedora's default firewall configuration does not permit git
traffic.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
---
 .../tasks/install-deps/fedora/main.yml        | 24 +++++++++++++++++++
 playbooks/roles/linux-mirror/tasks/main.yml   |  5 ++++
 2 files changed, 29 insertions(+)
 create mode 100644 playbooks/roles/linux-mirror/tasks/install-deps/fedora/main.yml

diff --git a/playbooks/roles/linux-mirror/tasks/install-deps/fedora/main.yml b/playbooks/roles/linux-mirror/tasks/install-deps/fedora/main.yml
new file mode 100644
index 000000000000..2a93256a3d6e
--- /dev/null
+++ b/playbooks/roles/linux-mirror/tasks/install-deps/fedora/main.yml
@@ -0,0 +1,24 @@
+---
+- name: Install Fedora-specific dependencies
+  become: true
+  become_flags: 'su - -c'
+  become_method: ansible.builtin.sudo
+  ansible.builtin.package:
+    name:
+      - git-daemon
+    state: present
+  when:
+    - install_linux_mirror|bool
+
+- name: Open the firewall on control node for git traffic
+  become: true
+  become_flags: 'su - -c'
+  become_method: ansible.builtin.sudo
+  ansible.posix.firewalld:
+    zone: libvirt
+    port: 9418/tcp
+    permanent: true
+    immediate: true
+    state: enabled
+  when:
+    - install_linux_mirror|bool
diff --git a/playbooks/roles/linux-mirror/tasks/main.yml b/playbooks/roles/linux-mirror/tasks/main.yml
index 461e131c93fd..a8f673c6d4ee 100644
--- a/playbooks/roles/linux-mirror/tasks/main.yml
+++ b/playbooks/roles/linux-mirror/tasks/main.yml
@@ -10,6 +10,11 @@
       skip: true
   tags: vars
 
+- name: Install dependencies for the linux-mirror role
+  ansible.builtin.include_tasks: install-deps/fedora/main.yml
+  when:
+    - ansible_distribution == 'Fedora'
+
 - name: Set up the mirrors.yaml based on preferences configured
   tags: [ 'mirror' ]
   template:

base-commit: d97440f49b5b5ecb65383a1874014391ca795899
-- 
2.44.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-05-02 13:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-01 14:03 [RFC PATCH 1/3] linux-mirror: Add Fedora-specific tasks cel
2024-05-01 14:03 ` [RFC PATCH 2/3] get-distro-default-bridge.sh: Remove "http://" cel
2024-05-01 14:03 ` [RFC PATCH 3/3] get-distro-default-bridge.sh: Set specific IP address for Fedora cel
2024-05-01 14:29 ` [RFC PATCH 1/3] linux-mirror: Add Fedora-specific tasks Chuck Lever
2024-05-01 19:12 ` Luis Chamberlain
2024-05-02 13:12   ` Chuck Lever III

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox