Removing all ansible-linter errors
Some checks failed
Ansible Linting / build (push) Failing after 16s
Secops Linting and Safety Checks / checkov-scan-s3 (push) Failing after 18s
Wiki Resources Sanity Checks / ruff-checks (push) Successful in 7s

This commit is contained in:
2026-04-26 01:35:56 -07:00
parent c44babf3d8
commit fbe6e5c3e2
15 changed files with 33 additions and 30 deletions

View File

@@ -2,3 +2,6 @@
skip_list: skip_list:
- role-name - role-name
- var-naming[no-role-prefix] - var-naming[no-role-prefix]
exclude_paths:
- linter.yaml
- inventory.yaml

View File

@@ -6,4 +6,3 @@
- name: Apply the nomad role - name: Apply the nomad role
ansible.builtin.include_role: ansible.builtin.include_role:
name: nomad name: nomad

View File

@@ -8,8 +8,8 @@
- name: Running install on the keyrings directory - name: Running install on the keyrings directory
ansible.builtin.command: ansible.builtin.command:
cmd: install -m 0755 -d /etc/apt/keyrings cmd: install -m 0755 -d /etc/apt/keyrings
register: install register: base_install_keyrings
changed_when: install.rc == 0 changed_when: base_install_keyrings.rc == 0
- name: Fetch Docker GPG Key - name: Fetch Docker GPG Key
vars: vars:
keylink: https://download.docker.com/linux/ubuntu/gpg keylink: https://download.docker.com/linux/ubuntu/gpg
@@ -37,5 +37,5 @@
- name: Verify that the docker components are installed properly - name: Verify that the docker components are installed properly
ansible.builtin.command: ansible.builtin.command:
cmd: docker run hello-world cmd: docker run hello-world
register: docker register: base_docker_hello
changed_when: docker.rc == 0 changed_when: base_docker_hello.rc == 0

View File

@@ -6,3 +6,5 @@
- name: Run installation script - name: Run installation script
ansible.builtin.command: ansible.builtin.command:
cmd: bash /tmp/k3s.sh cmd: bash /tmp/k3s.sh
register: base_k3s_install_script
changed_when: base_k3_install_script.rc == 0

View File

@@ -15,11 +15,3 @@
become: true become: true
tags: tags:
- setup - setup
- name: Run through nomad removal steps
tags: nomad
ansible.builtin.include_tasks:
file: nomad.yaml
apply:
become: true
tags:
- nomad

View File

@@ -2,10 +2,13 @@
ansible.builtin.get_url: ansible.builtin.get_url:
url: https://get.k3s.io url: https://get.k3s.io
dest: /tmp dest: /tmp
register: install_script mode: "0644"
register: k3s_dl_install_script
- name: Run installation script - name: Run installation script
become: true become: true
environment: environment:
INSTALL_K3S_EXEC: server INSTALL_K3S_EXEC: server
ansible.builtin.command: ansible.builtin.command:
cmd: sh {{ install_script.dest }} cmd: sh {{ k3s_dl_install_script.dest }}
register: k3s_install_script
changed_when: k3s_install_script.rc == 0

View File

@@ -3,16 +3,16 @@
block: block:
- name: Ensure the root data directory is present - name: Ensure the root data directory is present
ansible.builtin.file: ansible.builtin.file:
path: "{{ nomad.volumes.root }}" path: "{{ nomad_data.volumes.root }}"
state: absent state: absent
mode: "0755" mode: "0755"
- name: Ensure registry volume is present - name: Ensure registry volume is present
ansible.builtin.file: ansible.builtin.file:
path: "{{ nomad.volumes.registry }}" path: "{{ nomad_data.volumes.registry }}"
state: absent state: absent
mode: "0755" mode: "0755"
- name: Ensure the MinIO diretory is present - name: Ensure the MinIO diretory is present
ansible.builtin.file: ansible.builtin.file:
path: "{{ nomad.volumes.nfs }}" path: "{{ nomad_data.volumes.nfs }}"
state: absent state: absent
mode: "0755" mode: "0755"

View File

@@ -1,4 +1,4 @@
nomad: nomad_data:
volumes: volumes:
root: /opt/volumes root: /opt/volumes
registry: /opt/volumes/ncr registry: /opt/volumes/ncr

View File

@@ -2,12 +2,16 @@
become: true become: true
ansible.builtin.command: ansible.builtin.command:
cmd: docker compose pull cmd: docker compose pull
chdir: "{{ webadmin.home }}/{{ item }}" chdir: "{{ webserver_admin.home }}/{{ item }}"
loop: loop:
- services - services
register: webserver_docker_pull
changed_when: webserver_docker_pull.rc == 0
- name: Restart containers with newest container images - name: Restart containers with newest container images
ansible.builtin.command: ansible.builtin.command:
cmd: docker compose up -d cmd: docker compose up -d
chdir: "{{ webadmin.home }}/{{ item }}" chdir: "{{ webserver_admin.home }}/{{ item }}"
loop: loop:
- services - services
register: webserver_docker_restart
changed_when: webserver_docker_restart.rc == 0

View File

@@ -1,2 +1,2 @@
webadmin: webserver_admin:
home: /home/webadmin home: /home/webadmin