From 7e5b723a3a2375291db7019daf6fc54d14e42e69 Mon Sep 17 00:00:00 2001
From: Alexander Dahl <alex@netz39.de>
Date: Fri, 28 Feb 2025 08:36:12 +0100
Subject: [PATCH 1/2] :rotating_light: roles: nfs_host: Rename

Roles names are expected to be lower case with underscores only,
see ansible-lint warning:

    % ansible-lint -t role-name
    WARNING  Listing 1 violation(s) that are fatal
    role-name: Role name nfs-host does not match ``^[a-z][a-z0-9_]*$`` pattern.
    roles/nfs-host:1

    Read documentation for instructions on how to ignore specific rule violations.

                 Rule Violation Summary
     count tag       profile rule associated tags
         1 role-name basic   deprecations, metadata

    Failed after min profile: 1 failure(s), 0 warning(s) on 135 files.

Fixes: 213887052097 ("nfs server wird nicht im k3s laufen, labeling entfernt")
---
 host-plumbum.yml                                  | 2 +-
 roles/{nfs-host => nfs_host}/defaults/main.yml    | 2 +-
 roles/{nfs-host => nfs_host}/handlers/main.yml    | 0
 roles/{nfs-host => nfs_host}/tasks/main.yml       | 0
 roles/{nfs-host => nfs_host}/templates/exports.j2 | 0
 5 files changed, 2 insertions(+), 2 deletions(-)
 rename roles/{nfs-host => nfs_host}/defaults/main.yml (87%)
 rename roles/{nfs-host => nfs_host}/handlers/main.yml (100%)
 rename roles/{nfs-host => nfs_host}/tasks/main.yml (100%)
 rename roles/{nfs-host => nfs_host}/templates/exports.j2 (100%)

diff --git a/host-plumbum.yml b/host-plumbum.yml
index d9aa737..e0c3433 100644
--- a/host-plumbum.yml
+++ b/host-plumbum.yml
@@ -3,7 +3,7 @@
   become: true
 
   roles:
-    - role: nfs-host
+    - role: nfs_host
       vars:
         nfs_host_exports:
           - directory: "/srv/nfs/backup"
diff --git a/roles/nfs-host/defaults/main.yml b/roles/nfs_host/defaults/main.yml
similarity index 87%
rename from roles/nfs-host/defaults/main.yml
rename to roles/nfs_host/defaults/main.yml
index 210a3be..ee0d286 100644
--- a/roles/nfs-host/defaults/main.yml
+++ b/roles/nfs_host/defaults/main.yml
@@ -1,4 +1,4 @@
-# Defaults for nfs-host
+# Defaults for nfs_host
 ---
 nfs_host_exports: []
   # - directory: "/srv/nfs"
diff --git a/roles/nfs-host/handlers/main.yml b/roles/nfs_host/handlers/main.yml
similarity index 100%
rename from roles/nfs-host/handlers/main.yml
rename to roles/nfs_host/handlers/main.yml
diff --git a/roles/nfs-host/tasks/main.yml b/roles/nfs_host/tasks/main.yml
similarity index 100%
rename from roles/nfs-host/tasks/main.yml
rename to roles/nfs_host/tasks/main.yml
diff --git a/roles/nfs-host/templates/exports.j2 b/roles/nfs_host/templates/exports.j2
similarity index 100%
rename from roles/nfs-host/templates/exports.j2
rename to roles/nfs_host/templates/exports.j2

From 94bdf607008513f6988c0f3f2d7abb35fbaf8402 Mon Sep 17 00:00:00 2001
From: Alexander Dahl <alex@netz39.de>
Date: Fri, 28 Feb 2025 08:43:04 +0100
Subject: [PATCH 2/2] :rotating_light: roles: setup_http_site_forward: Rename

Roles names should be lowercase with underscores only.
ansible-lint complained:

    % ansible-lint -t role-name
    WARNING  Listing 1 violation(s) that are fatal
    role-name: Role name setup-http-site-forward does not match ``^[a-z][a-z0-9_]*$`` pattern.
    roles/setup-http-site-forward:1

    Read documentation for instructions on how to ignore specific rule violations.

                 Rule Violation Summary
     count tag       profile rule associated tags
         1 role-name basic   deprecations, metadata

    Failed after min profile: 1 failure(s), 0 warning(s) on 135 files.

Fixes: 85c09ea2ae7f ("Add role for apache forward site")
---
 host-tau.yml                                                    | 2 +-
 .../handlers/main.yml                                           | 0
 .../tasks/main.yml                                              | 0
 .../templates/apache-docker-forward-site.j2                     | 0
 4 files changed, 1 insertion(+), 1 deletion(-)
 rename roles/{setup-http-site-forward => setup_http_site_forward}/handlers/main.yml (100%)
 rename roles/{setup-http-site-forward => setup_http_site_forward}/tasks/main.yml (100%)
 rename roles/{setup-http-site-forward => setup_http_site_forward}/templates/apache-docker-forward-site.j2 (100%)

diff --git a/host-tau.yml b/host-tau.yml
index ee5e2a4..64c7c56 100644
--- a/host-tau.yml
+++ b/host-tau.yml
@@ -191,7 +191,7 @@
 
     - name: Setup forwarding for Discord invite
       include_role:
-        name: setup-http-site-forward
+        name: setup_http_site_forward
       vars:
         site_name: "{{ discord_invite_domain }}"
         # forward_to: "https://discord.com/invite/8FcDvAf"
diff --git a/roles/setup-http-site-forward/handlers/main.yml b/roles/setup_http_site_forward/handlers/main.yml
similarity index 100%
rename from roles/setup-http-site-forward/handlers/main.yml
rename to roles/setup_http_site_forward/handlers/main.yml
diff --git a/roles/setup-http-site-forward/tasks/main.yml b/roles/setup_http_site_forward/tasks/main.yml
similarity index 100%
rename from roles/setup-http-site-forward/tasks/main.yml
rename to roles/setup_http_site_forward/tasks/main.yml
diff --git a/roles/setup-http-site-forward/templates/apache-docker-forward-site.j2 b/roles/setup_http_site_forward/templates/apache-docker-forward-site.j2
similarity index 100%
rename from roles/setup-http-site-forward/templates/apache-docker-forward-site.j2
rename to roles/setup_http_site_forward/templates/apache-docker-forward-site.j2