Add psutil dependency. Fix names in fact files.
This commit is contained in:
parent
cd1cdef514
commit
0ed6685b30
@ -1,10 +1,10 @@
|
|||||||
---
|
---
|
||||||
# Facts that must be gathered after running tasks.
|
# Facts that must be gathered after running tasks.
|
||||||
|
|
||||||
- name: Facts | General | Gather | Locate bash
|
- name: General | Facts | Gather | Locate bash
|
||||||
shell: which bash
|
shell: which bash
|
||||||
register: bash_exec
|
register: bash_exec
|
||||||
|
|
||||||
- name: Facts | General | Gather | Locate ansible-pull
|
- name: General | Facts | Gather | Locate ansible-pull
|
||||||
shell: which ansible-pull
|
shell: which ansible-pull
|
||||||
register: ansible_pull_exec
|
register: ansible_pull_exec
|
||||||
|
@ -2,14 +2,14 @@
|
|||||||
# Define program names for package builtin.
|
# Define program names for package builtin.
|
||||||
# This file is for ALL systems and should not include UI components.
|
# This file is for ALL systems and should not include UI components.
|
||||||
|
|
||||||
- name: Facts | General | Package | apt
|
- name: General | Facts | Package | apt
|
||||||
set_fact:
|
set_fact:
|
||||||
sshfs: sshfs
|
sshfs: sshfs
|
||||||
locate: locate
|
locate: locate
|
||||||
when: ansible_pkg_mgr == "apt"
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | Package | FreeBSD
|
- name: General | Facts | Package | FreeBSD
|
||||||
set_fact:
|
set_fact:
|
||||||
sshfs: fusefs-sshfs
|
sshfs: fusefs-sshfs
|
||||||
locate: htop # Placeholder to prevent errors. locate builtin FreeBSD.
|
locate: htop # Placeholder to prevent errors. locate builtin FreeBSD.
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
---
|
---
|
||||||
# Define program names for service builtin.
|
# Define program names for service builtin.
|
||||||
|
|
||||||
- name: Facts | General | Service | Linux
|
- name: General | Facts | Service | Linux
|
||||||
set_fact:
|
set_fact:
|
||||||
cups: cups
|
cups: cups
|
||||||
cups_pattern: cupsd
|
cups_pattern: cupsd
|
||||||
@ -10,7 +10,7 @@
|
|||||||
when: ansible_system == "Linux"
|
when: ansible_system == "Linux"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | Service | FreeBSD
|
- name: General | Facts | Service | FreeBSD
|
||||||
set_fact:
|
set_fact:
|
||||||
cups: cups
|
cups: cups
|
||||||
cups_pattern: cupsd
|
cups_pattern: cupsd
|
||||||
|
@ -1,49 +1,49 @@
|
|||||||
---
|
---
|
||||||
# Define file, folder, and other facts per OS.
|
# Define file, folder, and other facts per OS.
|
||||||
|
|
||||||
- name: Facts | General | System | Pop OS
|
- name: General | Facts | System | Pop OS
|
||||||
set_fact:
|
set_fact:
|
||||||
lynis_install_dir: /usr/local/lynis
|
lynis_install_dir: /usr/local/lynis
|
||||||
sudoers_install_dir: /etc/sudoers.d/
|
sudoers_install_dir: /etc/sudoers.d/
|
||||||
when: ansible_distribution == "Pop!_OS"
|
when: ansible_distribution == "Pop!_OS"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | System | Debian and Ubuntu
|
- name: General | Facts | System | Debian and Ubuntu
|
||||||
set_fact:
|
set_fact:
|
||||||
lynis_install_dir: /usr/local/lynis
|
lynis_install_dir: /usr/local/lynis
|
||||||
sudoers_install_dir: /etc/sudoers.d/
|
sudoers_install_dir: /etc/sudoers.d/
|
||||||
when: ansible_distribution in ("Debian","Ubuntu")
|
when: ansible_distribution in ("Debian","Ubuntu")
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | System | FreeBSD
|
- name: General | Facts | System | FreeBSD
|
||||||
set_fact:
|
set_fact:
|
||||||
lynis_install_dir: /usr/local/lynis
|
lynis_install_dir: /usr/local/lynis
|
||||||
sudoers_install_dir: /usr/local/etc/sudoers.d/
|
sudoers_install_dir: /usr/local/etc/sudoers.d/
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | System | 1337
|
- name: General | Facts | System | 1337
|
||||||
set_fact:
|
set_fact:
|
||||||
leet_drive: /mnt/leet
|
leet_drive: /mnt/leet
|
||||||
|
|
||||||
- name: Facts | General | System | 1337 Mounted?
|
- name: General | Facts | System | 1337 Mounted?
|
||||||
stat:
|
stat:
|
||||||
path: "{{ leet_drive }}/Temp/ansible"
|
path: "{{ leet_drive }}/Temp/ansible"
|
||||||
register: leet_drive_details
|
register: leet_drive_details
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | System | Report Location = 1337
|
- name: General | Facts | System | Report Location = 1337
|
||||||
set_fact:
|
set_fact:
|
||||||
report_location: "{{ leet_drive }}/Temp/ansible"
|
report_location: "{{ leet_drive }}/Temp/ansible"
|
||||||
when: leet_drive_details.stat.exists
|
when: leet_drive_details.stat.exists
|
||||||
|
|
||||||
- name: Facts | General | System | Report Location = /root
|
- name: General | Facts | System | Report Location = /root
|
||||||
set_fact:
|
set_fact:
|
||||||
report_location: "/root"
|
report_location: "/root"
|
||||||
report_scp_location: "Temp/ansible/"
|
report_scp_location: "Temp/ansible/"
|
||||||
when: not leet_drive_details.stat.exists
|
when: not leet_drive_details.stat.exists
|
||||||
|
|
||||||
- name: Facts | General | System | Reports
|
- name: General | Facts | System | Reports
|
||||||
set_fact:
|
set_fact:
|
||||||
heartbeat_report: "{{ report_location }}/{{ ansible_hostname }}.txt"
|
heartbeat_report: "{{ report_location }}/{{ ansible_hostname }}.txt"
|
||||||
lynis_report: "{{ report_location }}/{{ ansible_hostname }}_lynis.txt"
|
lynis_report: "{{ report_location }}/{{ ansible_hostname }}_lynis.txt"
|
||||||
|
@ -1,13 +1,13 @@
|
|||||||
---
|
---
|
||||||
# Define users and groups per OS type.
|
# Define users and groups per OS type.
|
||||||
|
|
||||||
- name: Facts | General | User | Linux
|
- name: General | Facts | User | Linux
|
||||||
set_fact:
|
set_fact:
|
||||||
root_group: root
|
root_group: root
|
||||||
when: ansible_system == "Linux"
|
when: ansible_system == "Linux"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | General | User | FreeBSD
|
- name: General | Facts | User | FreeBSD
|
||||||
set_fact:
|
set_fact:
|
||||||
root_group: wheel
|
root_group: wheel
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
@ -10,22 +10,34 @@
|
|||||||
gnome_tweaks: gnome-tweaks
|
gnome_tweaks: gnome-tweaks
|
||||||
dconf_editor: dconf-editor
|
dconf_editor: dconf-editor
|
||||||
|
|
||||||
- name: Facts | Workstation | Package | Pop_OS! and Ubuntu
|
|
||||||
|
- name: Facts | Workstation | Package | Pop_OS!
|
||||||
set_fact:
|
set_fact:
|
||||||
flatpak_distro: true
|
flatpak_distro: true
|
||||||
firefox_esr: firefox
|
firefox_esr: firefox
|
||||||
when: ansible_distribution in ("Pop!_OS", "Ubuntu")
|
psutil: python3-psutil
|
||||||
|
when: ansible_distribution == "Pop!_OS"
|
||||||
|
|
||||||
|
|
||||||
|
- name: Facts | Workstation | Package | Ubuntu
|
||||||
|
set_fact:
|
||||||
|
flatpak_distro: true
|
||||||
|
firefox_esr: firefox
|
||||||
|
psutil: python3-psutil
|
||||||
|
when: ansible_distribution == "Ubuntu"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | Workstation | Package | Debian
|
- name: Facts | Workstation | Package | Debian
|
||||||
set_fact:
|
set_fact:
|
||||||
flatpak_distro: true
|
flatpak_distro: true
|
||||||
firefox_esr: firefox-esr
|
firefox_esr: firefox-esr
|
||||||
when: ansible_distribution in ("Debian")
|
psutil: python3-psutil
|
||||||
|
when: ansible_distribution == "Debian"
|
||||||
|
|
||||||
|
|
||||||
- name: Facts | Workstation | Package | FreeBSD
|
- name: Facts | Workstation | Package | FreeBSD
|
||||||
set_fact:
|
set_fact:
|
||||||
flatpak_distro: false
|
flatpak_distro: false
|
||||||
firefox_esr: firefox-esr
|
firefox_esr: firefox-esr
|
||||||
|
psutil: py37-psutil
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
@ -1,7 +1,7 @@
|
|||||||
---
|
---
|
||||||
# Cron jobs specific to FreeBSD
|
# Cron jobs specific to FreeBSD
|
||||||
|
|
||||||
- name: FreeBSD | Cron | Ansible | Enable SSHFS Job
|
- name: General | Cron | Ansible | FreeBSD | Enable SSHFS Job
|
||||||
cron:
|
cron:
|
||||||
user: ansible
|
user: ansible
|
||||||
name: "1337 SSHFS"
|
name: "1337 SSHFS"
|
||||||
@ -10,7 +10,7 @@
|
|||||||
state: present
|
state: present
|
||||||
disabled: no
|
disabled: no
|
||||||
|
|
||||||
- name: FreeBSD | Cron | Ansible | Enable Security Update
|
- name: General | Cron | Ansible | FreeBSD | Enable Security Update
|
||||||
cron:
|
cron:
|
||||||
user: ansible
|
user: ansible
|
||||||
name: "Security Update"
|
name: "Security Update"
|
||||||
|
@ -2,11 +2,12 @@
|
|||||||
# GNOME settings, extensions, and setup.
|
# GNOME settings, extensions, and setup.
|
||||||
|
|
||||||
# Make sure Gnome-Tweaks is installed
|
# Make sure Gnome-Tweaks is installed
|
||||||
- name: Workstation | Account Management | GNOME | Install Settings Editors
|
- name: Workstation | Account Management | GNOME | Install Dependencies
|
||||||
package:
|
package:
|
||||||
name:
|
name:
|
||||||
- "{{ gnome_tweaks }}"
|
- "{{ gnome_tweaks }}"
|
||||||
- "{{ dconf_editor }}"
|
- "{{ dconf_editor }}"
|
||||||
|
- "{{ psutil }}"
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
|
|
||||||
@ -26,7 +27,7 @@
|
|||||||
- name: Workstation | Account Management | GNOME | Favorites (FreeBSD)
|
- name: Workstation | Account Management | GNOME | Favorites (FreeBSD)
|
||||||
dconf:
|
dconf:
|
||||||
key: /org/gnome/shell/favorite-apps
|
key: /org/gnome/shell/favorite-apps
|
||||||
value: "['org.gnome.Terminal.desktop', 'org.gnome.Nautilus.desktop', 'firefox.desktop', 'org.mozilla.Thunderbird.desktop', 'code.desktop']"
|
value: "['org.gnome.Terminal.desktop', 'org.gnome.Nautilus.desktop', 'firefox.desktop', 'org.mozilla.Thunderbird.desktop', 'code-oss.desktop']"
|
||||||
state: present
|
state: present
|
||||||
become_user: ling
|
become_user: ling
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user