Hyperling c59e706c17
Add initial HUGO support, FreeBSD 13 support, and script for Ansible to hit dev branch. (#4)
* Create HUGO file.

* Add HUGO.

* Add script for running system against development branch.

* Add newline to end of file.

* Comment unused blocks.

* Add path of site that HUGO should host.

* Newlines, comments, and HUGO path. (#2) (#3)

* Create HUGO file.

* Add HUGO.

* Add script for running system against development branch.

* Add newline to end of file.

* Comment unused blocks.

* Add path of site that HUGO should host.

* FreeBSD is complaining about certbot not having dict object stdout. This whole playbook is supposed to be skipped though, lol.

* FreeBSD 13 is still mad. Ansible 2.11.2, jinja 2.11.2 (same version number??), Python 3.8.10.

* Fix root group to be existing variable. FreeBSD uses wheel.

* Allow choosing Github branch dynamically.

* `branch` needs to be at General level. Testing if this works...

* Change other `localhost` to `everything`.

* Update FreeBSD status.

* Goodbye, Code-OSS on Linux!

* Delete a terrible file.

* Remove excess tag.

* "Fix" SSHFS for FreeBSD.

* Variablize FreeBSD's loading of fusefs.

* Variablize /etc/rc.conf. Enable FuseFS more properly.

* Add beginning ticks.

* Add missing playbook.

* Enable FreeBSD mount job.

* Rearrange items to be more consistent with comment.

* It seems  FreeBSD removed the `gnome3` metapackage. Use `gnome3-lite` instead. Also add Telegram.

* Python is to 3.8 now.

* Expand on FreeBSD work.

* Expand on FreeBSD work.

* Add placeholders for Gitlab.

* Add parameter for Gitlab install.

* Add Gitlab playbook.

* Ensure FreeBSD uses the correct Python install.

* Add newline.

* Fix NFS for FreeBSD workstations.

* Remove unnecessary line, restricted install to Linux in playbook.

* Fix mount options for FreeBSD.

* Fix mount number, as well as system-specific facts.

* Add placeholders for remote viewing.

* Add RDP for FreeBSD.

* Omg! It works! Add setting enforcement.

* Always remove OSS.

* Remove hosts from explicit dev testing.
2021-07-19 07:07:03 -05:00

77 lines
2.7 KiB
YAML

---
# Define file, folder, and other facts per OS.
- name: General | Facts | System | Linux
set_fact:
rc_conf: /dev/null
lynis_install_dir: /usr/local/lynis
sudoers_install_dir: /etc/sudoers.d/
when: ansible_system == "Linux"
- name: General | Facts | System | FreeBSD
set_fact:
rc_conf: /etc/rc.conf
lynis_install_dir: /usr/local/lynis
sudoers_install_dir: /usr/local/etc/sudoers.d/
when: ansible_system == "FreeBSD"
- name: General | Facts | System | 1337 Drive
set_fact:
leet_ssh: 'ling@leet'
leet_drive: /mnt/leet
- name: General | Facts | System | 1337 Drive Mounted?
stat:
path: "{{ leet_drive }}/Temp/ansible"
register: leet_drive_details
- name: General | Facts | System | Report Location = 1337
set_fact:
report_location: "{{ leet_drive }}/Temp/ansible"
when: leet_drive_details.stat.exists
- name: General | Facts | System | Report Location = /root
set_fact:
report_location: "/root"
report_scp_location: "Temp/ansible"
when: not leet_drive_details.stat.exists
- name: General | Facts | System | Report File Names
set_fact:
heartbeat_report_name: "{{ ansible_hostname }}.txt"
ansible_pull_report_name: "{{ ansible_hostname }}_last_pull_times.txt"
lynis_report_name: "{{ ansible_hostname }}_lynis.txt"
nmap_report_name: "{{ ansible_hostname }}_nmap.txt"
- name: General | Facts | System | Report Locations (SSHFS)
set_fact:
heartbeat_report: "{{ report_location }}/{{ heartbeat_report_name }}"
ansible_pull_report: "{{ report_location }}/pull/{{ ansible_pull_report_name }}"
lynis_report: "{{ report_location }}/lynis/{{ lynis_report_name }}"
nmap_report: "{{ report_location }}/nmap/{{ nmap_report_name }}"
when: leet_drive_details.stat.exists
- name: General | Facts | System | Report Locations (Local)
set_fact:
heartbeat_report: "{{ report_location }}/{{ heartbeat_report_name }}"
ansible_pull_report: "{{ report_location }}/{{ ansible_pull_report_name }}"
lynis_report: "{{ report_location }}/{{ lynis_report_name }}"
nmap_report: "{{ report_location }}/{{ nmap_report_name }}"
when: not leet_drive_details.stat.exists
- name: General | Facts | System | Report Destinations (SCP)
set_fact:
heartbeat_report_scp: "{{ leet_ssh }}:{{ report_scp_location }}/{{ heartbeat_report_name }}"
ansible_pull_report_scp: "{{ leet_ssh }}:{{ report_scp_location }}/pull/{{ ansible_pull_report_name }}"
lynis_report_scp: "{{ leet_ssh }}:{{ report_scp_location }}/lynis/{{ lynis_report_name }}"
nmap_report_scp: "{{ leet_ssh }}:{{ report_scp_location }}/nmap/{{ nmap_report_name }}"
when: not leet_drive_details.stat.exists
- name: General | Facts | System | Ansible Branch
set_fact:
branch: main
when: branch is not defined