diff --git a/.ansible-lint b/.ansible-lint index 101357cb..41f5fdfe 100644 --- a/.ansible-lint +++ b/.ansible-lint @@ -3,6 +3,8 @@ skip_list: - yaml[line-length] - name[casing] - yaml[comments] + - name[play] + - var-naming[no-role-prefix] quiet: true exclude_paths: - .cache/ # implicit unless exclude_paths is defined in config @@ -22,3 +24,5 @@ exclude_paths: - roles/robertdebock.bootstrap - roles/PyratLabs.k3s - .gitlab-ci.yml + - friedhof/ + - playbooks/on-off diff --git a/.ansible-lint-ignore b/.ansible-lint-ignore deleted file mode 100644 index 2b18e9e6..00000000 --- a/.ansible-lint-ignore +++ /dev/null @@ -1,3 +0,0 @@ -# This file contains ignores rule violations for ansible-lint -playbooks/on-off/remove_old_ssh_key.yml name[play] -playbooks/on-off/remove_old_ssh_key.yml yaml[truthy] diff --git a/.drone.yml b/.drone.yml index dab97558..1f0140ce 100644 --- a/.drone.yml +++ b/.drone.yml @@ -23,7 +23,7 @@ steps: commands: - ansible-lint --version - echo $ANSIBLE_VAULT_PASSWORD > ./vault-pass.yml - - ansible-lint + - ansible-lint --force-color --format pep8 when: event: exclude: @@ -31,17 +31,3 @@ steps: environment: ANSIBLE_VAULT_PASSWORD: from_secret: vault-pass - ---- -kind: pipeline -type: docker -name: yaml-lint -steps: - - name: yamllint - image: cytopia/yamllint:1 - commands: - - /usr/bin/yamllint -f colored . - when: - event: - exclude: - - tag diff --git a/.yamllint b/.yamllint deleted file mode 100644 index 30d8fe83..00000000 --- a/.yamllint +++ /dev/null @@ -1,3 +0,0 @@ -ignore: - - ./roles/pandemonium1986.ansible-role-k9s - - ./roles/robertdebock.bootstrap diff --git a/README.md b/README.md index b630fb59..195fa744 100644 --- a/README.md +++ b/README.md @@ -1,4 +1 @@ # ansible_heimserver - -## example-cli -`ansible-playbook playbooks/base/0_master.yml -i inventory --key-file id_rsa_ansible_user --vault-password-file vault-pass.yml --limit jenkins-test.grote.lan` diff --git a/collections/community/general/plugins/modules/btrfs_info.py b/collections/community/general/plugins/modules/btrfs_info.py index c367b9ed..ef4be555 100644 --- a/collections/community/general/plugins/modules/btrfs_info.py +++ b/collections/community/general/plugins/modules/btrfs_info.py @@ -50,8 +50,8 @@ filesystems: description: A list of devices assigned to the filesystem. type: list sample: - - /dev/sda1 - - /dev/sdb1 + - /dev/sda1 + - /dev/sdb1 default_subvolume: description: The id of the filesystem's default subvolume. type: int diff --git a/collections/community/general/plugins/modules/btrfs_subvolume.py b/collections/community/general/plugins/modules/btrfs_subvolume.py index 864bb65a..5bfcab5c 100644 --- a/collections/community/general/plugins/modules/btrfs_subvolume.py +++ b/collections/community/general/plugins/modules/btrfs_subvolume.py @@ -162,8 +162,8 @@ filesystem: returned: success type: list sample: - - /dev/sda1 - - /dev/sdb1 + - /dev/sda1 + - /dev/sdb1 default_subvolume: description: The ID of the filesystem's default subvolume. returned: success and if filesystem is mounted diff --git a/docker-compose/homer/assets/config.yml b/docker-compose/homer/assets/config.yml index c2d04007..99200dbd 100644 --- a/docker-compose/homer/assets/config.yml +++ b/docker-compose/homer/assets/config.yml @@ -15,11 +15,6 @@ defaults: stylesheet: - 'assets/catppuccin-frappe.css' - - - - - links: - name: "Homepage" icon: "fas fa-heartbeat" diff --git a/docker-compose/httpd/docker-compose.yml.j2 b/docker-compose/httpd/docker-compose.yml.j2 index 43c09208..63bfc9d4 100644 --- a/docker-compose/httpd/docker-compose.yml.j2 +++ b/docker-compose/httpd/docker-compose.yml.j2 @@ -6,7 +6,7 @@ services: restart: always volumes: - uploads:/usr/local/apache2/htdocs/ - - "${PWD}/httpd.conf:/usr/local/apache2/conf/httpd.conf:ro" + - "/docker/httpd/httpd.conf:/usr/local/apache2/conf/httpd.conf:ro" ports: - 3344:80 labels: diff --git a/docker-compose/traefik/file-provider.yml b/docker-compose/traefik/file-provider.yml index 760f4525..7defcfb3 100644 --- a/docker-compose/traefik/file-provider.yml +++ b/docker-compose/traefik/file-provider.yml @@ -21,8 +21,8 @@ http: service_dokuwiki: loadBalancer: servers: - - url: "http://dokuwiki2.grote.lan/" + - url: "http://dokuwiki2.grote.lan/" service_gitea: loadBalancer: servers: - - url: "http://gitea.grote.lan:3000/" + - url: "http://gitea.grote.lan:3000/" diff --git a/roles/_mgrote.musterrolle/LICENSE b/friedhof/mgrote_acng/LICENSE similarity index 100% rename from roles/_mgrote.musterrolle/LICENSE rename to friedhof/mgrote_acng/LICENSE diff --git a/roles/_mgrote.musterrolle/README.md b/friedhof/mgrote_acng/README.md similarity index 100% rename from roles/_mgrote.musterrolle/README.md rename to friedhof/mgrote_acng/README.md diff --git a/friedhof/mgrote_acng/defaults/main.yml b/friedhof/mgrote_acng/defaults/main.yml new file mode 100644 index 00000000..34709099 --- /dev/null +++ b/friedhof/mgrote_acng/defaults/main.yml @@ -0,0 +1,6 @@ +--- +acng_exthreshold: "60" +acng_server_port: "9999" +acng_security_conf_path: "/etc/apt-cacher-ng/security.conf" +acng_server_auth_user: acngadmin +acng_server_auth_pass: klauspeter diff --git a/friedhof/mgrote_acng/handlers/main.yml b/friedhof/mgrote_acng/handlers/main.yml new file mode 100644 index 00000000..cec11168 --- /dev/null +++ b/friedhof/mgrote_acng/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: acng_starten_aktivieren + become: true + ansible.builtin.systemd: + name: apt-cacher-ng + enabled: true + state: restarted diff --git a/roles/_mgrote.musterrolle_systemd/LICENSE b/friedhof/mgrote_acng/mgrote.acng/LICENSE similarity index 100% rename from roles/_mgrote.musterrolle_systemd/LICENSE rename to friedhof/mgrote_acng/mgrote.acng/LICENSE diff --git a/roles/mgrote.acng/README.md b/friedhof/mgrote_acng/mgrote.acng/README.md similarity index 100% rename from roles/mgrote.acng/README.md rename to friedhof/mgrote_acng/mgrote.acng/README.md diff --git a/friedhof/mgrote_acng/mgrote.acng/defaults/main.yml b/friedhof/mgrote_acng/mgrote.acng/defaults/main.yml new file mode 100644 index 00000000..34709099 --- /dev/null +++ b/friedhof/mgrote_acng/mgrote.acng/defaults/main.yml @@ -0,0 +1,6 @@ +--- +acng_exthreshold: "60" +acng_server_port: "9999" +acng_security_conf_path: "/etc/apt-cacher-ng/security.conf" +acng_server_auth_user: acngadmin +acng_server_auth_pass: klauspeter diff --git a/friedhof/mgrote_acng/mgrote.acng/handlers/main.yml b/friedhof/mgrote_acng/mgrote.acng/handlers/main.yml new file mode 100644 index 00000000..cec11168 --- /dev/null +++ b/friedhof/mgrote_acng/mgrote.acng/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: acng_starten_aktivieren + become: true + ansible.builtin.systemd: + name: apt-cacher-ng + enabled: true + state: restarted diff --git a/friedhof/mgrote_acng/mgrote.acng/tasks/main.yml b/friedhof/mgrote_acng/mgrote.acng/tasks/main.yml new file mode 100644 index 00000000..89a4cbb6 --- /dev/null +++ b/friedhof/mgrote_acng/mgrote.acng/tasks/main.yml @@ -0,0 +1,42 @@ +--- +- name: ensure directories exists + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + loop: + - /etc/apt-cacher-ng + - /var/cache/apt-cacher-ng + +- name: ensure directories have the right permissions + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: apt-cacher-ng + group: apt-cacher-ng + loop: + - /var/cache/apt-cacher-ng + +- name: templating acng.conf + become: true + ansible.builtin.template: + src: "acng.conf" + dest: "/etc/apt-cacher-ng/acng.conf" + mode: "0664" + notify: acng_starten_aktivieren + +- name: install apt-cacher-ng packages + become: true + ansible.builtin.package: + name: apt-cacher-ng + state: present + +- name: templating security.conf + become: true + ansible.builtin.template: + src: "security.conf" + dest: "{{ acng_security_conf_path }}" + mode: "0640" + notify: acng_starten_aktivieren + no_log: true diff --git a/roles/_mgrote.musterrolle/templates/acng.conf b/friedhof/mgrote_acng/mgrote.acng/templates/acng.conf similarity index 100% rename from roles/_mgrote.musterrolle/templates/acng.conf rename to friedhof/mgrote_acng/mgrote.acng/templates/acng.conf diff --git a/roles/_mgrote.musterrolle/templates/security.conf b/friedhof/mgrote_acng/mgrote.acng/templates/security.conf similarity index 100% rename from roles/_mgrote.musterrolle/templates/security.conf rename to friedhof/mgrote_acng/mgrote.acng/templates/security.conf diff --git a/friedhof/mgrote_acng/tasks/main.yml b/friedhof/mgrote_acng/tasks/main.yml new file mode 100644 index 00000000..f85a6a67 --- /dev/null +++ b/friedhof/mgrote_acng/tasks/main.yml @@ -0,0 +1,35 @@ +--- +- name: ensure directories exists + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: apt-cacher-ng + group: apt-cacher-ng + mode: "0644" + loop: + - /etc/apt-cacher-ng + - /var/cache/apt-cacher-ng + +- name: templating acng.conf + become: true + ansible.builtin.template: + src: "acng.conf" + dest: "/etc/apt-cacher-ng/acng.conf" + mode: "0644" + notify: acng_starten_aktivieren + +- name: install apt-cacher-ng packages + become: true + ansible.builtin.package: + name: apt-cacher-ng + state: present + +- name: templating security.conf + become: true + ansible.builtin.template: + src: "security.conf" + dest: "{{ acng_security_conf_path }}" + mode: "0640" + notify: acng_starten_aktivieren + no_log: true diff --git a/roles/mgrote.acng/templates/acng.conf b/friedhof/mgrote_acng/templates/acng.conf similarity index 100% rename from roles/mgrote.acng/templates/acng.conf rename to friedhof/mgrote_acng/templates/acng.conf diff --git a/roles/mgrote.acng/templates/security.conf b/friedhof/mgrote_acng/templates/security.conf similarity index 100% rename from roles/mgrote.acng/templates/security.conf rename to friedhof/mgrote_acng/templates/security.conf diff --git a/roles/mgrote.acng/LICENSE b/friedhof/mgrote_alacritty/LICENSE similarity index 100% rename from roles/mgrote.acng/LICENSE rename to friedhof/mgrote_alacritty/LICENSE diff --git a/roles/mgrote.alacritty/README.md b/friedhof/mgrote_alacritty/README.md similarity index 100% rename from roles/mgrote.alacritty/README.md rename to friedhof/mgrote_alacritty/README.md diff --git a/friedhof/mgrote_alacritty/defaults/main.yml b/friedhof/mgrote_alacritty/defaults/main.yml new file mode 100644 index 00000000..ca4228b2 --- /dev/null +++ b/friedhof/mgrote_alacritty/defaults/main.yml @@ -0,0 +1,2 @@ +--- +alacritty_url: http://docker10.grote.lan:3344/alacritty-latest.tar.gz diff --git a/roles/mgrote.alacritty/LICENSE b/friedhof/mgrote_alacritty/mgrote.alacritty/LICENSE similarity index 100% rename from roles/mgrote.alacritty/LICENSE rename to friedhof/mgrote_alacritty/mgrote.alacritty/LICENSE diff --git a/friedhof/mgrote_alacritty/mgrote.alacritty/README.md b/friedhof/mgrote_alacritty/mgrote.alacritty/README.md new file mode 100644 index 00000000..b2842322 --- /dev/null +++ b/friedhof/mgrote_alacritty/mgrote.alacritty/README.md @@ -0,0 +1,8 @@ +## mgrote.alacritty +### Beschreibung +Installiert alacritty. + + +### getestet auf +- [x] Ubuntu (>=18.04) +- [x] Linux Mint diff --git a/friedhof/mgrote_alacritty/mgrote.alacritty/defaults/main.yml b/friedhof/mgrote_alacritty/mgrote.alacritty/defaults/main.yml new file mode 100644 index 00000000..ca4228b2 --- /dev/null +++ b/friedhof/mgrote_alacritty/mgrote.alacritty/defaults/main.yml @@ -0,0 +1,2 @@ +--- +alacritty_url: http://docker10.grote.lan:3344/alacritty-latest.tar.gz diff --git a/friedhof/mgrote_alacritty/mgrote.alacritty/tasks/main.yml b/friedhof/mgrote_alacritty/mgrote.alacritty/tasks/main.yml new file mode 100644 index 00000000..a4998d7f --- /dev/null +++ b/friedhof/mgrote_alacritty/mgrote.alacritty/tasks/main.yml @@ -0,0 +1,11 @@ +--- +- name: download binary + ansible.builtin.unarchive: + src: "{{ alacritty_url }}" + dest: /usr/local/bin + remote_src: true + +- name: set permissions + ansible.builtin.file: + path: /usr/local/bin/alacritty + mode: '0755' diff --git a/friedhof/mgrote_alacritty/tasks/main.yml b/friedhof/mgrote_alacritty/tasks/main.yml new file mode 100644 index 00000000..a4998d7f --- /dev/null +++ b/friedhof/mgrote_alacritty/tasks/main.yml @@ -0,0 +1,11 @@ +--- +- name: download binary + ansible.builtin.unarchive: + src: "{{ alacritty_url }}" + dest: /usr/local/bin + remote_src: true + +- name: set permissions + ansible.builtin.file: + path: /usr/local/bin/alacritty + mode: '0755' diff --git a/roles/mgrote.apcupsd/LICENSE b/friedhof/mgrote_apcupsd/LICENSE similarity index 100% rename from roles/mgrote.apcupsd/LICENSE rename to friedhof/mgrote_apcupsd/LICENSE diff --git a/roles/mgrote.apcupsd/README.md b/friedhof/mgrote_apcupsd/README.md similarity index 100% rename from roles/mgrote.apcupsd/README.md rename to friedhof/mgrote_apcupsd/README.md diff --git a/friedhof/mgrote_apcupsd/defaults/main.yml b/friedhof/mgrote_apcupsd/defaults/main.yml new file mode 100644 index 00000000..a86afff6 --- /dev/null +++ b/friedhof/mgrote_apcupsd/defaults/main.yml @@ -0,0 +1,40 @@ +--- +## Values: http://www.apcupsd.org/manual/manual.html + +## Master +# Wenn "true" ist dieser Host master. +apcupsd_nis_master: true + +# Interface auf dem der "Master" erreichbar ist. +apcupsd_nis_master_listen_ip: 0.0.0.0 + +# Post auf dem der "Master" erreichbar ist. +apcupsd_nis_master_listen_port: 3551 + +# Name der USV +apcupsd_ups_name: APC-BX950U-GR + +## Slave +# Zeitspanne zwischen dem pollen +apcupsd_slave_polltime: 10 #in Sekunden + + +## Master & Slave +# FQDN oder IP des "master" +apcupsd_nis_master_hostname: pve2.grote.lan + +# Zeitspanne in Sekunden, ab der der Systemdienst einen Stromausfall annimmt. Nuetzlich, um sehr kurze Ausfaelle ignorieren zu koennen. +apcupsd_master_onbatterydelay: 10 +apcupsd_slave_onbatterydelay: 10 + +# Durch die USV gemeldete Restkapazitaet in Prozent, ab der der Rechner heruntergefahren wird. +apcupsd_master_batterylevel_for_shutdown: 50 +apcupsd_slave_batterylevel_for_shutdown: 60 + +# apcupsd will shutdown the system during a power failure when the remaining runtime on batteries as internally calculated by the UPS falls below the specified minutes. Jeweils Master und Slave. +apcupsd_master_minutes_for_shutdown: 10 +apcupsd_slave_minutes_for_shutdown: 11 + +# Specifies when apcupsd should create the NOLOGON file to prevent users from logging on to the system. Jeweils Master und Slave. +apcupsd_master_nologon_when_active: always +apcupsd_slave_nologon_when_active: always diff --git a/friedhof/mgrote_apcupsd/handlers/main.yml b/friedhof/mgrote_apcupsd/handlers/main.yml new file mode 100644 index 00000000..5e55361d --- /dev/null +++ b/friedhof/mgrote_apcupsd/handlers/main.yml @@ -0,0 +1,12 @@ +--- +- name: restart_apcupsd #wird aufgerufen wenn apcupsd.conf_kopieren nach aenderungen den status "changed hat" + become: true + ansible.builtin.systemd: + name: apcupsd + state: restarted + enabled: true + +- name: apc_access_mail + ansible.builtin.shell: + cmd: set -o pipefail && /usr/sbin/apcaccess | mail -s "{{ ansible_hostname }}" {{ empfaenger_mail }} + executable: /bin/bash diff --git a/friedhof/mgrote_apcupsd/meta/main.yml b/friedhof/mgrote_apcupsd/meta/main.yml new file mode 100644 index 00000000..ba59fed4 --- /dev/null +++ b/friedhof/mgrote_apcupsd/meta/main.yml @@ -0,0 +1,14 @@ +--- +dependencies: + - role: mgrote_postfix +galaxy_info: + author: mgrote + description: installs apcupsd + min_ansible_version: 2.0 + license: GPLv3 + platforms: + - name: Proxmox + versions: + - all + galaxy_tags: + - system diff --git a/roles/mgrote.cv4pve-autosnap/LICENSE b/friedhof/mgrote_apcupsd/mgrote.apcupsd/LICENSE similarity index 100% rename from roles/mgrote.cv4pve-autosnap/LICENSE rename to friedhof/mgrote_apcupsd/mgrote.apcupsd/LICENSE diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/README.md b/friedhof/mgrote_apcupsd/mgrote.apcupsd/README.md new file mode 100644 index 00000000..04fa1101 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/README.md @@ -0,0 +1,20 @@ +## mgrote.apcupsd + +### Beschreibung +* Installiert apcupsd. +* Auf einem PC als "Master", hier ist die USV per USB angeschlossen. +* Auf allen anderen PCs als "Slave", diese OCs pollen alle Sekunden den Master. +* Benoetigt mgrote.postfix. +* Getestet mit: APC-BX950U-GR + +### Links + * http://www.apcupsd.org/manual/#checking-your-configuration-file + * https://linux.die.net/man/5/apcupsd.conf + + +### getestet auf +- [x] ProxMox 6.1 +- [x] ProxMox 7 + +### Variablen + Defaults +- siehe [defaults/main.yml](./defaults/main.yml) diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/defaults/main.yml b/friedhof/mgrote_apcupsd/mgrote.apcupsd/defaults/main.yml new file mode 100644 index 00000000..a86afff6 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/defaults/main.yml @@ -0,0 +1,40 @@ +--- +## Values: http://www.apcupsd.org/manual/manual.html + +## Master +# Wenn "true" ist dieser Host master. +apcupsd_nis_master: true + +# Interface auf dem der "Master" erreichbar ist. +apcupsd_nis_master_listen_ip: 0.0.0.0 + +# Post auf dem der "Master" erreichbar ist. +apcupsd_nis_master_listen_port: 3551 + +# Name der USV +apcupsd_ups_name: APC-BX950U-GR + +## Slave +# Zeitspanne zwischen dem pollen +apcupsd_slave_polltime: 10 #in Sekunden + + +## Master & Slave +# FQDN oder IP des "master" +apcupsd_nis_master_hostname: pve2.grote.lan + +# Zeitspanne in Sekunden, ab der der Systemdienst einen Stromausfall annimmt. Nuetzlich, um sehr kurze Ausfaelle ignorieren zu koennen. +apcupsd_master_onbatterydelay: 10 +apcupsd_slave_onbatterydelay: 10 + +# Durch die USV gemeldete Restkapazitaet in Prozent, ab der der Rechner heruntergefahren wird. +apcupsd_master_batterylevel_for_shutdown: 50 +apcupsd_slave_batterylevel_for_shutdown: 60 + +# apcupsd will shutdown the system during a power failure when the remaining runtime on batteries as internally calculated by the UPS falls below the specified minutes. Jeweils Master und Slave. +apcupsd_master_minutes_for_shutdown: 10 +apcupsd_slave_minutes_for_shutdown: 11 + +# Specifies when apcupsd should create the NOLOGON file to prevent users from logging on to the system. Jeweils Master und Slave. +apcupsd_master_nologon_when_active: always +apcupsd_slave_nologon_when_active: always diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/handlers/main.yml b/friedhof/mgrote_apcupsd/mgrote.apcupsd/handlers/main.yml new file mode 100644 index 00000000..da610592 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/handlers/main.yml @@ -0,0 +1,10 @@ +--- +- name: restart_apcupsd #wird aufgerufen wenn apcupsd.conf_kopieren nach aenderungen den status "changed hat" + become: true + ansible.builtin.systemd: + name: apcupsd + state: restarted + enabled: true + +- name: apc_access_mail + ansible.builtin.shell: /usr/sbin/apcaccess | mail -s "{{ ansible_hostname }}" {{ empfaenger_mail }} diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/meta/main.yml b/friedhof/mgrote_apcupsd/mgrote.apcupsd/meta/main.yml new file mode 100644 index 00000000..ba59fed4 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/meta/main.yml @@ -0,0 +1,14 @@ +--- +dependencies: + - role: mgrote_postfix +galaxy_info: + author: mgrote + description: installs apcupsd + min_ansible_version: 2.0 + license: GPLv3 + platforms: + - name: Proxmox + versions: + - all + galaxy_tags: + - system diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/main.yml b/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/main.yml new file mode 100644 index 00000000..bee19411 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/main.yml @@ -0,0 +1,42 @@ +--- +- name: install apcupsd packages + ansible.builtin.package: + name: + - apcupsd + - apcupsd-cgi + - apcupsd-doc + state: present + become: true + notify: apc_access_mail + +- name: create master config + ansible.builtin.include_tasks: master.yml + when: + - apcupsd_nis_master + - apcupsd_nis_master is defined + +- name: create slave config + ansible.builtin.include_tasks: slave.yml + when: + - not apcupsd_nis_master + - apcupsd_nis_master is defined + +- name: copy apcupsd file + become: true + ansible.builtin.template: + src: "apcupsd" + dest: "/etc/default/apcupsd" + +- name: set mail recipient + become: true + ansible.builtin.lineinfile: + path: /etc/apcupsd/apccontrol #wo + regexp: export SYSADMIN=root #suche nach + line: export SYSADMIN={{ empfaenger_mail }} #ersetze durch... + backrefs: true #verhindert das die zeile bei "nicht zutreffen" am ende der datei angefuegt wird: https://docs.ansible.com/ansible/latest/modules/lineinfile_module.html#parameters + +- name: copy test script + become: true + ansible.builtin.template: + src: "apccontrol.save" + dest: "/etc/apcupsd/apccontrol.save" diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/master.yml b/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/master.yml new file mode 100644 index 00000000..8cf17684 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/master.yml @@ -0,0 +1,7 @@ +--- +- name: templating master_apcupsd.conf + become: true + ansible.builtin.template: + src: "master_apcupsd.conf" + dest: "/etc/apcupsd/apcupsd.conf" + notify: restart_apcupsd #benachrichtigt handlers/main.yml-restart-apcupsd_restart um den dient neuzustarten, nur wenn hier status "changed" ausgeworfen wird" diff --git a/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/slave.yml b/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/slave.yml new file mode 100644 index 00000000..5f1f0d03 --- /dev/null +++ b/friedhof/mgrote_apcupsd/mgrote.apcupsd/tasks/slave.yml @@ -0,0 +1,7 @@ +--- +- name: templating slave_apcupsd.conf + become: true + ansible.builtin.template: + src: "slave_apcupsd.conf" + dest: "/etc/apcupsd/apcupsd.conf" + notify: restart_apcupsd #benachrichtigt handlers/main.yml-restart-apcupsd_restart um den dient neuzustarten, nur wenn hier status "changed" ausgeworfen wird" diff --git a/roles/mgrote.apcupsd/templates/apccontrol.save b/friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/apccontrol.save similarity index 100% rename from roles/mgrote.apcupsd/templates/apccontrol.save rename to friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/apccontrol.save diff --git a/roles/mgrote.apcupsd/templates/apcupsd b/friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/apcupsd similarity index 100% rename from roles/mgrote.apcupsd/templates/apcupsd rename to friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/apcupsd diff --git a/roles/mgrote.apcupsd/templates/master_apcupsd.conf b/friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/master_apcupsd.conf similarity index 100% rename from roles/mgrote.apcupsd/templates/master_apcupsd.conf rename to friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/master_apcupsd.conf diff --git a/roles/mgrote.apcupsd/templates/slave_apcupsd.conf b/friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/slave_apcupsd.conf similarity index 100% rename from roles/mgrote.apcupsd/templates/slave_apcupsd.conf rename to friedhof/mgrote_apcupsd/mgrote.apcupsd/templates/slave_apcupsd.conf diff --git a/friedhof/mgrote_apcupsd/tasks/main.yml b/friedhof/mgrote_apcupsd/tasks/main.yml new file mode 100644 index 00000000..bee19411 --- /dev/null +++ b/friedhof/mgrote_apcupsd/tasks/main.yml @@ -0,0 +1,42 @@ +--- +- name: install apcupsd packages + ansible.builtin.package: + name: + - apcupsd + - apcupsd-cgi + - apcupsd-doc + state: present + become: true + notify: apc_access_mail + +- name: create master config + ansible.builtin.include_tasks: master.yml + when: + - apcupsd_nis_master + - apcupsd_nis_master is defined + +- name: create slave config + ansible.builtin.include_tasks: slave.yml + when: + - not apcupsd_nis_master + - apcupsd_nis_master is defined + +- name: copy apcupsd file + become: true + ansible.builtin.template: + src: "apcupsd" + dest: "/etc/default/apcupsd" + +- name: set mail recipient + become: true + ansible.builtin.lineinfile: + path: /etc/apcupsd/apccontrol #wo + regexp: export SYSADMIN=root #suche nach + line: export SYSADMIN={{ empfaenger_mail }} #ersetze durch... + backrefs: true #verhindert das die zeile bei "nicht zutreffen" am ende der datei angefuegt wird: https://docs.ansible.com/ansible/latest/modules/lineinfile_module.html#parameters + +- name: copy test script + become: true + ansible.builtin.template: + src: "apccontrol.save" + dest: "/etc/apcupsd/apccontrol.save" diff --git a/friedhof/mgrote_apcupsd/tasks/master.yml b/friedhof/mgrote_apcupsd/tasks/master.yml new file mode 100644 index 00000000..8cf17684 --- /dev/null +++ b/friedhof/mgrote_apcupsd/tasks/master.yml @@ -0,0 +1,7 @@ +--- +- name: templating master_apcupsd.conf + become: true + ansible.builtin.template: + src: "master_apcupsd.conf" + dest: "/etc/apcupsd/apcupsd.conf" + notify: restart_apcupsd #benachrichtigt handlers/main.yml-restart-apcupsd_restart um den dient neuzustarten, nur wenn hier status "changed" ausgeworfen wird" diff --git a/friedhof/mgrote_apcupsd/tasks/slave.yml b/friedhof/mgrote_apcupsd/tasks/slave.yml new file mode 100644 index 00000000..5f1f0d03 --- /dev/null +++ b/friedhof/mgrote_apcupsd/tasks/slave.yml @@ -0,0 +1,7 @@ +--- +- name: templating slave_apcupsd.conf + become: true + ansible.builtin.template: + src: "slave_apcupsd.conf" + dest: "/etc/apcupsd/apcupsd.conf" + notify: restart_apcupsd #benachrichtigt handlers/main.yml-restart-apcupsd_restart um den dient neuzustarten, nur wenn hier status "changed" ausgeworfen wird" diff --git a/friedhof/mgrote_apcupsd/templates/apccontrol.save b/friedhof/mgrote_apcupsd/templates/apccontrol.save new file mode 100644 index 00000000..f8d74750 --- /dev/null +++ b/friedhof/mgrote_apcupsd/templates/apccontrol.save @@ -0,0 +1,138 @@ +{{ file_header | default () }} +#!@SCRIPTSHELL@ +# +# Safe apccontrol for testing. +# +# This apccontrol can be used for testing without fear +# that it will bring your system down +# @configure_input@ +# +prefix=@prefix@ +exec_prefix=@exec_prefix@ +APCUPSD=@sbindir@/apcupsd +SHUTDOWN=@SHUTDOWN@ +SCRIPTDIR=@sysconfdir@ + +# +case "$1" in + killpower) + wall <=20.04) + + +### Variablen + Defaults +see [defaults](./defaults/main.yml) + +### Abgekupfert bei +* https://alexellisuk.medium.com/lightweight-ad-blocking-with-dnsmasq-and-raspberry-pi-665dbb3242e3 +* https://www.atemlire.io/how-to-easily-create-your-own-adblock-using-dnsmasq +* https://pi-hole.net diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/defaults/main.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/defaults/main.yml new file mode 100644 index 00000000..69f398be --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/defaults/main.yml @@ -0,0 +1,41 @@ +--- +# Welche DNS-Server soll dnsmasq anfragen? +dnsmasq_resolver: + - 9.9.9.9 + - 1.1.1.1 +# Soll dnsmasq alle Anfragen loggen? +dnsmasq_log_queries: false +# Wohin soll das Log geschrieben werden? +dnsmasq_logfile: /var/log/dnsmasq.log +# Welche BLocklisten sollen verwendet werden? +dnsmasq_blocklists: + - name: sysctl.org + state: present + url: http://sysctl.org/cameleon/hosts + - name: StevenBlack.1 + state: present + url: https://raw.githubusercontent.com/StevenBlack/hosts/master/data/KADhosts/hosts + - name: StevenBlack.2 + state: present + url: https://raw.githubusercontent.com/StevenBlack/hosts/master/data/add.Spam/hosts + - name: adaway.org + state: present + url: https://adaway.org/hosts.txt + - name: StevenBlack.3 + state: present + url: https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts + - name: developerdan.1 + state: present + url: https://www.github.developerdan.com/hosts/lists/ads-and-tracking-extended.txt + - name: developerdan.2 + state: present + url: https://www.github.developerdan.com/hosts/lists/amp-hosts-extended.txt +# Wie groß soll der Cache sein? +dnsmasq_cache_size: 10000 +# Auf welchem Port soll dnsmasq laufen? +dnsmasq_port: 53 +# User und Gruppe für dnsmasq +dnsmasq_user_group: dnsmasq +dnsmasq_user: dnsmasq +# Which domain should never be forwarded tor the "dnsmasq_resolvers" +dnsmasq_never_forward_domain: local.lan diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/handlers/main.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/handlers/main.yml new file mode 100644 index 00000000..43e4e9e8 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/handlers/main.yml @@ -0,0 +1,6 @@ +--- +- name: restart dnsmasq + become: true + ansible.builtin.systemd: + name: dnsmasq + state: restarted diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/blocklist.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/blocklist.yml new file mode 100644 index 00000000..64c363bd --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/blocklist.yml @@ -0,0 +1,19 @@ +--- +- name: download blocklist(s) + ansible.builtin.get_url: + url: "{{ item.url }}" + dest: "/etc/dnsmasq.d/blocklists/{{ item.name }}" + owner: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + loop: "{{ dnsmasq_blocklists }}" + when: item.state == "present" + notify: restart dnsmasq + register: download + +- name: remove blocklist(s) + ansible.builtin.file: + path: "/etc/dnsmasq.d/blocklists/{{ item.name }}" + state: absent + loop: "{{ dnsmasq_blocklists }}" + when: item.state == "absent" + notify: restart dnsmasq diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/config.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/config.yml new file mode 100644 index 00000000..ec973e92 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/config.yml @@ -0,0 +1,9 @@ +--- +- name: template /etc/dnsmasq.conf + become: true + ansible.builtin.template: + src: dnsmasq.conf.j2 + dest: /etc/dnsmasq.conf + owner: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + notify: restart dnsmasq diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/install.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/install.yml new file mode 100644 index 00000000..f95c0cee --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/install.yml @@ -0,0 +1,62 @@ +--- +- name: ensure packages are installed + become: true + ansible.builtin.package: + name: + - dnsmasq + - wget + state: present + register: install + +- name: stop dnsmasq (to prevent accidental DHCP-Server after installation) + become: true + ansible.builtin.service: + name: dnsmasq + state: stopped + when: install.changed + +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ dnsmasq_user_group }}" + state: present + when: + - dnsmasq_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + ansible.builtin.shell: /usr/sbin/nologin + create_home: false + when: + - dnsmasq_user_group is defined + - dnsmasq_user is defined + +- name: ensure needed directories exists + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + loop: + - /etc/dnsmasq.d + - /etc/dnsmasq.d/blocklists + +- name: clear default directories + become: true + ansible.builtin.file: + path: "{{ item }}" + state: absent + loop: + - /etc/dnsmasq.d/README + +- name: template logrotate config + become: true + ansible.builtin.template: + src: logrotate.j2 + dest: /etc/logrotate.d/dnsmasq + owner: root + group: root diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/main.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/main.yml new file mode 100644 index 00000000..0cfd97c1 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/main.yml @@ -0,0 +1,12 @@ +--- +- name: include install tasks + ansible.builtin.include_tasks: install.yml + +- name: include configuration tasks + ansible.builtin.include_tasks: config.yml + +- name: include systemd tasks + ansible.builtin.include_tasks: services.yml + +- name: include blocklist tasks + ansible.builtin.include_tasks: blocklist.yml diff --git a/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/services.yml b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/services.yml new file mode 100644 index 00000000..f240ce4e --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/tasks/services.yml @@ -0,0 +1,18 @@ +--- +- name: stop systemd-resolved service + ansible.builtin.systemd: + name: systemd-resolved + state: stopped + +- name: mask systemd-resolved service + ansible.builtin.systemd: + name: systemd-resolved + masked: true + state: stopped + +- name: template /etc/resolv.conf + ansible.builtin.template: + src: resolv.conf.j2 + dest: /etc/resolv.conf + backup: true + notify: restart dnsmasq diff --git a/roles/mgrote.dnsmasq_adblocker/templates/dnsmasq.conf.j2 b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/templates/dnsmasq.conf.j2 similarity index 100% rename from roles/mgrote.dnsmasq_adblocker/templates/dnsmasq.conf.j2 rename to friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/templates/dnsmasq.conf.j2 diff --git a/roles/mgrote.dnsmasq_adblocker/templates/logrotate.j2 b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/templates/logrotate.j2 similarity index 100% rename from roles/mgrote.dnsmasq_adblocker/templates/logrotate.j2 rename to friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/templates/logrotate.j2 diff --git a/roles/mgrote.dnsmasq_adblocker/templates/resolv.conf.j2 b/friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/templates/resolv.conf.j2 similarity index 100% rename from roles/mgrote.dnsmasq_adblocker/templates/resolv.conf.j2 rename to friedhof/mgrote_dnsmasq_adblocker/mgrote.dnsmasq_adblocker/templates/resolv.conf.j2 diff --git a/friedhof/mgrote_dnsmasq_adblocker/tasks/blocklist.yml b/friedhof/mgrote_dnsmasq_adblocker/tasks/blocklist.yml new file mode 100644 index 00000000..64c363bd --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/tasks/blocklist.yml @@ -0,0 +1,19 @@ +--- +- name: download blocklist(s) + ansible.builtin.get_url: + url: "{{ item.url }}" + dest: "/etc/dnsmasq.d/blocklists/{{ item.name }}" + owner: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + loop: "{{ dnsmasq_blocklists }}" + when: item.state == "present" + notify: restart dnsmasq + register: download + +- name: remove blocklist(s) + ansible.builtin.file: + path: "/etc/dnsmasq.d/blocklists/{{ item.name }}" + state: absent + loop: "{{ dnsmasq_blocklists }}" + when: item.state == "absent" + notify: restart dnsmasq diff --git a/friedhof/mgrote_dnsmasq_adblocker/tasks/config.yml b/friedhof/mgrote_dnsmasq_adblocker/tasks/config.yml new file mode 100644 index 00000000..ec973e92 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/tasks/config.yml @@ -0,0 +1,9 @@ +--- +- name: template /etc/dnsmasq.conf + become: true + ansible.builtin.template: + src: dnsmasq.conf.j2 + dest: /etc/dnsmasq.conf + owner: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + notify: restart dnsmasq diff --git a/friedhof/mgrote_dnsmasq_adblocker/tasks/install.yml b/friedhof/mgrote_dnsmasq_adblocker/tasks/install.yml new file mode 100644 index 00000000..f95c0cee --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/tasks/install.yml @@ -0,0 +1,62 @@ +--- +- name: ensure packages are installed + become: true + ansible.builtin.package: + name: + - dnsmasq + - wget + state: present + register: install + +- name: stop dnsmasq (to prevent accidental DHCP-Server after installation) + become: true + ansible.builtin.service: + name: dnsmasq + state: stopped + when: install.changed + +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ dnsmasq_user_group }}" + state: present + when: + - dnsmasq_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + ansible.builtin.shell: /usr/sbin/nologin + create_home: false + when: + - dnsmasq_user_group is defined + - dnsmasq_user is defined + +- name: ensure needed directories exists + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: "{{ dnsmasq_user }}" + group: "{{ dnsmasq_user_group }}" + loop: + - /etc/dnsmasq.d + - /etc/dnsmasq.d/blocklists + +- name: clear default directories + become: true + ansible.builtin.file: + path: "{{ item }}" + state: absent + loop: + - /etc/dnsmasq.d/README + +- name: template logrotate config + become: true + ansible.builtin.template: + src: logrotate.j2 + dest: /etc/logrotate.d/dnsmasq + owner: root + group: root diff --git a/friedhof/mgrote_dnsmasq_adblocker/tasks/main.yml b/friedhof/mgrote_dnsmasq_adblocker/tasks/main.yml new file mode 100644 index 00000000..0cfd97c1 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/tasks/main.yml @@ -0,0 +1,12 @@ +--- +- name: include install tasks + ansible.builtin.include_tasks: install.yml + +- name: include configuration tasks + ansible.builtin.include_tasks: config.yml + +- name: include systemd tasks + ansible.builtin.include_tasks: services.yml + +- name: include blocklist tasks + ansible.builtin.include_tasks: blocklist.yml diff --git a/friedhof/mgrote_dnsmasq_adblocker/tasks/services.yml b/friedhof/mgrote_dnsmasq_adblocker/tasks/services.yml new file mode 100644 index 00000000..f240ce4e --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/tasks/services.yml @@ -0,0 +1,18 @@ +--- +- name: stop systemd-resolved service + ansible.builtin.systemd: + name: systemd-resolved + state: stopped + +- name: mask systemd-resolved service + ansible.builtin.systemd: + name: systemd-resolved + masked: true + state: stopped + +- name: template /etc/resolv.conf + ansible.builtin.template: + src: resolv.conf.j2 + dest: /etc/resolv.conf + backup: true + notify: restart dnsmasq diff --git a/friedhof/mgrote_dnsmasq_adblocker/templates/dnsmasq.conf.j2 b/friedhof/mgrote_dnsmasq_adblocker/templates/dnsmasq.conf.j2 new file mode 100644 index 00000000..382b3214 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/templates/dnsmasq.conf.j2 @@ -0,0 +1,63 @@ +{{ file_header | default () }} +# Listen on this specific port instead of the standard DNS port +# (53). Setting this to zero completely disables DNS function, +# leaving only DHCP and/or TFTP. +port={{ dnsmasq_port }} + +# If you want dnsmasq to listen for DHCP and DNS requests only on +# specified interfaces (and the loopback) give the name of the +# interface (eg eth0) here. +# Repeat the line for more than one interface. +interface={{ ansible_default_ipv4.interface }} + +# If you want dnsmasq to provide only DNS service on an interface, +# configure it as shown above, and then use the following line to +# disable DHCP and TFTP on it. +no-dhcp-interface={{ ansible_default_ipv4.interface }} + +# Set the cachesize here. +cache-size={{ dnsmasq_cache_size }} + +log-facility={{ dnsmasq_logfile }} + +# Never forward plain names (without a dot or domain part) +domain-needed + +# Never forward addresses in the non-routed address spaces. +bogus-priv + +# If you don't want dnsmasq to read /etc/hosts, uncomment the +# following line. +no-hosts + +# Add local-only domains here, queries in these domains are answered +# from /etc/hosts or DHCP only. +local=/{{ dnsmasq_never_forward_domain }}/ + +# RFC 6761: Caching DNS servers SHOULD recognize +# test, localhost, invalid +# names as special and SHOULD NOT attempt to look up NS records for them, or +# otherwise query authoritative DNS servers in an attempt to resolve these +# names. +server=/test/ +server=/localhost/ +server=/invalid/ + +# OpenWRT furthermore blocks bind, local, onion domains +# see https://git.openwrt.org/?p=openwrt/openwrt.git;a=blob_plain;f=package/network/services/dnsmasq/files/rfc6761.conf;hb=HEAD +# and https://www.iana.org/assignments/special-use-domain-names/special-use-domain-names.xhtml +server=/bind/ +server=/onion/ + +# If you don't want dnsmasq to read /etc/hosts, uncomment the +# following line. +#no-hosts +# or if you want it to read another file, as well as /etc/hosts, use +# this. +addn-hosts=/etc/dnsmasq.d/blocklists + +{% if dnsmasq_log_queries is sameas true %} +# For debugging purposes, log each DNS query as it passes through +# dnsmasq. +log-queries +{% endif %} diff --git a/roles/_mgrote.musterrolle/templates/logrotate_restic b/friedhof/mgrote_dnsmasq_adblocker/templates/logrotate.j2 similarity index 62% rename from roles/_mgrote.musterrolle/templates/logrotate_restic rename to friedhof/mgrote_dnsmasq_adblocker/templates/logrotate.j2 index 5fbaaf66..bb72c21d 100644 --- a/roles/_mgrote.musterrolle/templates/logrotate_restic +++ b/friedhof/mgrote_dnsmasq_adblocker/templates/logrotate.j2 @@ -1,12 +1,15 @@ {{ file_header | default () }} -/var/log/restic.log { +{{ dnsmasq_logfile }} { su root root create 0640 root root rotate 4 - weekly + daily compress missingok notifempty dateext dateyesterday + postrotate + systemctl restart dnsmasq + endscript } diff --git a/friedhof/mgrote_dnsmasq_adblocker/templates/resolv.conf.j2 b/friedhof/mgrote_dnsmasq_adblocker/templates/resolv.conf.j2 new file mode 100644 index 00000000..24cc4d58 --- /dev/null +++ b/friedhof/mgrote_dnsmasq_adblocker/templates/resolv.conf.j2 @@ -0,0 +1,4 @@ +{{ file_header | default () }} +{% for item in dnsmasq_resolver %} +nameserver {{ item }} +{% endfor %} diff --git a/roles/mgrote.docker-compose-deploy/LICENSE b/friedhof/mgrote_docker_compose_deploy/LICENSE similarity index 100% rename from roles/mgrote.docker-compose-deploy/LICENSE rename to friedhof/mgrote_docker_compose_deploy/LICENSE diff --git a/roles/mgrote.docker-compose-deploy/README.md b/friedhof/mgrote_docker_compose_deploy/README.md similarity index 100% rename from roles/mgrote.docker-compose-deploy/README.md rename to friedhof/mgrote_docker_compose_deploy/README.md diff --git a/friedhof/mgrote_docker_compose_deploy/tasks/dockercompose-down.yml b/friedhof/mgrote_docker_compose_deploy/tasks/dockercompose-down.yml new file mode 100644 index 00000000..e1ea2e39 --- /dev/null +++ b/friedhof/mgrote_docker_compose_deploy/tasks/dockercompose-down.yml @@ -0,0 +1,24 @@ +--- +- name: set dir - "{{ item.name }}" + ansible.builtin.set_fact: + project_dir: "{{ docker_compose_base_dir }}/{{ item.dir_name | default (item.name) }}" + when: + - docker_compose_base_dir is defined + - docker_compose_projects is defined + +- name: check if dir exists + ansible.builtin.stat: + path: "{{ project_dir }}" + register: dir + +- name: stop container - "{{ item.name }}" + ansible.builtin.shell: docker-compose down + args: + chdir: "{{ project_dir }}" + when: dir.stat.exists + +- name: remove repository - "{{ item.name }}" + ansible.builtin.file: + state: absent + dest: "{{ project_dir }}" + when: dir.stat.exists diff --git a/friedhof/mgrote_docker_compose_deploy/tasks/dockercompose-up.yml b/friedhof/mgrote_docker_compose_deploy/tasks/dockercompose-up.yml new file mode 100644 index 00000000..2ea5937c --- /dev/null +++ b/friedhof/mgrote_docker_compose_deploy/tasks/dockercompose-up.yml @@ -0,0 +1,64 @@ +--- +- name: set username and passwort - "{{ item.name }}" + ansible.builtin.set_fact: + login: "{{ item.repository_user }}:{{ item.repository_user_password }}@" + when: + - item.repository_user is defined + - item.repository_user_password is defined + +- name: set dir - "{{ item.name }}" + ansible.builtin.set_fact: + project_dir: "{{ docker_compose_base_dir }}/{{ item.dir_name | default (item.name) }}" + when: + - docker_compose_base_dir is defined + - docker_compose_projects is defined + +- name: check if repo exists - "{{ item.name }}" (wenn der Task >30s dauert sind die Login-Daten falsch) + ansible.builtin.stat: + path: "{{ project_dir }}" + register: repo_exists + +- name: set safe directory + become: true + ansible.builtin.shell: + cmd: git config --global --add safe.directory "{{ project_dir }}" + changed_when: false + +- name: stash changes - "{{ item.name }}" + ansible.builtin.shell: git stash + args: + chdir: "{{ project_dir }}" + changed_when: false + when: repo_exists.stat.exists + +- name: clone repository - "{{ item.name }}" + ansible.builtin.git: + repo: "https://{{ login | default () }}{{ item.repository_url }}" + dest: "{{ project_dir }}" + version: "{{ item.git_branch | default ('master') }}" + register: repo + +- name: set owner recursive for repo + ansible.builtin.file: + path: "{{ project_dir }}" + owner: "{{ item.os_username }}" + group: "{{ item.os_username }}" + recurse: true + when: repo is changed + +- name: create networks - "{{ item.name }}" + ansible.builtin.shell: "docker network create {{ item.network_name }}" # erstelle network + when: "item.network_name is defined" # wenn network_name definiert ist + register: network_result # speichere ergebnis in var + changed_when: "network_result.rc == 0" # markiere tasks als changed when exit-code == 0 + ignore_errors: true # ignoriere fehler + +- name: (re)start container - "{{ item.name }}" + ansible.builtin.shell: docker-compose down && docker-compose up -d + args: + chdir: "{{ project_dir }}" + when: repo.changed + +- name: unset username and passwort - "{{ item.name }}" + ansible.builtin.set_fact: + login: "" diff --git a/friedhof/mgrote_docker_compose_deploy/tasks/main.yml b/friedhof/mgrote_docker_compose_deploy/tasks/main.yml new file mode 100644 index 00000000..2dd5d728 --- /dev/null +++ b/friedhof/mgrote_docker_compose_deploy/tasks/main.yml @@ -0,0 +1,16 @@ +--- +- name: loop docker tasks - up + ansible.builtin.include_tasks: dockercompose-up.yml + loop: "{{ docker_compose_projects }}" + when: + - item.state == "present" + - docker_compose_projects is defined + no_log: true + +- name: loop docker tasks - down + ansible.builtin.include_tasks: dockercompose-down.yml + loop: "{{ docker_compose_projects }}" + when: + - item.state == "absent" + - docker_compose_projects is defined + no_log: true diff --git a/roles/mgrote.docker-compose-inline/LICENSE b/friedhof/mgrote_i3/LICENSE similarity index 100% rename from roles/mgrote.docker-compose-inline/LICENSE rename to friedhof/mgrote_i3/LICENSE diff --git a/roles/mgrote.dokuwiki/LICENSE b/friedhof/mgrote_i3/mgrote.i3/LICENSE similarity index 100% rename from roles/mgrote.dokuwiki/LICENSE rename to friedhof/mgrote_i3/mgrote.i3/LICENSE diff --git a/roles/mgrote.i3/readme.md b/friedhof/mgrote_i3/mgrote.i3/readme.md similarity index 100% rename from roles/mgrote.i3/readme.md rename to friedhof/mgrote_i3/mgrote.i3/readme.md diff --git a/friedhof/mgrote_i3/mgrote.i3/tasks/main.yml b/friedhof/mgrote_i3/mgrote.i3/tasks/main.yml new file mode 100644 index 00000000..f39bedee --- /dev/null +++ b/friedhof/mgrote_i3/mgrote.i3/tasks/main.yml @@ -0,0 +1,15 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - i3 + - i3lock + - arandr + - x11-xserver-utils # xrandr + - feh # wallpaper + - rofi + - xautolock #bildschirmsperre nach x min + - flameshot #screenshots + - dunst #notification daemon + state: present diff --git a/friedhof/mgrote_i3/readme.md b/friedhof/mgrote_i3/readme.md new file mode 100644 index 00000000..f45cf8a6 --- /dev/null +++ b/friedhof/mgrote_i3/readme.md @@ -0,0 +1,4 @@ +## mgrote.vim + +### Beschreibung +installiert i3 + tools. diff --git a/friedhof/mgrote_i3/tasks/main.yml b/friedhof/mgrote_i3/tasks/main.yml new file mode 100644 index 00000000..f39bedee --- /dev/null +++ b/friedhof/mgrote_i3/tasks/main.yml @@ -0,0 +1,15 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - i3 + - i3lock + - arandr + - x11-xserver-utils # xrandr + - feh # wallpaper + - rofi + - xautolock #bildschirmsperre nach x min + - flameshot #screenshots + - dunst #notification daemon + state: present diff --git a/roles/mgrote.dotfiles/LICENSE b/friedhof/mgrote_minio/LICENSE similarity index 100% rename from roles/mgrote.dotfiles/LICENSE rename to friedhof/mgrote_minio/LICENSE diff --git a/roles/mgrote.minio/README.md b/friedhof/mgrote_minio/README.md similarity index 100% rename from roles/mgrote.minio/README.md rename to friedhof/mgrote_minio/README.md diff --git a/friedhof/mgrote_minio/defaults/main.yml b/friedhof/mgrote_minio/defaults/main.yml new file mode 100644 index 00000000..72481169 --- /dev/null +++ b/friedhof/mgrote_minio/defaults/main.yml @@ -0,0 +1,20 @@ +--- +minio_download_url: https://dl.min.io/server/minio/release/linux-amd64/minio # downloadlink + +minio_bin_path: /usr/local/bin # where to put the binary +minio_volumes_base_dir: /usr/local/share/minio/ # where to store the buckets +minio_config_dir: /etc/minio # where to store the config + +minio_fqdn: minio-test.grote.lan +minio_port: 9000 # s3 port +minio_console_port: 34081 # mgmt-gui port + +minio_root_user: minio # default web user +minio_root_password: miniostorage # defaut pass + +minio_user: minio-user # linux user +minio_group: minio-user # linux group + +minio_server_url: "" # see https://docs.min.io/minio/baremetal/reference/minio-server/minio-server.html + +minio_browser_redirect_url: "" # see https://docs.min.io/minio/baremetal/reference/minio-server/minio-server.html diff --git a/friedhof/mgrote_minio/handlers/main.yml b/friedhof/mgrote_minio/handlers/main.yml new file mode 100644 index 00000000..1f4ae1d4 --- /dev/null +++ b/friedhof/mgrote_minio/handlers/main.yml @@ -0,0 +1,6 @@ +--- +- name: (re)start service + become: true + ansible.builtin.systemd: + name: minio + state: restarted diff --git a/roles/mgrote.exa/LICENSE b/friedhof/mgrote_minio/mgrote.minio/LICENSE similarity index 100% rename from roles/mgrote.exa/LICENSE rename to friedhof/mgrote_minio/mgrote.minio/LICENSE diff --git a/friedhof/mgrote_minio/mgrote.minio/README.md b/friedhof/mgrote_minio/mgrote.minio/README.md new file mode 100644 index 00000000..198a277e --- /dev/null +++ b/friedhof/mgrote_minio/mgrote.minio/README.md @@ -0,0 +1,12 @@ +## mgrote.minio + +### Beschreibung +Installiert einen Single-Minio-Server. + +### getestet auf +- [X] Ubuntu (>=20.04) +- [ ] Debian +- [ ] ProxMox 6.1 + +### Variablen + Defaults +see [defaults](./defaults/main.yml) diff --git a/friedhof/mgrote_minio/mgrote.minio/defaults/main.yml b/friedhof/mgrote_minio/mgrote.minio/defaults/main.yml new file mode 100644 index 00000000..72481169 --- /dev/null +++ b/friedhof/mgrote_minio/mgrote.minio/defaults/main.yml @@ -0,0 +1,20 @@ +--- +minio_download_url: https://dl.min.io/server/minio/release/linux-amd64/minio # downloadlink + +minio_bin_path: /usr/local/bin # where to put the binary +minio_volumes_base_dir: /usr/local/share/minio/ # where to store the buckets +minio_config_dir: /etc/minio # where to store the config + +minio_fqdn: minio-test.grote.lan +minio_port: 9000 # s3 port +minio_console_port: 34081 # mgmt-gui port + +minio_root_user: minio # default web user +minio_root_password: miniostorage # defaut pass + +minio_user: minio-user # linux user +minio_group: minio-user # linux group + +minio_server_url: "" # see https://docs.min.io/minio/baremetal/reference/minio-server/minio-server.html + +minio_browser_redirect_url: "" # see https://docs.min.io/minio/baremetal/reference/minio-server/minio-server.html diff --git a/friedhof/mgrote_minio/mgrote.minio/handlers/main.yml b/friedhof/mgrote_minio/mgrote.minio/handlers/main.yml new file mode 100644 index 00000000..1f4ae1d4 --- /dev/null +++ b/friedhof/mgrote_minio/mgrote.minio/handlers/main.yml @@ -0,0 +1,6 @@ +--- +- name: (re)start service + become: true + ansible.builtin.systemd: + name: minio + state: restarted diff --git a/friedhof/mgrote_minio/mgrote.minio/tasks/main.yml b/friedhof/mgrote_minio/mgrote.minio/tasks/main.yml new file mode 100644 index 00000000..05a5a677 --- /dev/null +++ b/friedhof/mgrote_minio/mgrote.minio/tasks/main.yml @@ -0,0 +1,62 @@ +--- +- name: ensure group exists + ansible.builtin.group: + name: "{{ minio_group }}" + state: present + +- name: ensure user exists + ansible.builtin.user: + name: "{{ minio_user }}" + group: "{{ minio_group }}" + ansible.builtin.shell: /sbin/nologin + state: present + create_home: false + +- name: ensure needed directories are present + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + with_items: + - "{{ minio_volumes_base_dir }}" + - "{{ minio_config_dir }}" + +- name: download binary + ansible.builtin.get_url: + url: "{{ minio_download_url }}" + dest: "{{ minio_bin_path }}/minio" + mode: "0744" + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + +- name: template default config + become: true + ansible.builtin.template: + src: "default.j2" + dest: "/etc/default/minio" + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + notify: (re)start service + no_log: true + +- name: template systemd-unit + become: true + ansible.builtin.template: + src: "minio.service.j2" + dest: "/etc/systemd/system/minio.service" + mode: a+x + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + notify: (re)start service + +- name: systemd daemon reload + become: true + ansible.builtin.systemd: + daemon_reload: true + +- name: enable systemd service + become: true + ansible.builtin.systemd: + name: minio + enabled: true diff --git a/roles/mgrote.minio/templates/default.j2 b/friedhof/mgrote_minio/mgrote.minio/templates/default.j2 similarity index 100% rename from roles/mgrote.minio/templates/default.j2 rename to friedhof/mgrote_minio/mgrote.minio/templates/default.j2 diff --git a/roles/mgrote.minio/templates/minio.service.j2 b/friedhof/mgrote_minio/mgrote.minio/templates/minio.service.j2 similarity index 100% rename from roles/mgrote.minio/templates/minio.service.j2 rename to friedhof/mgrote_minio/mgrote.minio/templates/minio.service.j2 diff --git a/friedhof/mgrote_minio/tasks/main.yml b/friedhof/mgrote_minio/tasks/main.yml new file mode 100644 index 00000000..05a5a677 --- /dev/null +++ b/friedhof/mgrote_minio/tasks/main.yml @@ -0,0 +1,62 @@ +--- +- name: ensure group exists + ansible.builtin.group: + name: "{{ minio_group }}" + state: present + +- name: ensure user exists + ansible.builtin.user: + name: "{{ minio_user }}" + group: "{{ minio_group }}" + ansible.builtin.shell: /sbin/nologin + state: present + create_home: false + +- name: ensure needed directories are present + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + with_items: + - "{{ minio_volumes_base_dir }}" + - "{{ minio_config_dir }}" + +- name: download binary + ansible.builtin.get_url: + url: "{{ minio_download_url }}" + dest: "{{ minio_bin_path }}/minio" + mode: "0744" + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + +- name: template default config + become: true + ansible.builtin.template: + src: "default.j2" + dest: "/etc/default/minio" + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + notify: (re)start service + no_log: true + +- name: template systemd-unit + become: true + ansible.builtin.template: + src: "minio.service.j2" + dest: "/etc/systemd/system/minio.service" + mode: a+x + owner: "{{ minio_user }}" + group: "{{ minio_user }}" + notify: (re)start service + +- name: systemd daemon reload + become: true + ansible.builtin.systemd: + daemon_reload: true + +- name: enable systemd service + become: true + ansible.builtin.systemd: + name: minio + enabled: true diff --git a/friedhof/mgrote_minio/templates/default.j2 b/friedhof/mgrote_minio/templates/default.j2 new file mode 100644 index 00000000..fc15b740 --- /dev/null +++ b/friedhof/mgrote_minio/templates/default.j2 @@ -0,0 +1,7 @@ +MINIO_ROOT_USER="{{ minio_root_user }}" +MINIO_VOLUMES="{{ minio_volumes_base_dir }}" +MINIO_OPTS="-C {{ minio_config_dir }} --address {{ minio_fqdn }}:{{ minio_port }} --console-address :{{ minio_console_port }}" +MINIO_ROOT_PASSWORD="{{ minio_root_password }}" + +MINIO_SERVER_URL="{{ minio_server_url }}" +MINIO_BROWSER_REDIRECT_URL="{{ minio_browser_redirect_url}}" diff --git a/friedhof/mgrote_minio/templates/minio.service.j2 b/friedhof/mgrote_minio/templates/minio.service.j2 new file mode 100644 index 00000000..29486dab --- /dev/null +++ b/friedhof/mgrote_minio/templates/minio.service.j2 @@ -0,0 +1,36 @@ +[Unit] +Description=MinIO +Documentation=https://docs.min.io +Wants=network-online.target +After=network-online.target +AssertFileIsExecutable=/usr/local/bin/minio + +[Service] +WorkingDirectory=/usr/local/ + +User={{ minio_user }} +Group={{ minio_group }} +ProtectProc=invisible + +EnvironmentFile=/etc/default/minio +ExecStartPre=/bin/bash -c "if [ -z \"${MINIO_VOLUMES}\" ]; then echo \"Variable MINIO_VOLUMES not set in /etc/default/minio\"; exit 1; fi" + +ExecStart={{ minio_bin_path }}/minio server $MINIO_OPTS $MINIO_VOLUMES + +# Let systemd restart this service always +Restart=always + +# Specifies the maximum file descriptor number that can be opened by this process +LimitNOFILE=65536 + +# Specifies the maximum number of threads this process can create +TasksMax=infinity + +# Disable timeout logic and wait until process is stopped +TimeoutStopSec=infinity +SendSIGKILL=no + +[Install] +WantedBy=multi-user.target + +# Built for ${project.name}-${project.version} (${project.name}) diff --git a/roles/mgrote.motd/README.md b/friedhof/mgrote_motd/README.md similarity index 100% rename from roles/mgrote.motd/README.md rename to friedhof/mgrote_motd/README.md diff --git a/friedhof/mgrote_motd/defaults/main.yml b/friedhof/mgrote_motd/defaults/main.yml new file mode 100644 index 00000000..37927134 --- /dev/null +++ b/friedhof/mgrote_motd/defaults/main.yml @@ -0,0 +1,12 @@ +--- +motd_wetter_ort: "Magdeburg" +motd_wetter_aktiv: false +motd_fortune_aktiv: false + +managed_files: + - 00-ansible + - 05-fortune + - 10-wetter + - 20-facts + - 90-updates + - 91-reboot diff --git a/friedhof/mgrote_motd/handlers/main.yml b/friedhof/mgrote_motd/handlers/main.yml new file mode 100644 index 00000000..7519b0d8 --- /dev/null +++ b/friedhof/mgrote_motd/handlers/main.yml @@ -0,0 +1,6 @@ +--- +- name: restart_sshd + become: true + ansible.builtin.systemd: + name: sshd + state: restarted diff --git a/friedhof/mgrote_motd/tasks/base.yml b/friedhof/mgrote_motd/tasks/base.yml new file mode 100644 index 00000000..e08740cc --- /dev/null +++ b/friedhof/mgrote_motd/tasks/base.yml @@ -0,0 +1,70 @@ +--- +# - name: install packages +# become: true +# ansible.builtin.package: +# name: +# - update-motd +# state: present +# when: "ansible_facts['distribution'] == 'Ubuntu'" + +- name: remove default packages + become: true + ansible.builtin.package: + name: + - motd-news-config + state: absent + +- name: 'remove unwanted motd messages' + become: true + ansible.builtin.file: + path: '/etc/update-motd.d/{{ item }}' + state: absent + with_items: + - 00-header + - 10-help-text + - 10-uname + - 50-motd-news + - 80-livepatch + - 50-landscape-sysinfo + - 51-cloudguest + - 99-esm + - 00-ansible + - 20-facts + - 90-updates + - 91-reboot + - 90-updates-available + - 91-release-upgrade + +- name: delete "no warranty" - Message + become: true + ansible.builtin.file: + path: /etc/motd + state: absent + +- name: setup new motd + become: true + ansible.builtin.template: + src: '{{ item }}' + dest: '/etc/update-motd.d/{{ item }}' + owner: root + group: root + mode: "0755" + with_items: + - 00-ansible-mgrote + - 20-facts-mgrote + - 90-updates-mgrote + - 91-reboot-mgrote + +- name: delete fortune + become: true + ansible.builtin.file: + path: /etc/update-motd.d/05-fortune-mgrote + state: absent + when: falset motd_fortune_aktiv + +- name: delete Wetter + become: true + ansible.builtin.file: + path: '/etc/update-motd.d/10-wetter-mgrote' + state: absent + when: falset motd_wetter_aktiv diff --git a/friedhof/mgrote_motd/tasks/fortune.yml b/friedhof/mgrote_motd/tasks/fortune.yml new file mode 100644 index 00000000..d8678db9 --- /dev/null +++ b/friedhof/mgrote_motd/tasks/fortune.yml @@ -0,0 +1,16 @@ +--- +- name: install fortune + become: true + ansible.builtin.package: + name: + - fortune + state: present + +- name: setup new motd - fortune + become: true + ansible.builtin.template: + src: '05-fortune-mgrote' + dest: '/etc/update-motd.d/05-fortune-mgrote' + owner: root + group: root + mode: "0755" diff --git a/friedhof/mgrote_motd/tasks/main.yml b/friedhof/mgrote_motd/tasks/main.yml new file mode 100644 index 00000000..08a3b68b --- /dev/null +++ b/friedhof/mgrote_motd/tasks/main.yml @@ -0,0 +1,16 @@ +--- +- name: include systemctl tasks + ansible.builtin.include_tasks: systemctl.yml + +- name: include base tasks + ansible.builtin.include_tasks: base.yml + +- name: include fortune tasks + ansible.builtin.include_tasks: fortune.yml + when: + - motd_wetter_aktiv + +- name: include weather tasks + ansible.builtin.include_tasks: weather.yml + when: + - motd_wetter_aktiv diff --git a/friedhof/mgrote_motd/tasks/systemctl.yml b/friedhof/mgrote_motd/tasks/systemctl.yml new file mode 100644 index 00000000..441612d3 --- /dev/null +++ b/friedhof/mgrote_motd/tasks/systemctl.yml @@ -0,0 +1,10 @@ +--- +- name: stop units + become: true + ansible.builtin.systemd: + name: motd-news + masked: true + state: stopped + enabled: false + daemon_reload: true + ignore_errors: true diff --git a/friedhof/mgrote_motd/tasks/weather.yml b/friedhof/mgrote_motd/tasks/weather.yml new file mode 100644 index 00000000..93337563 --- /dev/null +++ b/friedhof/mgrote_motd/tasks/weather.yml @@ -0,0 +1,9 @@ +--- +- name: setup new motd - wetter + become: true + ansible.builtin.template: + src: '10-wetter-mgrote' + dest: '/etc/update-motd.d/10-wetter-mgrote' + owner: root + group: root + mode: "0755" diff --git a/roles/mgrote.motd/templates/00-ansible-mgrote b/friedhof/mgrote_motd/templates/00-ansible-mgrote similarity index 100% rename from roles/mgrote.motd/templates/00-ansible-mgrote rename to friedhof/mgrote_motd/templates/00-ansible-mgrote diff --git a/roles/mgrote.motd/templates/05-fortune-mgrote b/friedhof/mgrote_motd/templates/05-fortune-mgrote similarity index 100% rename from roles/mgrote.motd/templates/05-fortune-mgrote rename to friedhof/mgrote_motd/templates/05-fortune-mgrote diff --git a/roles/mgrote.motd/templates/10-wetter-mgrote b/friedhof/mgrote_motd/templates/10-wetter-mgrote similarity index 100% rename from roles/mgrote.motd/templates/10-wetter-mgrote rename to friedhof/mgrote_motd/templates/10-wetter-mgrote diff --git a/roles/mgrote.motd/templates/20-facts-mgrote b/friedhof/mgrote_motd/templates/20-facts-mgrote similarity index 100% rename from roles/mgrote.motd/templates/20-facts-mgrote rename to friedhof/mgrote_motd/templates/20-facts-mgrote diff --git a/roles/mgrote.motd/templates/90-updates-mgrote b/friedhof/mgrote_motd/templates/90-updates-mgrote similarity index 100% rename from roles/mgrote.motd/templates/90-updates-mgrote rename to friedhof/mgrote_motd/templates/90-updates-mgrote diff --git a/roles/mgrote.motd/templates/91-reboot-mgrote b/friedhof/mgrote_motd/templates/91-reboot-mgrote similarity index 100% rename from roles/mgrote.motd/templates/91-reboot-mgrote rename to friedhof/mgrote_motd/templates/91-reboot-mgrote diff --git a/friedhof/mgrote_munin_node/defaults/main.yml b/friedhof/mgrote_munin_node/defaults/main.yml new file mode 100644 index 00000000..fafaf701 --- /dev/null +++ b/friedhof/mgrote_munin_node/defaults/main.yml @@ -0,0 +1,33 @@ +--- +munin_user_group: root # group to which the user belongs +munin_node_log: /var/log/munin/munin-node.log +munin_node_pid: /var/run/munin/munin-node.pid +munin_node_plugin_timeout: 60 # in sec +munin_node_global_timeout: 900 # in sec +munin_node_host_name: '' # Set this if the client doesn't report the correct hostname +munin_node_allowed_ips: # A list of addresses that are allowed to connect Munin requires IPs be added as regular expressions. + - '^127\.0\.0\.1$' + - '^::1$' +munin_node_allowed_cidrs: [192.168.2.0/24] # A list of addresses that are allowed to connect +munin_node_denied_cidrs: [] # a list of addresses that are not allowed to connect +munin_node_bind_host: "0.0.0.0" # bind to interface +munin_node_bind_port: "4949" # bind to port +munin_node_log_level: 4 # Loglevel + +# Plugin configuration options (the key is the plugin heading, items within will +# be options for the plugin). +# Source and destination of munin plugins. +munin_plugin_src_path: /usr/share/munin/plugins/ +munin_plugin_dest_path: /etc/munin/plugins/ +munin_plugin_conf_dest_path: /etc/munin/plugin-conf.d/ +# munin_node_plugins: #plugins to install +# - name: docker_volumes # name +# src: https://git.mgrote.net/mg/mirror-munin-contrib/raw/branch/master/plugins/docker/docker_ #src +# config_file_name: /etc/munin/plugin-conf.d/docker # where to put plugin config + # content of config +# config: | +# user root +# env.DOCKER_HOST unix://run/docker.sock + +# munin_node_disabled_plugins: # remove plugins from running config +# - name: meminfo diff --git a/friedhof/mgrote_munin_node/handlers/main.yml b/friedhof/mgrote_munin_node/handlers/main.yml new file mode 100644 index 00000000..1305c543 --- /dev/null +++ b/friedhof/mgrote_munin_node/handlers/main.yml @@ -0,0 +1,15 @@ +--- +- name: restart munin-node + ansible.builtin.service: + name: munin-node + state: restarted + +- name: munin-node-configure --shell # noqa ignore-errors + ansible.builtin.command: munin-node-configure --shell + register: output_conf + changed_when: "output_conf.rc != 0" + ignore_errors: true # ignoriere fehler + +- name: munin-node-configure --shell - 2 # noqa ignore-errors + ansible.builtin.command: munin-node-configure --shell --families=contrib,auto | sh -x + ignore_errors: true # ignoriere fehler diff --git a/roles/mgrote.munin-node/readme.md b/friedhof/mgrote_munin_node/readme.md similarity index 100% rename from roles/mgrote.munin-node/readme.md rename to friedhof/mgrote_munin_node/readme.md diff --git a/friedhof/mgrote_munin_node/tasks/additional.yml b/friedhof/mgrote_munin_node/tasks/additional.yml new file mode 100644 index 00000000..6061c696 --- /dev/null +++ b/friedhof/mgrote_munin_node/tasks/additional.yml @@ -0,0 +1,37 @@ +--- +- name: download additional plugins + ansible.builtin.get_url: + url: "{{ item.src }}" + dest: "{{ munin_plugin_src_path }}{{ item.name }}" + mode: '0755' + loop: "{{ munin_node_plugins }}" + notify: restart munin-node + no_log: true + check_mode: false # damit werden auch im check-mode die Plugins heruntergeladen, sonst schlägt der nächste Task fehl + +- name: enable additional plugins + ansible.builtin.file: + src: "{{ munin_plugin_src_path }}{{ item.name }}" + dest: "{{ munin_plugin_dest_path }}{{ item.name }}" + state: link + notify: restart munin-node + loop: "{{ munin_node_plugins }}" + no_log: true + +- name: copy additional plugin-config + ansible.builtin.copy: + content: "{{ item.config }}" + dest: "{{ munin_plugin_conf_dest_path }}{{ item.name }}" + owner: root + group: root + mode: "0644" + notify: restart munin-node + loop: "{{ munin_node_plugins }}" + when: item.config is defined + no_log: true + +- name: Ensure munin-node is running. + ansible.builtin.service: + name: munin-node + state: started + enabled: true diff --git a/friedhof/mgrote_munin_node/tasks/install.yml b/friedhof/mgrote_munin_node/tasks/install.yml new file mode 100644 index 00000000..ed52e48e --- /dev/null +++ b/friedhof/mgrote_munin_node/tasks/install.yml @@ -0,0 +1,29 @@ +--- +- name: install packages + ansible.builtin.apt: + name: munin-node + state: present + notify: + - munin-node-configure --shell + - munin-node-configure --shell - 2 + +- name: create directories + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: root + group: root + mode: "0644" + loop: + - /etc/munin + - /etc/munin/plugin-conf.d + - /etc/munin/plugins + +- name: Copy munin-node configuration. + ansible.builtin.template: + src: munin-node.conf.j2 + dest: /etc/munin/munin-node.conf + owner: root + group: root + mode: "0644" + notify: restart munin-node diff --git a/friedhof/mgrote_munin_node/tasks/main.yml b/friedhof/mgrote_munin_node/tasks/main.yml new file mode 100644 index 00000000..688818dc --- /dev/null +++ b/friedhof/mgrote_munin_node/tasks/main.yml @@ -0,0 +1,11 @@ +--- +- name: include install-tasks + ansible.builtin.include_tasks: install.yml +- name: include user tasks + ansible.builtin.include_tasks: user.yml +- name: include plugin-tasks + ansible.builtin.include_tasks: additional.yml + when: munin_node_plugins is defined +- name: include remove-tasks + ansible.builtin.include_tasks: remove.yml + when: munin_node_disabled_plugins is defined diff --git a/friedhof/mgrote_munin_node/tasks/remove.yml b/friedhof/mgrote_munin_node/tasks/remove.yml new file mode 100644 index 00000000..18acd07e --- /dev/null +++ b/friedhof/mgrote_munin_node/tasks/remove.yml @@ -0,0 +1,16 @@ +--- +- name: remove unwanted plugins + ansible.builtin.file: + path: "{{ munin_plugin_dest_path }}{{ item.name }}" + state: absent + loop: "{{ munin_node_disabled_plugins }}" + notify: restart munin-node + when: munin_node_disabled_plugins is defined + +- name: remove additional plugin-config + ansible.builtin.file: + state: absent + dest: "{{ munin_plugin_conf_dest_path }}{{ item.name }}" + notify: restart munin-node + loop: "{{ munin_node_disabled_plugins }}" + when: munin_node_disabled_plugins is defined diff --git a/friedhof/mgrote_munin_node/tasks/user.yml b/friedhof/mgrote_munin_node/tasks/user.yml new file mode 100644 index 00000000..be0e785c --- /dev/null +++ b/friedhof/mgrote_munin_node/tasks/user.yml @@ -0,0 +1,26 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ munin_user_group }}" + state: present + +- name: ensure user exists + become: true + ansible.builtin.user: + name: munin + group: "{{ munin_user_group }}" + shell: /usr/sbin/nologin + create_home: false + +- name: add user to sudoers + become: true + ansible.builtin.blockinfile: + path: /etc/sudoers + state: present + block: | + munin ALL=(ALL) NOPASSWD:ALL + validate: '/usr/sbin/visudo -cf %s' + backup: true + marker_begin: munin-sudoers BEGIN + marker_end: munin-sudoers END diff --git a/roles/mgrote.munin-node/templates/munin-node.conf.j2 b/friedhof/mgrote_munin_node/templates/munin-node.conf.j2 similarity index 100% rename from roles/mgrote.munin-node/templates/munin-node.conf.j2 rename to friedhof/mgrote_munin_node/templates/munin-node.conf.j2 diff --git a/roles/mgrote.fail2ban/LICENSE b/friedhof/mgrote_ntp_chrony_server/LICENSE similarity index 100% rename from roles/mgrote.fail2ban/LICENSE rename to friedhof/mgrote_ntp_chrony_server/LICENSE diff --git a/roles/mgrote.ntp_chrony_server/README.md b/friedhof/mgrote_ntp_chrony_server/README.md similarity index 100% rename from roles/mgrote.ntp_chrony_server/README.md rename to friedhof/mgrote_ntp_chrony_server/README.md diff --git a/friedhof/mgrote_ntp_chrony_server/defaults/main.yml b/friedhof/mgrote_ntp_chrony_server/defaults/main.yml new file mode 100644 index 00000000..a37aa279 --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/defaults/main.yml @@ -0,0 +1,18 @@ +--- +ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet +ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile +ntp_chrony_servers: # welche Server sollen befragt werden + - address: ptbtime1.ptb.de + options: iburst #optionaler parameter + - address: ptbtime2.ptb.de + options: iburst + - address: ptbtime3.ptb.de + options: iburst + - address: time3.google.com + options: iburst + - address: ntp0.fau.de + options: iburst +ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_logging: false # logging an/aus +ntp_chrony_subnet_allow: 192.168.2.0/24 # welche Netze dürfen den Server befragen diff --git a/friedhof/mgrote_ntp_chrony_server/handlers/main.yml b/friedhof/mgrote_ntp_chrony_server/handlers/main.yml new file mode 100644 index 00000000..fac93e2f --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart_chrony + become: true + ansible.builtin.systemd: + name: chrony + enabled: true + state: restarted diff --git a/roles/mgrote.fluxcd/LICENSE b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/LICENSE similarity index 100% rename from roles/mgrote.fluxcd/LICENSE rename to friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/LICENSE diff --git a/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/README.md b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/README.md new file mode 100644 index 00000000..fe451830 --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/README.md @@ -0,0 +1,13 @@ +## mgrote.ntp_chrony_server + +### Beschreibung +Installiert chrony als ntp-server. + + +### getestet auf +- [x] Ubuntu (>=18.04) +- [ ] Debian +- [ ] ProxMox 6.1 + +### Variablen + Defaults +see [defaults](./defaults/main.yml) diff --git a/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/defaults/main.yml b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/defaults/main.yml new file mode 100644 index 00000000..a37aa279 --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/defaults/main.yml @@ -0,0 +1,18 @@ +--- +ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet +ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile +ntp_chrony_servers: # welche Server sollen befragt werden + - address: ptbtime1.ptb.de + options: iburst #optionaler parameter + - address: ptbtime2.ptb.de + options: iburst + - address: ptbtime3.ptb.de + options: iburst + - address: time3.google.com + options: iburst + - address: ntp0.fau.de + options: iburst +ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_logging: false # logging an/aus +ntp_chrony_subnet_allow: 192.168.2.0/24 # welche Netze dürfen den Server befragen diff --git a/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/handlers/main.yml b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/handlers/main.yml new file mode 100644 index 00000000..fac93e2f --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart_chrony + become: true + ansible.builtin.systemd: + name: chrony + enabled: true + state: restarted diff --git a/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/tasks/main.yml b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/tasks/main.yml new file mode 100644 index 00000000..9f0c2d49 --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/tasks/main.yml @@ -0,0 +1,59 @@ +--- +- name: mask systemd-timesyncd service + become: true + ansible.builtin.systemd: + name: systemd-timesyncd + state: stopped + masked: true + +- name: gather package facts + become: true + ansible.builtin.package_facts: + manager: auto + +- name: stop and mask ntp service + become: true + ansible.builtin.systemd: + name: ntp + masked: true + state: stopped + when: "'ntp' in ansible_facts.packages" + +- name: install chrony packages + become: true + ansible.builtin.package: + name: + - chrony + state: present + notify: restart_chrony + +- name: copy chrony config + become: true + ansible.builtin.template: + src: chrony.conf.j2 + dest: /etc/chrony/chrony.conf + mode: "0755" + notify: restart_chrony + +- name: copy logrotate config + become: true + ansible.builtin.template: + src: logrotate_chrony + dest: /etc/logrotate.d/chrony + owner: root + group: root + mode: "0644" +- name: Create chrony driftfile folder + become: true + ansible.builtin.file: + state: directory + path: "{{ ntp_chrony_driftfile_directory }}" + mode: "0755" + owner: "{{ ntp_chrony_user }}" + group: "{{ ntp_chrony_group }}" + notify: restart_chrony + +- name: set timezone to {{ ntp_chrony_timezone }} + become: true + community.general.timezone: + name: "{{ ntp_chrony_timezone }}" diff --git a/roles/mgrote.ntp_chrony_server/templates/chrony.conf.j2 b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/templates/chrony.conf.j2 similarity index 100% rename from roles/mgrote.ntp_chrony_server/templates/chrony.conf.j2 rename to friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/templates/chrony.conf.j2 diff --git a/roles/mgrote.ntp_chrony_client/templates/logrotate_chrony b/friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/templates/logrotate_chrony similarity index 100% rename from roles/mgrote.ntp_chrony_client/templates/logrotate_chrony rename to friedhof/mgrote_ntp_chrony_server/mgrote.ntp_chrony_server/templates/logrotate_chrony diff --git a/friedhof/mgrote_ntp_chrony_server/tasks/main.yml b/friedhof/mgrote_ntp_chrony_server/tasks/main.yml new file mode 100644 index 00000000..9f0c2d49 --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/tasks/main.yml @@ -0,0 +1,59 @@ +--- +- name: mask systemd-timesyncd service + become: true + ansible.builtin.systemd: + name: systemd-timesyncd + state: stopped + masked: true + +- name: gather package facts + become: true + ansible.builtin.package_facts: + manager: auto + +- name: stop and mask ntp service + become: true + ansible.builtin.systemd: + name: ntp + masked: true + state: stopped + when: "'ntp' in ansible_facts.packages" + +- name: install chrony packages + become: true + ansible.builtin.package: + name: + - chrony + state: present + notify: restart_chrony + +- name: copy chrony config + become: true + ansible.builtin.template: + src: chrony.conf.j2 + dest: /etc/chrony/chrony.conf + mode: "0755" + notify: restart_chrony + +- name: copy logrotate config + become: true + ansible.builtin.template: + src: logrotate_chrony + dest: /etc/logrotate.d/chrony + owner: root + group: root + mode: "0644" +- name: Create chrony driftfile folder + become: true + ansible.builtin.file: + state: directory + path: "{{ ntp_chrony_driftfile_directory }}" + mode: "0755" + owner: "{{ ntp_chrony_user }}" + group: "{{ ntp_chrony_group }}" + notify: restart_chrony + +- name: set timezone to {{ ntp_chrony_timezone }} + become: true + community.general.timezone: + name: "{{ ntp_chrony_timezone }}" diff --git a/friedhof/mgrote_ntp_chrony_server/templates/chrony.conf.j2 b/friedhof/mgrote_ntp_chrony_server/templates/chrony.conf.j2 new file mode 100644 index 00000000..edb61b8f --- /dev/null +++ b/friedhof/mgrote_ntp_chrony_server/templates/chrony.conf.j2 @@ -0,0 +1,32 @@ +{{ file_header | default () }} +# servers +{% for item in ntp_chrony_servers %} +server {{ item.address }} {{ item.options |default() }} +{% endfor %} + +# keys +keyfile /etc/chrony/chrony.keys + +# driftfile +driftfile {{ ntp_chrony_driftfile_directory }}/chrony.drift + + +{% if ntp_chrony_logging is sameas true %} +# Logging +log tracking measurements statistics +logdir /var/log/chrony +{% endif %} + +# Stop bad estimates upsetting machine clock. +maxupdateskew 100.0 + +# This directive enables kernel synchronisation (every 11 minutes) of the +# real-time clock. Note that it can’t be used along with the 'rtcfile' directive. +rtcsync + +# Step the system clock instead of slewing it if the adjustment is larger than +# one second, but only in the first three clock updates. +makestep 1 3 + +# chrony as ntp server +allow {{ ntp_chrony_subnet_allow }} diff --git a/roles/mgrote.ntp_chrony_server/templates/logrotate_chrony b/friedhof/mgrote_ntp_chrony_server/templates/logrotate_chrony similarity index 100% rename from roles/mgrote.ntp_chrony_server/templates/logrotate_chrony rename to friedhof/mgrote_ntp_chrony_server/templates/logrotate_chrony diff --git a/roles/mgrote.fwupd_settings/LICENSE b/friedhof/mgrote_polybar/LICENSE similarity index 100% rename from roles/mgrote.fwupd_settings/LICENSE rename to friedhof/mgrote_polybar/LICENSE diff --git a/friedhof/mgrote_polybar/defaults/main.yml b/friedhof/mgrote_polybar/defaults/main.yml new file mode 100644 index 00000000..086a34c7 --- /dev/null +++ b/friedhof/mgrote_polybar/defaults/main.yml @@ -0,0 +1,4 @@ +--- +polybar_siji_repo: https://github.com/stark/siji +polybar_siji_local: /home/mg/siji +polybar_siji_fonts_dir: /home/mg/.fonts diff --git a/roles/mgrote.i3/LICENSE b/friedhof/mgrote_polybar/mgrote.polybar/LICENSE similarity index 100% rename from roles/mgrote.i3/LICENSE rename to friedhof/mgrote_polybar/mgrote.polybar/LICENSE diff --git a/friedhof/mgrote_polybar/mgrote.polybar/defaults/main.yml b/friedhof/mgrote_polybar/mgrote.polybar/defaults/main.yml new file mode 100644 index 00000000..086a34c7 --- /dev/null +++ b/friedhof/mgrote_polybar/mgrote.polybar/defaults/main.yml @@ -0,0 +1,4 @@ +--- +polybar_siji_repo: https://github.com/stark/siji +polybar_siji_local: /home/mg/siji +polybar_siji_fonts_dir: /home/mg/.fonts diff --git a/roles/mgrote.polybar/readme.md b/friedhof/mgrote_polybar/mgrote.polybar/readme.md similarity index 100% rename from roles/mgrote.polybar/readme.md rename to friedhof/mgrote_polybar/mgrote.polybar/readme.md diff --git a/friedhof/mgrote_polybar/mgrote.polybar/tasks/main.yml b/friedhof/mgrote_polybar/mgrote.polybar/tasks/main.yml new file mode 100644 index 00000000..c8f02843 --- /dev/null +++ b/friedhof/mgrote_polybar/mgrote.polybar/tasks/main.yml @@ -0,0 +1,47 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - polybar + - lm-sensors + - brightnessctl + - inotify-tools + - yad # polybar popup-calendar + - xdotool # polybar popup-calendar + - wmctrl # für polybar windows-list # https://github.com/aroma1994/polybar-windows + state: present + +- name: checkout siji font + become: true + ansible.builtin.git: + repo: "{{ polybar_siji_repo }}" + dest: "{{ polybar_siji_local }}" + register: gitcheckout + +- name: create siji dir + become: true + ansible.builtin.file: + path: + - "{{ polybar_siji_fonts_dir }}" + state: directory + +- name: install siji-font + become: true + ansible.builtin.shell: "{{ polybar_siji_local }}/install.sh -d {{ polybar_siji_fonts_dir }}" + args: + chdir: "{{ polybar_siji_local }}" + creates: /home/mg/.fonts + when: gitcheckout.changed + +- name: remove bitmap-file + become: true + ansible.builtin.file: + path: /etc/fonts/conf.d/70-no-bitmaps.conf + state: absent + when: gitcheckout.changed + +- name: update fc-cache + become: true + ansible.builtin.shell: fc-cache + when: gitcheckout.changed diff --git a/friedhof/mgrote_polybar/readme.md b/friedhof/mgrote_polybar/readme.md new file mode 100644 index 00000000..bd81a8b4 --- /dev/null +++ b/friedhof/mgrote_polybar/readme.md @@ -0,0 +1,7 @@ +## mgrote.polybar + +### Beschreibung +installiert polybar, siji-font und setzt die rechte für das backlight. + +### Variablen + Defaults +- see [defaults](./defaults/main.yml) diff --git a/friedhof/mgrote_polybar/tasks/main.yml b/friedhof/mgrote_polybar/tasks/main.yml new file mode 100644 index 00000000..c8f02843 --- /dev/null +++ b/friedhof/mgrote_polybar/tasks/main.yml @@ -0,0 +1,47 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - polybar + - lm-sensors + - brightnessctl + - inotify-tools + - yad # polybar popup-calendar + - xdotool # polybar popup-calendar + - wmctrl # für polybar windows-list # https://github.com/aroma1994/polybar-windows + state: present + +- name: checkout siji font + become: true + ansible.builtin.git: + repo: "{{ polybar_siji_repo }}" + dest: "{{ polybar_siji_local }}" + register: gitcheckout + +- name: create siji dir + become: true + ansible.builtin.file: + path: + - "{{ polybar_siji_fonts_dir }}" + state: directory + +- name: install siji-font + become: true + ansible.builtin.shell: "{{ polybar_siji_local }}/install.sh -d {{ polybar_siji_fonts_dir }}" + args: + chdir: "{{ polybar_siji_local }}" + creates: /home/mg/.fonts + when: gitcheckout.changed + +- name: remove bitmap-file + become: true + ansible.builtin.file: + path: /etc/fonts/conf.d/70-no-bitmaps.conf + state: absent + when: gitcheckout.changed + +- name: update fc-cache + become: true + ansible.builtin.shell: fc-cache + when: gitcheckout.changed diff --git a/roles/mgrote.k8s_autocompletion/LICENSE b/friedhof/mgrote_r8152_kernel_module/LICENSE similarity index 100% rename from roles/mgrote.k8s_autocompletion/LICENSE rename to friedhof/mgrote_r8152_kernel_module/LICENSE diff --git a/roles/mgrote.r8152_kernel_module/README.md b/friedhof/mgrote_r8152_kernel_module/README.md similarity index 100% rename from roles/mgrote.r8152_kernel_module/README.md rename to friedhof/mgrote_r8152_kernel_module/README.md diff --git a/friedhof/mgrote_r8152_kernel_module/defaults/main.yml b/friedhof/mgrote_r8152_kernel_module/defaults/main.yml new file mode 100644 index 00000000..5c2b1d34 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/defaults/main.yml @@ -0,0 +1,12 @@ +--- +r8152_module_needed: false # standardmäßig falsch +r8152_packages: + - pve-headers + - build-essential + - make + - dkms +r8152_safekeeping_reboot_delay: 12 # nach wieviel minuten wird der pc neugestartet, tasks wird am ende gelöscht wenn alles erfolgreich war +# damit ist sichergestellt das der pc wieder hochfährt falls etwas passiert +r8152_src_dir: /usr/src/r8125-9.004.01 # wo wird das entpackte archiv abgelegt +r8152_filename: r8125-dkms_9.004.01.tar.gz # wie ist der dateiname auf dem ansible controller +r8152_version: 9.004.01 # wie lautet die versuin diff --git a/roles/mgrote.r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz b/friedhof/mgrote_r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz similarity index 100% rename from roles/mgrote.r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz rename to friedhof/mgrote_r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz diff --git a/friedhof/mgrote_r8152_kernel_module/meta/main.yml b/friedhof/mgrote_r8152_kernel_module/meta/main.yml new file mode 100644 index 00000000..8dd51618 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/meta/main.yml @@ -0,0 +1,3 @@ +--- +collections: + - community.general diff --git a/roles/mgrote.k8s_misc/LICENSE b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/LICENSE similarity index 100% rename from roles/mgrote.k8s_misc/LICENSE rename to friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/LICENSE diff --git a/roles/mgrote.r8152_kernel_module_on_off/README.md b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/README.md similarity index 100% rename from roles/mgrote.r8152_kernel_module_on_off/README.md rename to friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/README.md diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/defaults/main.yml b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/defaults/main.yml new file mode 100644 index 00000000..5c2b1d34 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/defaults/main.yml @@ -0,0 +1,12 @@ +--- +r8152_module_needed: false # standardmäßig falsch +r8152_packages: + - pve-headers + - build-essential + - make + - dkms +r8152_safekeeping_reboot_delay: 12 # nach wieviel minuten wird der pc neugestartet, tasks wird am ende gelöscht wenn alles erfolgreich war +# damit ist sichergestellt das der pc wieder hochfährt falls etwas passiert +r8152_src_dir: /usr/src/r8125-9.004.01 # wo wird das entpackte archiv abgelegt +r8152_filename: r8125-dkms_9.004.01.tar.gz # wie ist der dateiname auf dem ansible controller +r8152_version: 9.004.01 # wie lautet die versuin diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz new file mode 100644 index 00000000..f91b8cdb Binary files /dev/null and b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/files/r8125-dkms_9.004.01.tar.gz differ diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/meta/main.yml b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/meta/main.yml new file mode 100644 index 00000000..8dd51618 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/meta/main.yml @@ -0,0 +1,3 @@ +--- +collections: + - community.general diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/assert.yml b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/assert.yml new file mode 100644 index 00000000..be45d87f --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/assert.yml @@ -0,0 +1,20 @@ +--- +- name: check if module is installed - folder + become: true + ansible.builtin.stat: + path: "/lib/modules/r8152" + register: folder_exists + +- name: check if module is installed - lsmod + become: true + ansible.builtin.shell: lsmod + register: module_in_lsmod + changed_when: false # sorgt dafür das der Task nie als "changed" angezeigt wird + +- name: include install-tasks + ansible.builtin.include_tasks: doing.yml + when: (module_in_lsmod.stdout.find('r8152') == -1) and (folder_exists.stat.exists == false) + +- name: include dkms-tasks + ansible.builtin.include_tasks: dkms.yml + when: (module_in_lsmod.stdout.find('r8152') == -1) and (folder_exists.stat.exists == false) diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/dkms.yml b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/dkms.yml new file mode 100644 index 00000000..6d1cdce4 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/dkms.yml @@ -0,0 +1,34 @@ +--- +- name: dkms add + become: true + ansible.builtin.shell: dkms add -m r8125 -v "{{ r8152_version }}" + args: + chdir: "{{ r8152_src_dir }}" + +- name: dkms build + become: true + ansible.builtin.shell: dkms build -m r8125 -v "{{ r8152_version }}" + args: + chdir: "{{ r8152_src_dir }}" + +- name: dkms install + become: true + ansible.builtin.shell: dkms install -m r8125 -v "{{ r8152_version }}" + args: + chdir: "{{ r8152_src_dir }}" + +- name: depmod -a + become: true + ansible.builtin.shell: depmod -a + args: + chdir: "{{ r8152_src_dir }}" + +- name: update initramfs + become: true + ansible.builtin.shell: update-initramfs -u + args: + chdir: "{{ r8152_src_dir }}" + +- name: reboot + ansible.builtin.reboot: + reboot_timeout: 120 diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/doing.yml b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/doing.yml new file mode 100644 index 00000000..b7659405 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/doing.yml @@ -0,0 +1,36 @@ +--- +- name: install needed packages + become: true + ansible.builtin.package: + name: "{{ r8152_packages }}" + state: present + +- name: add reboot(for safekeeping) + become: true + ansible.builtin.shell: shutdown -r "{{ r8152_safekeeping_reboot_delay }}" + +- name: update apt cache + become: true + ansible.builtin.apt: + update_cache: true + +- name: updated installed packages + become: true + ansible.builtin.package: + upgrade: dist + +- name: create dirs + ansible.builtin.file: + path: "{{ item }}" + state: directory + loop: + - "{{ r8152_src_dir }}" + +- name: copy and extract archive + become: true + ansible.builtin.unarchive: + src: "{{ r8152_filename }}" + dest: "{{ r8152_src_dir }}" + mode: a+x + extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives + remote_src: false #datei liegt also auf dem ansible-controller diff --git a/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/main.yml b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/main.yml new file mode 100644 index 00000000..5e7a3780 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/mgrote.r8152_kernel_module/tasks/main.yml @@ -0,0 +1,4 @@ +--- +- name: include assert-tasks + ansible.builtin.include_tasks: assert.yml + when: r8152_module_needed diff --git a/friedhof/mgrote_r8152_kernel_module/tasks/assert.yml b/friedhof/mgrote_r8152_kernel_module/tasks/assert.yml new file mode 100644 index 00000000..be45d87f --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/tasks/assert.yml @@ -0,0 +1,20 @@ +--- +- name: check if module is installed - folder + become: true + ansible.builtin.stat: + path: "/lib/modules/r8152" + register: folder_exists + +- name: check if module is installed - lsmod + become: true + ansible.builtin.shell: lsmod + register: module_in_lsmod + changed_when: false # sorgt dafür das der Task nie als "changed" angezeigt wird + +- name: include install-tasks + ansible.builtin.include_tasks: doing.yml + when: (module_in_lsmod.stdout.find('r8152') == -1) and (folder_exists.stat.exists == false) + +- name: include dkms-tasks + ansible.builtin.include_tasks: dkms.yml + when: (module_in_lsmod.stdout.find('r8152') == -1) and (folder_exists.stat.exists == false) diff --git a/friedhof/mgrote_r8152_kernel_module/tasks/dkms.yml b/friedhof/mgrote_r8152_kernel_module/tasks/dkms.yml new file mode 100644 index 00000000..6d1cdce4 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/tasks/dkms.yml @@ -0,0 +1,34 @@ +--- +- name: dkms add + become: true + ansible.builtin.shell: dkms add -m r8125 -v "{{ r8152_version }}" + args: + chdir: "{{ r8152_src_dir }}" + +- name: dkms build + become: true + ansible.builtin.shell: dkms build -m r8125 -v "{{ r8152_version }}" + args: + chdir: "{{ r8152_src_dir }}" + +- name: dkms install + become: true + ansible.builtin.shell: dkms install -m r8125 -v "{{ r8152_version }}" + args: + chdir: "{{ r8152_src_dir }}" + +- name: depmod -a + become: true + ansible.builtin.shell: depmod -a + args: + chdir: "{{ r8152_src_dir }}" + +- name: update initramfs + become: true + ansible.builtin.shell: update-initramfs -u + args: + chdir: "{{ r8152_src_dir }}" + +- name: reboot + ansible.builtin.reboot: + reboot_timeout: 120 diff --git a/friedhof/mgrote_r8152_kernel_module/tasks/doing.yml b/friedhof/mgrote_r8152_kernel_module/tasks/doing.yml new file mode 100644 index 00000000..b7659405 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/tasks/doing.yml @@ -0,0 +1,36 @@ +--- +- name: install needed packages + become: true + ansible.builtin.package: + name: "{{ r8152_packages }}" + state: present + +- name: add reboot(for safekeeping) + become: true + ansible.builtin.shell: shutdown -r "{{ r8152_safekeeping_reboot_delay }}" + +- name: update apt cache + become: true + ansible.builtin.apt: + update_cache: true + +- name: updated installed packages + become: true + ansible.builtin.package: + upgrade: dist + +- name: create dirs + ansible.builtin.file: + path: "{{ item }}" + state: directory + loop: + - "{{ r8152_src_dir }}" + +- name: copy and extract archive + become: true + ansible.builtin.unarchive: + src: "{{ r8152_filename }}" + dest: "{{ r8152_src_dir }}" + mode: a+x + extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives + remote_src: false #datei liegt also auf dem ansible-controller diff --git a/friedhof/mgrote_r8152_kernel_module/tasks/main.yml b/friedhof/mgrote_r8152_kernel_module/tasks/main.yml new file mode 100644 index 00000000..5e7a3780 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module/tasks/main.yml @@ -0,0 +1,4 @@ +--- +- name: include assert-tasks + ansible.builtin.include_tasks: assert.yml + when: r8152_module_needed diff --git a/roles/mgrote.minio/LICENSE b/friedhof/mgrote_r8152_kernel_module_on_off/LICENSE similarity index 100% rename from roles/mgrote.minio/LICENSE rename to friedhof/mgrote_r8152_kernel_module_on_off/LICENSE diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/README.md b/friedhof/mgrote_r8152_kernel_module_on_off/README.md new file mode 100644 index 00000000..f3ece44c --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/README.md @@ -0,0 +1,16 @@ +## mgrote.r8152_kernel_module + +### Beschreibung +Installiert das Module r8152 für die 2.5G USB-C Ethernetkarte DN3025 von Digitus. +Startet den PC neu. + +### getestet auf +- [x] ProxMox 6.1 + +### Variablen + Defaults +see [defaults](./defaults/main.yml) + +``r8152_module_needed`` muss pro Host gesetzt werden. + +### Siehe auch + * [Link zum Treiber](https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-usb-3-0-software) diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/defaults/main.yml b/friedhof/mgrote_r8152_kernel_module_on_off/defaults/main.yml new file mode 100644 index 00000000..7a215f7e --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/defaults/main.yml @@ -0,0 +1,11 @@ +--- +r8152_filename: r8152.53.56-2.15.0 +r8152_packages: + - pve-headers + - build-essential + - make +r8152_reboot_timeout: 90 +r8152_pre_reboot_delay: 120 +r8152_post_reboot_delay: 60 +r8152_module_needed: false +r8152_safekeeping_reboot_delay: 12 diff --git a/roles/mgrote.r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 b/friedhof/mgrote_r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 similarity index 100% rename from roles/mgrote.r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 rename to friedhof/mgrote_r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/meta/main.yml b/friedhof/mgrote_r8152_kernel_module_on_off/meta/main.yml new file mode 100644 index 00000000..8dd51618 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/meta/main.yml @@ -0,0 +1,3 @@ +--- +collections: + - community.general diff --git a/roles/mgrote.motd/LICENSE b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/LICENSE similarity index 100% rename from roles/mgrote.motd/LICENSE rename to friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/LICENSE diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/README.md b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/README.md new file mode 100644 index 00000000..f3ece44c --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/README.md @@ -0,0 +1,16 @@ +## mgrote.r8152_kernel_module + +### Beschreibung +Installiert das Module r8152 für die 2.5G USB-C Ethernetkarte DN3025 von Digitus. +Startet den PC neu. + +### getestet auf +- [x] ProxMox 6.1 + +### Variablen + Defaults +see [defaults](./defaults/main.yml) + +``r8152_module_needed`` muss pro Host gesetzt werden. + +### Siehe auch + * [Link zum Treiber](https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-usb-3-0-software) diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/defaults/main.yml b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/defaults/main.yml new file mode 100644 index 00000000..7a215f7e --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/defaults/main.yml @@ -0,0 +1,11 @@ +--- +r8152_filename: r8152.53.56-2.15.0 +r8152_packages: + - pve-headers + - build-essential + - make +r8152_reboot_timeout: 90 +r8152_pre_reboot_delay: 120 +r8152_post_reboot_delay: 60 +r8152_module_needed: false +r8152_safekeeping_reboot_delay: 12 diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 new file mode 100644 index 00000000..6a85f32a Binary files /dev/null and b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/files/r8152.53.56-2.15.0.tar.bz2 differ diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/meta/main.yml b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/meta/main.yml new file mode 100644 index 00000000..8dd51618 --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/meta/main.yml @@ -0,0 +1,3 @@ +--- +collections: + - community.general diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/tasks/doing.yml b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/tasks/doing.yml new file mode 100644 index 00000000..3163163e --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/tasks/doing.yml @@ -0,0 +1,83 @@ +--- +- name: install needed packages + become: true + ansible.builtin.package: + name: "{{ r8152_packages }}" + state: present + register: aptp + + +- name: add reboot(for safekeeping) + become: true + ansible.builtin.shell: shutdown -r "{{ r8152_safekeeping_reboot_delay }}" + +- name: update apt cache + become: true + ansible.builtin.apt: + update_cache: true + register: aptc + +- name: updated installed packages + become: true + ansible.builtin.package: + upgrade: dist + register: apti + +- name: reboot - 1 + ansible.builtin.reboot: + reboot_timeout: "{{ r8152_reboot_timeout }}" + pre_reboot_delay: "{{ r8152_reboot_timeout }}" + post_reboot_delay: "{{ r8152_post_reboot_delay }}" + when: + - aptp.changed + - apti.changed + - aptc.changed + +- name: create dirs + ansible.builtin.file: + path: "{{ item }}" + state: directory + loop: + - "/tmp/r8152/" + - "/lib/modules/r8152/{{ r8152_filename }}" + +- name: copy archive + become: true + ansible.builtin.copy: + src: "files/{{ r8152_filename }}.tar.bz2" + dest: "/tmp/r8152/{{ r8152_filename }}.tar.bz2" + mode: '0775' + +- name: extract archive + become: true + ansible.builtin.unarchive: + src: "/tmp/r8152/{{ r8152_filename }}.tar.bz2" + dest: "/lib/modules/r8152/{{ r8152_filename }}" + mode: a+x + extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives + remote_src: true #datei liegt also auf dem zielsystem + +- name: make + community.general.make: + chdir: "/lib/modules/r8152/{{ r8152_filename }}" + become: true + +- name: make install + community.general.make: + chdir: "/lib/modules/r8152/{{ r8152_filename }}" + target: install + become: true + +- name: depmod -a + become: true + ansible.builtin.shell: depmod -a + +- name: reboot - 2 + ansible.builtin.reboot: + reboot_timeout: "{{ r8152_reboot_timeout }}" + pre_reboot_delay: "{{ r8152_reboot_timeout }}" + post_reboot_delay: "{{ r8152_post_reboot_delay }}" + +- name: cancel reboot(for safekeeping) + become: true + ansible.builtin.shell: shutdown -c diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/tasks/main.yml b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/tasks/main.yml new file mode 100644 index 00000000..0a26caed --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/mgrote.r8152_kernel_module_on_off/tasks/main.yml @@ -0,0 +1,16 @@ +--- +- name: check if module is installed - folder + become: true + ansible.builtin.stat: + path: "/lib/modules/r8152/{{ r8152_filename }}" + register: folder_exists + +- name: check if module is installed - lsmod + become: true + ansible.builtin.shell: lsmod + register: module_in_lsmod + changed_when: false # sorgt dafür das der Task nie als "changed" angezeigt wird + +- name: include tasks (task get skipped if the folder or the module exists or r8152_module_needed == false) + ansible.builtin.include_tasks: doing.yml + when: ((folder_exists.stat.exists == False) or (module_in_lsmod.stdout.find('r8152') == -1)) and (r8152_module_needed) diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/tasks/doing.yml b/friedhof/mgrote_r8152_kernel_module_on_off/tasks/doing.yml new file mode 100644 index 00000000..3163163e --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/tasks/doing.yml @@ -0,0 +1,83 @@ +--- +- name: install needed packages + become: true + ansible.builtin.package: + name: "{{ r8152_packages }}" + state: present + register: aptp + + +- name: add reboot(for safekeeping) + become: true + ansible.builtin.shell: shutdown -r "{{ r8152_safekeeping_reboot_delay }}" + +- name: update apt cache + become: true + ansible.builtin.apt: + update_cache: true + register: aptc + +- name: updated installed packages + become: true + ansible.builtin.package: + upgrade: dist + register: apti + +- name: reboot - 1 + ansible.builtin.reboot: + reboot_timeout: "{{ r8152_reboot_timeout }}" + pre_reboot_delay: "{{ r8152_reboot_timeout }}" + post_reboot_delay: "{{ r8152_post_reboot_delay }}" + when: + - aptp.changed + - apti.changed + - aptc.changed + +- name: create dirs + ansible.builtin.file: + path: "{{ item }}" + state: directory + loop: + - "/tmp/r8152/" + - "/lib/modules/r8152/{{ r8152_filename }}" + +- name: copy archive + become: true + ansible.builtin.copy: + src: "files/{{ r8152_filename }}.tar.bz2" + dest: "/tmp/r8152/{{ r8152_filename }}.tar.bz2" + mode: '0775' + +- name: extract archive + become: true + ansible.builtin.unarchive: + src: "/tmp/r8152/{{ r8152_filename }}.tar.bz2" + dest: "/lib/modules/r8152/{{ r8152_filename }}" + mode: a+x + extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives + remote_src: true #datei liegt also auf dem zielsystem + +- name: make + community.general.make: + chdir: "/lib/modules/r8152/{{ r8152_filename }}" + become: true + +- name: make install + community.general.make: + chdir: "/lib/modules/r8152/{{ r8152_filename }}" + target: install + become: true + +- name: depmod -a + become: true + ansible.builtin.shell: depmod -a + +- name: reboot - 2 + ansible.builtin.reboot: + reboot_timeout: "{{ r8152_reboot_timeout }}" + pre_reboot_delay: "{{ r8152_reboot_timeout }}" + post_reboot_delay: "{{ r8152_post_reboot_delay }}" + +- name: cancel reboot(for safekeeping) + become: true + ansible.builtin.shell: shutdown -c diff --git a/friedhof/mgrote_r8152_kernel_module_on_off/tasks/main.yml b/friedhof/mgrote_r8152_kernel_module_on_off/tasks/main.yml new file mode 100644 index 00000000..0a26caed --- /dev/null +++ b/friedhof/mgrote_r8152_kernel_module_on_off/tasks/main.yml @@ -0,0 +1,16 @@ +--- +- name: check if module is installed - folder + become: true + ansible.builtin.stat: + path: "/lib/modules/r8152/{{ r8152_filename }}" + register: folder_exists + +- name: check if module is installed - lsmod + become: true + ansible.builtin.shell: lsmod + register: module_in_lsmod + changed_when: false # sorgt dafür das der Task nie als "changed" angezeigt wird + +- name: include tasks (task get skipped if the folder or the module exists or r8152_module_needed == false) + ansible.builtin.include_tasks: doing.yml + when: ((folder_exists.stat.exists == False) or (module_in_lsmod.stdout.find('r8152') == -1)) and (r8152_module_needed) diff --git a/roles/mgrote.mount_cifs/LICENSE b/friedhof/mgrote_supermicro_fan_control/LICENSE similarity index 100% rename from roles/mgrote.mount_cifs/LICENSE rename to friedhof/mgrote_supermicro_fan_control/LICENSE diff --git a/roles/mgrote.supermicro_fan_control/README.md b/friedhof/mgrote_supermicro_fan_control/README.md similarity index 100% rename from roles/mgrote.supermicro_fan_control/README.md rename to friedhof/mgrote_supermicro_fan_control/README.md diff --git a/friedhof/mgrote_supermicro_fan_control/handlers/main.yml b/friedhof/mgrote_supermicro_fan_control/handlers/main.yml new file mode 100644 index 00000000..176ba46f --- /dev/null +++ b/friedhof/mgrote_supermicro_fan_control/handlers/main.yml @@ -0,0 +1,25 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true + +- name: systemctl enable units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + enabled: true + masked: false + with_items: + - sm_fan_control.service + - sm_fan_control.timer + +- name: systemctl start units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + state: restarted + enabled: true + with_items: + - sm_fan_control.timer + notify: systemctl daemon-reload diff --git a/roles/mgrote.munin-node/LICENSE b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/LICENSE similarity index 100% rename from roles/mgrote.munin-node/LICENSE rename to friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/LICENSE diff --git a/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/README.md b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/README.md new file mode 100644 index 00000000..b52dd8f3 --- /dev/null +++ b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/README.md @@ -0,0 +1,25 @@ +## mgrote.supermicro_fan_control + +### Beschreibung +Setzt den Fan-Mode auf "Standard". +Setzt die Grenzwerte fur die Lüfterdrehzahlen passend für "beQuiet PureWings 2 140mm" + +### getestet auf +- [X] ProxMox 7* + + +### Sonstiges +Setze Fan Speed für "CPU" auf 25%: `ipmitool raw 0x30 0x70 0x66 0x01 0x01 0x16` +Setze Fan Speed für "Case" 50%: `ipmitool raw 0x30 0x70 0x66 0x01 0x00 0x32` +Setze Fan-Threshold: `ipmitool sensor thresh "FAN5" lower 100 200 300` + + + Locating sensor record 'FAN5'... + Setting sensor "FAN5" Lower Non-Recoverable threshold to 100.000 + Setting sensor "FAN5" Lower Critical threshold to 200.000 + Setting sensor "FAN5" Lower Non-Critical threshold to 300.000 + + +### Quellen +* https://forums.servethehome.com/index.php?resources/supermicro-x9-x10-x11-fan-speed-control.20/ +* https://www.truenas.com/community/resources/how-to-change-ipmi-sensor-thresholds-using-ipmitool.35/ diff --git a/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/handlers/main.yml b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/handlers/main.yml new file mode 100644 index 00000000..176ba46f --- /dev/null +++ b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/handlers/main.yml @@ -0,0 +1,25 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true + +- name: systemctl enable units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + enabled: true + masked: false + with_items: + - sm_fan_control.service + - sm_fan_control.timer + +- name: systemctl start units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + state: restarted + enabled: true + with_items: + - sm_fan_control.timer + notify: systemctl daemon-reload diff --git a/roles/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png similarity index 100% rename from roles/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png rename to friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png diff --git a/roles/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png similarity index 100% rename from roles/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png rename to friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png diff --git a/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/tasks/main.yml b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/tasks/main.yml new file mode 100644 index 00000000..1a908615 --- /dev/null +++ b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/tasks/main.yml @@ -0,0 +1,36 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - ipmitool + state: present + +- name: template sm_fan_control.service + become: true + ansible.builtin.template: + src: sm_fan_control.service.j2 + dest: /etc/systemd/system/sm_fan_control.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: template sm_fan_control.timer + become: true + ansible.builtin.template: + src: sm_fan_control.timer.j2 + dest: /etc/systemd/system/sm_fan_control.timer + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: systemctl start sm_fan_control.timer + become: true + ansible.builtin.systemd: + name: sm_fan_control.timer + state: started + enabled: true diff --git a/roles/mgrote.supermicro_fan_control/templates/sm_fan_control.service.j2 b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/templates/sm_fan_control.service.j2 similarity index 100% rename from roles/mgrote.supermicro_fan_control/templates/sm_fan_control.service.j2 rename to friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/templates/sm_fan_control.service.j2 diff --git a/roles/mgrote.supermicro_fan_control/templates/sm_fan_control.timer.j2 b/friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/templates/sm_fan_control.timer.j2 similarity index 100% rename from roles/mgrote.supermicro_fan_control/templates/sm_fan_control.timer.j2 rename to friedhof/mgrote_supermicro_fan_control/mgrote.supermicro_fan_control/templates/sm_fan_control.timer.j2 diff --git a/friedhof/mgrote_supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png b/friedhof/mgrote_supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png new file mode 100644 index 00000000..e85b1446 Binary files /dev/null and b/friedhof/mgrote_supermicro_fan_control/screenshots/2022-03-27 13_19_36-Reference Material - Supermicro X9_X10_X11 Fan Speed Control _ ServeTheHome Foru.png differ diff --git a/friedhof/mgrote_supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png b/friedhof/mgrote_supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png new file mode 100644 index 00000000..f0038572 Binary files /dev/null and b/friedhof/mgrote_supermicro_fan_control/screenshots/2022-03-27 13_20_11-default_1_ansible2.grote.lan - _default_1_bash - _pve2_ _.png differ diff --git a/friedhof/mgrote_supermicro_fan_control/tasks/main.yml b/friedhof/mgrote_supermicro_fan_control/tasks/main.yml new file mode 100644 index 00000000..1a908615 --- /dev/null +++ b/friedhof/mgrote_supermicro_fan_control/tasks/main.yml @@ -0,0 +1,36 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - ipmitool + state: present + +- name: template sm_fan_control.service + become: true + ansible.builtin.template: + src: sm_fan_control.service.j2 + dest: /etc/systemd/system/sm_fan_control.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: template sm_fan_control.timer + become: true + ansible.builtin.template: + src: sm_fan_control.timer.j2 + dest: /etc/systemd/system/sm_fan_control.timer + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: systemctl start sm_fan_control.timer + become: true + ansible.builtin.systemd: + name: sm_fan_control.timer + state: started + enabled: true diff --git a/friedhof/mgrote_supermicro_fan_control/templates/sm_fan_control.service.j2 b/friedhof/mgrote_supermicro_fan_control/templates/sm_fan_control.service.j2 new file mode 100644 index 00000000..16bd1b9c --- /dev/null +++ b/friedhof/mgrote_supermicro_fan_control/templates/sm_fan_control.service.j2 @@ -0,0 +1,17 @@ +{{ file_header | default () }} +[Unit] +Description=Set the fan threshold on Supermicro X9/10/11 Mainboards. +After=multi-user.target + +[Service] +Type=oneshot +# Setze auf "Fan Mode: Standard" +ExecStart=/usr/bin/ipmitool raw 0x30 0x45 0x01 +# Setze Grenzwerte Zone "Case" +ExecStart=/usr/bin/ipmitool sensor thresh "FAN1" lower 100 200 300 +ExecStart=/usr/bin/ipmitool sensor thresh "FAN2" lower 100 200 300 +ExecStart=/usr/bin/ipmitool sensor thresh "FAN3" lower 100 200 300 +ExecStart=/usr/bin/ipmitool sensor thresh "FAN4" lower 100 200 300 +ExecStart=/usr/bin/ipmitool sensor thresh "FAN5" lower 100 200 300 +# Setze Grenzwerte Zone "CPU" +ExecStart=/usr/bin/ipmitool sensor thresh "FANA" lower 100 200 300 diff --git a/roles/_mgrote.musterrolle_systemd/templates/rclone.timer.j2 b/friedhof/mgrote_supermicro_fan_control/templates/sm_fan_control.timer.j2 similarity index 51% rename from roles/_mgrote.musterrolle_systemd/templates/rclone.timer.j2 rename to friedhof/mgrote_supermicro_fan_control/templates/sm_fan_control.timer.j2 index fa2ba12a..ed00d467 100644 --- a/roles/_mgrote.musterrolle_systemd/templates/rclone.timer.j2 +++ b/friedhof/mgrote_supermicro_fan_control/templates/sm_fan_control.timer.j2 @@ -1,10 +1,9 @@ {{ file_header | default () }} [Unit] -Description=Timer for rclone syncs. +Description=Timer: Sets the fan threshold on Supermicro X9/10/11 Mainboards. [Timer] -OnCalendar={{ item.timer }} -RandomizedDelaySec=30 min +OnBootSec=1min [Install] WantedBy=timers.target multi-user.target diff --git a/roles/mgrote.ntp_chrony_client/LICENSE b/friedhof/mgrote_systemd_timesyncd/LICENSE similarity index 100% rename from roles/mgrote.ntp_chrony_client/LICENSE rename to friedhof/mgrote_systemd_timesyncd/LICENSE diff --git a/roles/mgrote.systemd-timesyncd/README.md b/friedhof/mgrote_systemd_timesyncd/README.md similarity index 100% rename from roles/mgrote.systemd-timesyncd/README.md rename to friedhof/mgrote_systemd_timesyncd/README.md diff --git a/friedhof/mgrote_systemd_timesyncd/defaults/main.yml b/friedhof/mgrote_systemd_timesyncd/defaults/main.yml new file mode 100644 index 00000000..aea4272a --- /dev/null +++ b/friedhof/mgrote_systemd_timesyncd/defaults/main.yml @@ -0,0 +1,4 @@ +--- +ntp_timesyncd_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet +ntp_timesyncd_servers: # welche Server sollen befragt werden + - ptbtime1.ptb.de diff --git a/friedhof/mgrote_systemd_timesyncd/handlers/main.yml b/friedhof/mgrote_systemd_timesyncd/handlers/main.yml new file mode 100644 index 00000000..6e3a9968 --- /dev/null +++ b/friedhof/mgrote_systemd_timesyncd/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart systemd-timesyncd.service + become: true + ansible.builtin.systemd: + name: systemd-timesyncd + state: restarted + when: not ansible_facts['virtualization_type'] == "lxc" diff --git a/friedhof/mgrote_systemd_timesyncd/tasks/main.yml b/friedhof/mgrote_systemd_timesyncd/tasks/main.yml new file mode 100644 index 00000000..4b827d7c --- /dev/null +++ b/friedhof/mgrote_systemd_timesyncd/tasks/main.yml @@ -0,0 +1,56 @@ +--- +- name: gather package facts + become: true + ansible.builtin.package_facts: + manager: auto + +# deaktiviere andere ntp-implementationen +- name: stop and mask ntp service + become: true + ansible.builtin.systemd: + name: ntp + masked: true + state: stopped + enabled: false + when: "'ntp' in ansible_facts.packages" + +- name: stop and mask chrony service + become: true + ansible.builtin.systemd: + name: chrony + masked: true + state: stopped + enabled: false + when: "'chrony' in ansible_facts.packages" + +- name: install systemd-timesyncd + become: true + ansible.builtin.package: + name: + - systemd-timesyncd + state: present + +- name: template systemd-timesyncd config + become: true + ansible.builtin.template: + src: "timesyncd.conf.j2" + dest: "/etc/systemd/timesyncd.conf" + mode: "0644" + owner: root + group: root + notify: restart systemd-timesyncd.service + +- name: activate systemd-timesyncd service (not within containers like lxc) + become: true + ansible.builtin.systemd: + name: systemd-timesyncd + masked: false + state: started + enabled: true + when: not ansible_facts['virtualization_type'] == "lxc" + tags: test + +- name: set timezone to {{ ntp_timesyncd_timezone }} + become: true + community.general.timezone: + name: "{{ ntp_timesyncd_timezone }}" diff --git a/roles/mgrote.systemd-timesyncd/templates/timesyncd.conf.j2 b/friedhof/mgrote_systemd_timesyncd/templates/timesyncd.conf.j2 similarity index 100% rename from roles/mgrote.systemd-timesyncd/templates/timesyncd.conf.j2 rename to friedhof/mgrote_systemd_timesyncd/templates/timesyncd.conf.j2 diff --git a/roles/mgrote.ntp_chrony_server/LICENSE b/friedhof/mgrote_timeshift/LICENSE similarity index 100% rename from roles/mgrote.ntp_chrony_server/LICENSE rename to friedhof/mgrote_timeshift/LICENSE diff --git a/roles/mgrote.timeshift/README.md b/friedhof/mgrote_timeshift/README.md similarity index 100% rename from roles/mgrote.timeshift/README.md rename to friedhof/mgrote_timeshift/README.md diff --git a/friedhof/mgrote_timeshift/handlers/main.yml b/friedhof/mgrote_timeshift/handlers/main.yml new file mode 100644 index 00000000..dced8ff2 --- /dev/null +++ b/friedhof/mgrote_timeshift/handlers/main.yml @@ -0,0 +1,4 @@ +--- +- name: create snapshot + become: true + ansible.builtin.shell: "/usr/bin/timeshift --scripted --create" diff --git a/roles/mgrote.pbs_datastores/LICENSE b/friedhof/mgrote_timeshift/mgrote.timeshift/LICENSE similarity index 100% rename from roles/mgrote.pbs_datastores/LICENSE rename to friedhof/mgrote_timeshift/mgrote.timeshift/LICENSE diff --git a/friedhof/mgrote_timeshift/mgrote.timeshift/README.md b/friedhof/mgrote_timeshift/mgrote.timeshift/README.md new file mode 100644 index 00000000..63d99e9a --- /dev/null +++ b/friedhof/mgrote_timeshift/mgrote.timeshift/README.md @@ -0,0 +1,10 @@ +## mgrote.timeshift + +### Beschreibung +Installiert und konfiguriert timeshift. + +### getestet auf +- [X] Ubuntu (>=18.04) + +### Variablen + Defaults +see [defaults](./defaults/main.yml) diff --git a/friedhof/mgrote_timeshift/mgrote.timeshift/handlers/main.yml b/friedhof/mgrote_timeshift/mgrote.timeshift/handlers/main.yml new file mode 100644 index 00000000..dced8ff2 --- /dev/null +++ b/friedhof/mgrote_timeshift/mgrote.timeshift/handlers/main.yml @@ -0,0 +1,4 @@ +--- +- name: create snapshot + become: true + ansible.builtin.shell: "/usr/bin/timeshift --scripted --create" diff --git a/friedhof/mgrote_timeshift/mgrote.timeshift/tasks/main.yml b/friedhof/mgrote_timeshift/mgrote.timeshift/tasks/main.yml new file mode 100644 index 00000000..2663b394 --- /dev/null +++ b/friedhof/mgrote_timeshift/mgrote.timeshift/tasks/main.yml @@ -0,0 +1,23 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - timeshift + state: present + notify: create snapshot + +- name: copy timeshift config + become: true + ansible.builtin.template: + src: "timeshift.json" + dest: "/etc/timeshift/timeshift.json" + +- name: create timeshift cronjob + become: true + ansible.builtin.cron: + name: restic + state: present + job: "/usr/bin/timeshift --scripted --create" + minute: "7" + hour: "*/4" diff --git a/roles/mgrote.timeshift/templates/timeshift.json b/friedhof/mgrote_timeshift/mgrote.timeshift/templates/timeshift.json similarity index 100% rename from roles/mgrote.timeshift/templates/timeshift.json rename to friedhof/mgrote_timeshift/mgrote.timeshift/templates/timeshift.json diff --git a/friedhof/mgrote_timeshift/tasks/main.yml b/friedhof/mgrote_timeshift/tasks/main.yml new file mode 100644 index 00000000..2663b394 --- /dev/null +++ b/friedhof/mgrote_timeshift/tasks/main.yml @@ -0,0 +1,23 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - timeshift + state: present + notify: create snapshot + +- name: copy timeshift config + become: true + ansible.builtin.template: + src: "timeshift.json" + dest: "/etc/timeshift/timeshift.json" + +- name: create timeshift cronjob + become: true + ansible.builtin.cron: + name: restic + state: present + job: "/usr/bin/timeshift --scripted --create" + minute: "7" + hour: "*/4" diff --git a/friedhof/mgrote_timeshift/templates/timeshift.json b/friedhof/mgrote_timeshift/templates/timeshift.json new file mode 100644 index 00000000..af2fd8ab --- /dev/null +++ b/friedhof/mgrote_timeshift/templates/timeshift.json @@ -0,0 +1,31 @@ +{{ file_header | default () }} +{ + "backup_device_uuid" : "9b924961-0fd4-423f-b440-f2f3d1fa46d8", + "parent_device_uuid" : "", + "do_first_run" : "false", + "btrfs_mode" : "false", + "include_btrfs_home_for_backup" : "false", + "include_btrfs_home_for_restore" : "false", + "stop_cron_emails" : "false", + "btrfs_use_qgroup" : "false", + "schedule_monthly" : "false", + "schedule_weekly" : "false", + "schedule_daily" : "false", + "schedule_hourly" : "false", + "schedule_boot" : "false", + "count_monthly" : "2", + "count_weekly" : "3", + "count_daily" : "7", + "count_hourly" : "6", + "count_boot" : "5", + "snapshot_size" : "7515627384", + "snapshot_count" : "254372", + "date_format" : "%Y-%m-%d %H:%M:%S", + "exclude" : [ + "/root/**", + "/home/polybar/**", + "/home/ansible-user/**", + "/home/mg/**" + ], + "exclude-apps" : [] +} diff --git a/roles/mgrote.pbs_pve_integration/LICENSE b/friedhof/mgrote_tor_node/LICENSE similarity index 100% rename from roles/mgrote.pbs_pve_integration/LICENSE rename to friedhof/mgrote_tor_node/LICENSE diff --git a/roles/mgrote.tor-node/README.md b/friedhof/mgrote_tor_node/README.md similarity index 100% rename from roles/mgrote.tor-node/README.md rename to friedhof/mgrote_tor_node/README.md diff --git a/friedhof/mgrote_tor_node/defaults/main.yml b/friedhof/mgrote_tor_node/defaults/main.yml new file mode 100644 index 00000000..f02f40c7 --- /dev/null +++ b/friedhof/mgrote_tor_node/defaults/main.yml @@ -0,0 +1,18 @@ +--- +# required +# [a-zA-Z0-9] +tor_relay_name: tor1name +tor_or_port: 443 +tor_socks_port: 0 +tor_control_socket: 0 +tor_contact_info: webmaster@domain.local +tor_control_port: 9051 +# optional +# tor_my_family: name +# tor_bandwidth_rate: +# tor_bandwidth_burst: +tor_mode: relay # OR bridge +tor_bridge_port: 5555 + +# use IPv6 +tor_ipv6: false diff --git a/friedhof/mgrote_tor_node/handlers/main.yml b/friedhof/mgrote_tor_node/handlers/main.yml new file mode 100644 index 00000000..44896b18 --- /dev/null +++ b/friedhof/mgrote_tor_node/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart tor + become: true + ansible.builtin.systemd: + name: tor + enabled: true + state: restarted diff --git a/friedhof/mgrote_tor_node/tasks/bridge.yml b/friedhof/mgrote_tor_node/tasks/bridge.yml new file mode 100644 index 00000000..bea1d5ed --- /dev/null +++ b/friedhof/mgrote_tor_node/tasks/bridge.yml @@ -0,0 +1,15 @@ +--- +- name: install obsf packages + become: true + ansible.builtin.package: + name: + - obfs4proxy + state: present + notify: restart tor + +- name: templating torrc + become: true + ansible.builtin.template: + src: "bridge_torrc" + dest: "/etc/tor/torrc" + notify: restart tor diff --git a/friedhof/mgrote_tor_node/tasks/main.yml b/friedhof/mgrote_tor_node/tasks/main.yml new file mode 100644 index 00000000..77a3a3df --- /dev/null +++ b/friedhof/mgrote_tor_node/tasks/main.yml @@ -0,0 +1,39 @@ +--- +- name: install dependencies + become: true + ansible.builtin.package: + name: apt-transport-https + state: present + +- name: add tor repo key + ansible.builtin.apt_key: + url: https://deb.torproject.org/torproject.org/A3C4F0F979CAA22CDBA8F512EE8CBC9E886DDD89.asc + state: present + +- name: add tor repo + ansible.builtin.apt_repository: + repo: deb https://deb.torproject.org/torproject.org {{ ansible_distribution_release }} main + state: present + filename: tor + +- name: install tor packages + become: true + ansible.builtin.package: + name: + - tor + - deb.torproject.org-keyring + state: present + notify: restart tor + +- name: include bridge tasks + ansible.builtin.include_tasks: bridge.yml + when: + - tor_mode == 'bridge' + +- name: include relay tasks + ansible.builtin.include_tasks: relay.yml + when: + - tor_mode == 'relay' + +- name: include nyx tasks + ansible.builtin.include_tasks: nyx.yml diff --git a/friedhof/mgrote_tor_node/tasks/nyx.yml b/friedhof/mgrote_tor_node/tasks/nyx.yml new file mode 100644 index 00000000..ea4b33cf --- /dev/null +++ b/friedhof/mgrote_tor_node/tasks/nyx.yml @@ -0,0 +1,8 @@ +--- +- name: install nyx packages + become: true + ansible.builtin.package: + name: + - nyx + state: present + notify: restart tor diff --git a/friedhof/mgrote_tor_node/tasks/relay.yml b/friedhof/mgrote_tor_node/tasks/relay.yml new file mode 100644 index 00000000..e688c672 --- /dev/null +++ b/friedhof/mgrote_tor_node/tasks/relay.yml @@ -0,0 +1,7 @@ +--- +- name: templating torrc + become: true + ansible.builtin.template: + src: "relay_torrc" + dest: "/etc/tor/torrc" + notify: restart tor diff --git a/roles/mgrote.tor-node/templates/bridge_torrc b/friedhof/mgrote_tor_node/templates/bridge_torrc similarity index 100% rename from roles/mgrote.tor-node/templates/bridge_torrc rename to friedhof/mgrote_tor_node/templates/bridge_torrc diff --git a/roles/mgrote.tor-node/templates/relay_torrc b/friedhof/mgrote_tor_node/templates/relay_torrc similarity index 100% rename from roles/mgrote.tor-node/templates/relay_torrc rename to friedhof/mgrote_tor_node/templates/relay_torrc diff --git a/roles/mgrote.pbs_users/LICENSE b/friedhof/mgrote_xnview/LICENSE similarity index 100% rename from roles/mgrote.pbs_users/LICENSE rename to friedhof/mgrote_xnview/LICENSE diff --git a/roles/mgrote.xnview/README.md b/friedhof/mgrote_xnview/README.md similarity index 100% rename from roles/mgrote.xnview/README.md rename to friedhof/mgrote_xnview/README.md diff --git a/friedhof/mgrote_xnview/defaults/main.yml b/friedhof/mgrote_xnview/defaults/main.yml new file mode 100644 index 00000000..3ba6a4e6 --- /dev/null +++ b/friedhof/mgrote_xnview/defaults/main.yml @@ -0,0 +1,2 @@ +--- +xnview_deb_url: https://download.xnview.com/XnViewMP-linux-x64.deb diff --git a/roles/mgrote.polybar/LICENSE b/friedhof/mgrote_xnview/mgrote.xnview/LICENSE similarity index 100% rename from roles/mgrote.polybar/LICENSE rename to friedhof/mgrote_xnview/mgrote.xnview/LICENSE diff --git a/friedhof/mgrote_xnview/mgrote.xnview/README.md b/friedhof/mgrote_xnview/mgrote.xnview/README.md new file mode 100644 index 00000000..7debfdd9 --- /dev/null +++ b/friedhof/mgrote_xnview/mgrote.xnview/README.md @@ -0,0 +1,8 @@ +## mgrote.xnview +### Beschreibung +Installiert xnview. + + +### getestet auf +- [x] Ubuntu (>=18.04) +- [x] Linux Mint diff --git a/friedhof/mgrote_xnview/mgrote.xnview/defaults/main.yml b/friedhof/mgrote_xnview/mgrote.xnview/defaults/main.yml new file mode 100644 index 00000000..3ba6a4e6 --- /dev/null +++ b/friedhof/mgrote_xnview/mgrote.xnview/defaults/main.yml @@ -0,0 +1,2 @@ +--- +xnview_deb_url: https://download.xnview.com/XnViewMP-linux-x64.deb diff --git a/friedhof/mgrote_xnview/mgrote.xnview/tasks/main.yml b/friedhof/mgrote_xnview/mgrote.xnview/tasks/main.yml new file mode 100644 index 00000000..595e0b50 --- /dev/null +++ b/friedhof/mgrote_xnview/mgrote.xnview/tasks/main.yml @@ -0,0 +1,5 @@ +--- +- name: download and install xnview + become: true + ansible.builtin.apt: + deb: "{{ xnview_deb_url }}" diff --git a/friedhof/mgrote_xnview/tasks/main.yml b/friedhof/mgrote_xnview/tasks/main.yml new file mode 100644 index 00000000..595e0b50 --- /dev/null +++ b/friedhof/mgrote_xnview/tasks/main.yml @@ -0,0 +1,5 @@ +--- +- name: download and install xnview + become: true + ansible.builtin.apt: + deb: "{{ xnview_deb_url }}" diff --git a/roles/mgrote.postfix/LICENSE b/friedhof/mgrote_xrdp/LICENSE similarity index 100% rename from roles/mgrote.postfix/LICENSE rename to friedhof/mgrote_xrdp/LICENSE diff --git a/roles/mgrote.xrdp/README.md b/friedhof/mgrote_xrdp/README.md similarity index 100% rename from roles/mgrote.xrdp/README.md rename to friedhof/mgrote_xrdp/README.md diff --git a/roles/mgrote.proxmox_bind_mounts/LICENSE b/friedhof/mgrote_xrdp/mgrote.xrdp/LICENSE similarity index 100% rename from roles/mgrote.proxmox_bind_mounts/LICENSE rename to friedhof/mgrote_xrdp/mgrote.xrdp/LICENSE diff --git a/friedhof/mgrote_xrdp/mgrote.xrdp/README.md b/friedhof/mgrote_xrdp/mgrote.xrdp/README.md new file mode 100644 index 00000000..ba582fa2 --- /dev/null +++ b/friedhof/mgrote_xrdp/mgrote.xrdp/README.md @@ -0,0 +1,11 @@ +## mgrote.xrdp +### Beschreibung +Installiert xrdp. + +### getestet auf +- [ ] Ubuntu (>=18.04) +- [x] Linux Mint + + +### Variablen +`xrdp_user` - user whos session-config gets created(default: `mg`) diff --git a/friedhof/mgrote_xrdp/mgrote.xrdp/tasks/main.yml b/friedhof/mgrote_xrdp/mgrote.xrdp/tasks/main.yml new file mode 100644 index 00000000..b4a65176 --- /dev/null +++ b/friedhof/mgrote_xrdp/mgrote.xrdp/tasks/main.yml @@ -0,0 +1,24 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - xrdp + - xorgxrdp + state: present + +- name: create xsession config file + become: true + ansible.builtin.file: + path: "/home/{{ xrdp_user | default('mg') }}/.xsession" + state: touch + owner: "{{ xrdp_user | default('mg') }}" + modification_time: preserve + access_time: preserve + +- name: set xsession config + become: true + ansible.builtin.blockinfile: + path: "/home/{{ xrdp_user | default('mg') }}/.xsession" + block: | + env -u SESSION_MANAGER -u DBUS_SESSION_BUS_ADDRESS cinnamon-session diff --git a/friedhof/mgrote_xrdp/tasks/main.yml b/friedhof/mgrote_xrdp/tasks/main.yml new file mode 100644 index 00000000..b4a65176 --- /dev/null +++ b/friedhof/mgrote_xrdp/tasks/main.yml @@ -0,0 +1,24 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - xrdp + - xorgxrdp + state: present + +- name: create xsession config file + become: true + ansible.builtin.file: + path: "/home/{{ xrdp_user | default('mg') }}/.xsession" + state: touch + owner: "{{ xrdp_user | default('mg') }}" + modification_time: preserve + access_time: preserve + +- name: set xsession config + become: true + ansible.builtin.blockinfile: + path: "/home/{{ xrdp_user | default('mg') }}/.xsession" + block: | + env -u SESSION_MANAGER -u DBUS_SESSION_BUS_ADDRESS cinnamon-session diff --git a/roles/mgrote.proxmox_lxc_profiles/LICENSE b/friedhof/mgrote_zswap/LICENSE similarity index 100% rename from roles/mgrote.proxmox_lxc_profiles/LICENSE rename to friedhof/mgrote_zswap/LICENSE diff --git a/roles/mgrote.zswap/README.md b/friedhof/mgrote_zswap/README.md similarity index 100% rename from roles/mgrote.zswap/README.md rename to friedhof/mgrote_zswap/README.md diff --git a/friedhof/mgrote_zswap/defaults/main.yml b/friedhof/mgrote_zswap/defaults/main.yml new file mode 100644 index 00000000..f30e693b --- /dev/null +++ b/friedhof/mgrote_zswap/defaults/main.yml @@ -0,0 +1,2 @@ +--- +zswap_path: "/sys/module/zswap/parameters/enabled" diff --git a/roles/mgrote.qemu_guest_agent/LICENSE b/friedhof/mgrote_zswap/mgrote.zswap/LICENSE similarity index 100% rename from roles/mgrote.qemu_guest_agent/LICENSE rename to friedhof/mgrote_zswap/mgrote.zswap/LICENSE diff --git a/friedhof/mgrote_zswap/mgrote.zswap/README.md b/friedhof/mgrote_zswap/mgrote.zswap/README.md new file mode 100644 index 00000000..e3ed0a3b --- /dev/null +++ b/friedhof/mgrote_zswap/mgrote.zswap/README.md @@ -0,0 +1,10 @@ +## mgrote.zswap + +### Beschreibung + +Aktiviert [zswap](https://www.kernel.org/doc/html/latest/admin-guide/mm/zswap.html) per cronjob + + +### getestet auf + +- [x] Ubuntu (>=20.04) diff --git a/friedhof/mgrote_zswap/mgrote.zswap/defaults/main.yml b/friedhof/mgrote_zswap/mgrote.zswap/defaults/main.yml new file mode 100644 index 00000000..f30e693b --- /dev/null +++ b/friedhof/mgrote_zswap/mgrote.zswap/defaults/main.yml @@ -0,0 +1,2 @@ +--- +zswap_path: "/sys/module/zswap/parameters/enabled" diff --git a/friedhof/mgrote_zswap/mgrote.zswap/tasks/main.yml b/friedhof/mgrote_zswap/mgrote.zswap/tasks/main.yml new file mode 100644 index 00000000..609a6c4b --- /dev/null +++ b/friedhof/mgrote_zswap/mgrote.zswap/tasks/main.yml @@ -0,0 +1,6 @@ +--- +- name: add zswap to crontab + ansible.builtin.cron: + name: "activate zswap" + special_time: reboot + job: "echo 1 > {{ zswap_path }}" diff --git a/friedhof/mgrote_zswap/tasks/main.yml b/friedhof/mgrote_zswap/tasks/main.yml new file mode 100644 index 00000000..609a6c4b --- /dev/null +++ b/friedhof/mgrote_zswap/tasks/main.yml @@ -0,0 +1,6 @@ +--- +- name: add zswap to crontab + ansible.builtin.cron: + name: "activate zswap" + special_time: reboot + job: "echo 1 > {{ zswap_path }}" diff --git a/group_vars/all.yml b/group_vars/all.yml index a49d7a01..35c1edbe 100644 --- a/group_vars/all.yml +++ b/group_vars/all.yml @@ -1,220 +1,220 @@ --- - ### wird in vielen Rollen verwendet - ssh_public_key_mg: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKL8opSQ0rWVw9uCfbuiqmXq188OP4xh66MBTO3zV5jo heimserver_mg_v3 - empfaenger_mail: michael.grote@posteo.de - file_header: | - #----------------------------------------------------------------# - # This file is managed with ansible! # - #----------------------------------------------------------------# - ### mgrote.restic - restic_user: root - restic_group: restic - restic_conf_dir: /etc/restic - restic_exclude: | - ._* - desktop.ini - .Trash-* - **/**cache***/** - **/**Cache***/** - **/**AppData***/** - # https://github.com/restic/restic/issues/1005 - # https://forum.restic.net/t/exclude-syntax-confusion/1531/12 - restic_mount_timeout: "10 min" - restic_failure_delay: "30 s" - restic_schedule: "0/6:00" # alle 6 Stunden - restic_folders_to_backup: "/" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files - restic_repository: "//fileserver3.grote.lan/restic" - restic_repository_password: "{{ lookup('keepass', 'restic_repository_password', 'password') }}" - restic_mount_user: restic - restic_mount_password: "{{ lookup('keepass', 'fileserver_smb_user_restic', 'password') }}" - restic_fail_mail: "{{ empfaenger_mail }}" - ### mgrote.user - users: - - username: mg - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: "{{ ssh_public_key_mg }}" - allow_sudo: true - allow_passwordless_sudo: true - - username: ansible-user - password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu - allow_sudo: true - allow_passwordless_sudo: true +### wird in vielen Rollen verwendet +ssh_public_key_mg: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKL8opSQ0rWVw9uCfbuiqmXq188OP4xh66MBTO3zV5jo heimserver_mg_v3 +empfaenger_mail: michael.grote@posteo.de +file_header: | + #----------------------------------------------------------------# + # This file is managed with ansible! # + #----------------------------------------------------------------# +### mgrote.restic +restic_user: root +restic_group: restic +restic_conf_dir: /etc/restic +restic_exclude: | + ._* + desktop.ini + .Trash-* + **/**cache***/** + **/**Cache***/** + **/**AppData***/** + # https://github.com/restic/restic/issues/1005 + # https://forum.restic.net/t/exclude-syntax-confusion/1531/12 +restic_mount_timeout: "10 min" +restic_failure_delay: "30 s" +restic_schedule: "0/6:00" # alle 6 Stunden +restic_folders_to_backup: "/" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files +restic_repository: "//fileserver3.grote.lan/restic" +restic_repository_password: "{{ lookup('keepass', 'restic_repository_password', 'password') }}" +restic_mount_user: restic +restic_mount_password: "{{ lookup('keepass', 'fileserver_smb_user_restic', 'password') }}" +restic_fail_mail: "{{ empfaenger_mail }}" +### mgrote.user +users: + - username: mg + password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: "{{ ssh_public_key_mg }}" + allow_sudo: true + allow_passwordless_sudo: true + - username: ansible-user + password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu + allow_sudo: true + allow_passwordless_sudo: true - ### mgrote.dotfiles - dotfiles_repo_url: https://git.mgrote.net/mg/dotfiles - dotfiles_repo_path: /home/mg/dotfiles - dotfiles_files: - - repo_path: "{{ dotfiles_repo_path}}/.vimrc" - local_path: "/home/mg/.vimrc" - - repo_path: "{{ dotfiles_repo_path}}/.tmux.conf" - local_path: "/home/mg/.tmux.conf" - - repo_path: "{{ dotfiles_repo_path}}/.gitconfig" - local_path: "/home/mg/.gitconfig" - dotfiles_owner: mg - ### jnv.unattended_upgrades - unattended_mail: "{{ empfaenger_mail }}" - unattended_mail_only_on_error: true - unattended_syslog_enable: true - unattended_origins_patterns: - - 'origin=Ubuntu,archive=${distro_codename}-security' - - 'o=Ubuntu,a=${distro_codename}-updates' - ### mgrote.ntp_chrony_client - ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet - ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile - ntp_chrony_servers: # welche Server sollen befragt werden - - address: ptbtime1.ptb.de - options: iburst #optionaler parameter - ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst - ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst - ntp_chrony_logging: false +### mgrote.dotfiles +dotfiles_repo_url: https://git.mgrote.net/mg/dotfiles +dotfiles_repo_path: /home/mg/dotfiles +dotfiles_files: + - repo_path: "{{ dotfiles_repo_path }}/.vimrc" + local_path: "/home/mg/.vimrc" + - repo_path: "{{ dotfiles_repo_path }}/.tmux.conf" + local_path: "/home/mg/.tmux.conf" + - repo_path: "{{ dotfiles_repo_path }}/.gitconfig" + local_path: "/home/mg/.gitconfig" +dotfiles_owner: mg +### jnv.unattended_upgrades +unattended_mail: "{{ empfaenger_mail }}" +unattended_mail_only_on_error: true +unattended_syslog_enable: true +unattended_origins_patterns: + - 'origin=Ubuntu,archive=${distro_codename}-security' + - 'o=Ubuntu,a=${distro_codename}-updates' +### mgrote.ntp_chrony_client +ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet +ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile +ntp_chrony_servers: # welche Server sollen befragt werden + - address: ptbtime1.ptb.de + options: iburst #optionaler parameter +ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_logging: false - ### mgrote.postfix - postfix_absender_mailadresse: info@mgrote.net - postfix_absender_passwort: "{{ lookup('keepass', 'postfix_absender_passwort', 'password') }}" - postfix_erlaubte_netzwerke: "127.0.0.0/8 192.168.2.0/24" - postfix_mail_nach_cronjob: false - postfix_smtp_server: smtp.strato.de - postfix_smtp_server_port: 587 - postfix_smtp_use_tls: "yes" - ### mgrote.tmux - tmux_conf_destination: "/home/mg/.tmux.conf" - tmux_bashrc_destination: "/home/mg/.bashrc" - tmux_standardsession_name: "default" - ### mgrote.fail2ban - f2b_bantime: 300 - f2b_findtime: 300 - f2b_maxretry: 5 - f2b_destemail: "{{ empfaenger_mail }}" - f2b_sender: "{{ postfix_absender_mailadresse }}" - ### oefenweb.ufw - ufw_rules: - - rule: allow - to_port: 22 - protocol: tcp - comment: 'ssh' - from_ip: 0.0.0.0/0 - ufw_default_incoming_policy: deny - ufw_default_outgoing_policy: allow - ### mgrote.apt_manage_packages - apt_packages_common: - - locales - - python3 - - build-essential - - htop - - git - - dnsutils - - mc - - cifs-utils - - haveged #https://www.linux-magazin.de/ausgaben/2011/09/einfuehrung2/ - - ca-certificates - - netdiscover - - tree - - curl - - whois - - logrotate - - ncdu - - net-tools - - apt-transport-https - - neofetch - - moreutils - - acl - - vim - - rsync - - at - - ripgrep - - iotop - - pwgen - - keychain - apt_packages_physical: - - s-tui - - smartmontools - - lm-sensors - - ethtool - apt_packages_vm: - - qemu-guest-agent - - open-vm-tools - apt_packages_absent: - - nano - - snapd - - ubuntu-advantage-tools - apt_packages_internet: - - http://docker10.grote.lan:3344/bash-helper-scripts-mgrote-latest.deb +### mgrote.postfix +postfix_absender_mailadresse: info@mgrote.net +postfix_absender_passwort: "{{ lookup('keepass', 'postfix_absender_passwort', 'password') }}" +postfix_erlaubte_netzwerke: "127.0.0.0/8 192.168.2.0/24" +postfix_mail_nach_cronjob: false +postfix_smtp_server: smtp.strato.de +postfix_smtp_server_port: 587 +postfix_smtp_use_tls: "yes" +### mgrote.tmux +tmux_conf_destination: "/home/mg/.tmux.conf" +tmux_bashrc_destination: "/home/mg/.bashrc" +tmux_standardsession_name: "default" +### mgrote.fail2ban +f2b_bantime: 300 +f2b_findtime: 300 +f2b_maxretry: 5 +f2b_destemail: "{{ empfaenger_mail }}" +f2b_sender: "{{ postfix_absender_mailadresse }}" +### oefenweb.ufw +ufw_rules: + - rule: allow + to_port: 22 + protocol: tcp + comment: 'ssh' + from_ip: 0.0.0.0/0 +ufw_default_incoming_policy: deny +ufw_default_outgoing_policy: allow +### mgrote.apt_manage_packages +apt_packages_common: + - locales + - python3 + - build-essential + - htop + - git + - dnsutils + - mc + - cifs-utils + - haveged #https://www.linux-magazin.de/ausgaben/2011/09/einfuehrung2/ + - ca-certificates + - netdiscover + - tree + - curl + - whois + - logrotate + - ncdu + - net-tools + - apt-transport-https + - neofetch + - moreutils + - acl + - vim + - rsync + - at + - ripgrep + - iotop + - pwgen + - keychain +apt_packages_physical: + - s-tui + - smartmontools + - lm-sensors + - ethtool +apt_packages_vm: + - qemu-guest-agent + - open-vm-tools +apt_packages_absent: + - nano + - snapd + - ubuntu-advantage-tools +apt_packages_internet: + - http://docker10.grote.lan:3344/bash-helper-scripts-mgrote-latest.deb - ### mgrote.zfs_sanoid - sanoid_templates: - - name: '31tage' - keep_hourly: '24' # Aufheben (Stunde) - keep_daily: '31' # Aufheben (Tage) - keep_monthly: '3' # Aufheben (Monate) - keep_yearly: '0' # Aufheben (Jahre) - frequently: '16' # Aufheben (Minuten) - frequent_period: '15' # Intervall (alle 5 Minuten) - autosnap: 'yes' # Automatisches erstellen von Snapshots - autoprune: 'yes' - - name: '14tage' - keep_hourly: '24' - keep_daily: '14' - keep_monthly: '0' - keep_yearly: '0' - frequently: '16' - frequent_period: '15' - autosnap: 'yes' - autoprune: 'yes' - - name: '3tage' - keep_hourly: '24' - keep_daily: '7' - keep_monthly: '0' - keep_yearly: '0' - frequently: '16' - frequent_period: '15' - autosnap: 'yes' - autoprune: 'yes' - - name: '3monate' - keep_hourly: '24' - keep_daily: '7' - keep_monthly: '3' - keep_yearly: '0' - frequently: '16' - frequent_period: '15' - autosnap: 'yes' - autoprune: 'yes' - - name: 'pve3tage' - keep_hourly: '72' - keep_daily: '5' - keep_monthly: '0' - keep_yearly: '0' - frequently: '16' - frequent_period: '15' - autosnap: 'yes' - autoprune: 'yes' +### mgrote.zfs_sanoid +sanoid_templates: + - name: '31tage' + keep_hourly: '24' # Aufheben (Stunde) + keep_daily: '31' # Aufheben (Tage) + keep_monthly: '3' # Aufheben (Monate) + keep_yearly: '0' # Aufheben (Jahre) + frequently: '16' # Aufheben (Minuten) + frequent_period: '15' # Intervall (alle 5 Minuten) + autosnap: 'yes' # Automatisches erstellen von Snapshots + autoprune: 'yes' + - name: '14tage' + keep_hourly: '24' + keep_daily: '14' + keep_monthly: '0' + keep_yearly: '0' + frequently: '16' + frequent_period: '15' + autosnap: 'yes' + autoprune: 'yes' + - name: '3tage' + keep_hourly: '24' + keep_daily: '7' + keep_monthly: '0' + keep_yearly: '0' + frequently: '16' + frequent_period: '15' + autosnap: 'yes' + autoprune: 'yes' + - name: '3monate' + keep_hourly: '24' + keep_daily: '7' + keep_monthly: '3' + keep_yearly: '0' + frequently: '16' + frequent_period: '15' + autosnap: 'yes' + autoprune: 'yes' + - name: 'pve3tage' + keep_hourly: '72' + keep_daily: '5' + keep_monthly: '0' + keep_yearly: '0' + frequently: '16' + frequent_period: '15' + autosnap: 'yes' + autoprune: 'yes' - ### mgrote.zfs_sanoid - sanoid_deb_url: http://docker10.grote.lan:3344/sanoid_3.0.4.deb +### mgrote.zfs_sanoid +sanoid_deb_url: http://docker10.grote.lan:3344/sanoid_3.0.4.deb - # Ansible Variablen - ### User - ansible_user: "ansible-user" - ### SSH - ansible_ssh_common_args: "'-o StrictHostKeyChecking=no'" - ### python3 - # https://docs.ansible.com/ansible/latest/reference_appendices/python_3_support.html - ansible_python_interpreter: "/usr/bin/python3" +# Ansible Variablen +### User +ansible_user: "ansible-user" +### SSH +ansible_ssh_common_args: "'-o StrictHostKeyChecking=no'" +### python3 +# https://docs.ansible.com/ansible/latest/reference_appendices/python_3_support.html +ansible_python_interpreter: "/usr/bin/python3" - # Ansible Plugin Variablen - ### Keepass - # https://github.com/viczem/ansible-keepass - keepass_dbx: "./keepass_db.kdbx" - keepass_psw: !vault | - $ANSIBLE_VAULT;1.1;AES256 - 62383737623066396239383336646164616537646630653964313532383130343533346561633039 - 3437306134656535353438666165376332633064383135650a636537626662656130376537633164 - 61613132326536666466636632363866393066656236303766333338356337396338376266346631 - 6364336331623539300a313562303161373631613734313938346666376239613333333363376236 - 38363035376662353135333332363431343833656666643036326234656166643531 +# Ansible Plugin Variablen +### Keepass +# https://github.com/viczem/ansible-keepass +keepass_dbx: "./keepass_db.kdbx" +keepass_psw: !vault | + $ANSIBLE_VAULT;1.1;AES256 + 62383737623066396239383336646164616537646630653964313532383130343533346561633039 + 3437306134656535353438666165376332633064383135650a636537626662656130376537633164 + 61613132326536666466636632363866393066656236303766333338356337396338376266346631 + 6364336331623539300a313562303161373631613734313938346666376239613333333363376236 + 38363035376662353135333332363431343833656666643036326234656166643531 diff --git a/group_vars/ansible.yml b/group_vars/ansible.yml index aa262fcf..0625961f 100644 --- a/group_vars/ansible.yml +++ b/group_vars/ansible.yml @@ -1,16 +1,16 @@ --- - ### geerlingguy.pip - pip_package: python3-pip - pip_install_packages: - - name: pykeepass - version: 3.2.1 - - name: Jinja2>=2.11.2 - - name: markupsafe - - name: ara - - name: jmespath - ### geerlingguy.ansible - ansible_install_method: pip - ansible_install_version_pip: '8.0.0' - ### mgrote.apt_manage_packages - apt_packages_extra: - - sshpass +### geerlingguy.pip +pip_package: python3-pip +pip_install_packages: + - name: pykeepass + version: 3.2.1 + - name: Jinja2>=2.11.2 + - name: markupsafe + - name: ara + - name: jmespath +### geerlingguy.ansible +ansible_install_method: pip +ansible_install_version_pip: '8.0.0' +### mgrote.apt_manage_packages +apt_packages_extra: + - sshpass diff --git a/group_vars/docker.yml b/group_vars/docker.yml index c014e84b..3d77562c 100644 --- a/group_vars/docker.yml +++ b/group_vars/docker.yml @@ -1,65 +1,66 @@ --- - ### mrlesmithjr.ansible-manage-lvm - lvm_groups: - - vgname: vg_docker - disks: - - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 - create: true - lvnames: - - lvname: lv_docker - size: +100%FREE - create: true - filesystem: xfs - mount: true - mntp: /var/lib/docker - manage_lvm: true - pvresize_to_max: true - ### mgrote.restic - restic_folders_to_backup: "/ /var/lib/docker" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files - ### mgrote.user - users: - - username: mg - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo, docker - state: present - public_ssh_key: "{{ ssh_public_key_mg }}" - allow_sudo: true - allow_passwordless_sudo: true - - username: docker-user - password: "{{ lookup('keepass', 'docker-user_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo, docker - state: present - allow_sudo: true - allow_passwordless_sudo: true - uid: "5000" - - username: ansible-user - password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu - allow_sudo: true - allow_passwordless_sudo: true - ### geerlingguy.docker - docker_users: - - mg - - docker-user +### mrlesmithjr.ansible-manage-lvm +lvm_groups: + - vgname: vg_docker + disks: + - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 + create: true + lvnames: + - lvname: lv_docker + size: +100%FREE + create: true + filesystem: xfs + mount: true + mntp: /var/lib/docker +manage_lvm: true +pvresize_to_max: true +### mgrote.restic +restic_folders_to_backup: "/ /var/lib/docker" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files +### mgrote.user +users: + - username: mg + password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo, docker + state: present + public_ssh_key: "{{ ssh_public_key_mg }}" + allow_sudo: true + allow_passwordless_sudo: true + - username: docker-user + password: "{{ lookup('keepass', 'docker-user_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo, docker + state: present + allow_sudo: true + allow_passwordless_sudo: true + uid: "5000" + - username: ansible-user + password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu + allow_sudo: true + allow_passwordless_sudo: true - ### mgrote.docker-compose-deploy - docker_compose_base_dir: /home/docker-user +### geerlingguy.docker +docker_users: + - mg + - docker-user - ### mgrote.apt_manage_sources - repos_override: # mit docker-repos - - deb [arch=amd64] https://download.docker.com/linux/ubuntu jammy stable - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }} main restricted" - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-updates main restricted" - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }} universe" - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-updates universe" - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }} multiverse" - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-updates multiverse" - - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-backports main restricted universe multiverse" - - "deb http://security.ubuntu.com/ubuntu {{ ansible_distribution_release }}-security main restricted" - - "deb http://security.ubuntu.com/ubuntu {{ ansible_distribution_release }}-security universe" - - "deb http://security.ubuntu.com/ubuntu {{ ansible_distribution_release }}-security multiverse" +### mgrote.docker-compose-deploy +docker_compose_base_dir: /home/docker-user + +### mgrote.apt_manage_sources +repos_override: # mit docker-repos + - deb [arch=amd64] https://download.docker.com/linux/ubuntu jammy stable + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }} main restricted" + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-updates main restricted" + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }} universe" + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-updates universe" + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }} multiverse" + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-updates multiverse" + - "deb http://de.archive.ubuntu.com/ubuntu/ {{ ansible_distribution_release }}-backports main restricted universe multiverse" + - "deb http://security.ubuntu.com/ubuntu {{ ansible_distribution_release }}-security main restricted" + - "deb http://security.ubuntu.com/ubuntu {{ ansible_distribution_release }}-security universe" + - "deb http://security.ubuntu.com/ubuntu {{ ansible_distribution_release }}-security multiverse" diff --git a/group_vars/dokuwiki.yml b/group_vars/dokuwiki.yml index f89f3cdf..1b03f3bd 100644 --- a/group_vars/dokuwiki.yml +++ b/group_vars/dokuwiki.yml @@ -1,19 +1,19 @@ --- - ### mgrote.dokuwiki - dokuwiki_install_path: /var/www/dokuwiki # wohin soll dokuwiki installiert werden - dokuwiki_download_url: https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz # wo soll dokuwiki heruntergeladen werden - dokuwiki_version_name: 2022-07-31 "Igor" # aus /var/www/dokuwiki/VERSION # welche Version, damit wird abgeglichen ob das Archiv heruntergeladen werden muss - dokuwiki_user: www-data # dokuwiki nutzer - dokuwiki_group: www-data # dokuwiki gruppe - ### oefenweb.ufw - ufw_rules: - - rule: allow - to_port: 22 - protocol: tcp - comment: 'ssh' - from_ip: 0.0.0.0/0 - - rule: allow - to_port: 80 - comment: 'dokuwiki-webserver' - from_ip: 0.0.0.0/0 - protocol: tcp +### mgrote.dokuwiki +dokuwiki_install_path: /var/www/dokuwiki # wohin soll dokuwiki installiert werden +dokuwiki_download_url: https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz # wo soll dokuwiki heruntergeladen werden +dokuwiki_version_name: 2022-07-31 "Igor" # aus /var/www/dokuwiki/VERSION # welche Version, damit wird abgeglichen ob das Archiv heruntergeladen werden muss +dokuwiki_user: www-data # dokuwiki nutzer +dokuwiki_group: www-data # dokuwiki gruppe +### oefenweb.ufw +ufw_rules: + - rule: allow + to_port: 22 + protocol: tcp + comment: 'ssh' + from_ip: 0.0.0.0/0 + - rule: allow + to_port: 80 + comment: 'dokuwiki-webserver' + from_ip: 0.0.0.0/0 + protocol: tcp diff --git a/group_vars/fileserver.yml b/group_vars/fileserver.yml index 03eae044..db04154b 100644 --- a/group_vars/fileserver.yml +++ b/group_vars/fileserver.yml @@ -1,121 +1,121 @@ --- - ### PROXMOX - # fileserver3 ist ein LXC-Container; der Container ist "privileged" damit der Bind-Mount die richtigen Rechte bekommt +### PROXMOX +# fileserver3 ist ein LXC-Container; der Container ist "privileged" damit der Bind-Mount die richtigen Rechte bekommt - ### oefenweb.ufw - ufw_rules: - - rule: allow - to_port: 22 - protocol: tcp - comment: 'ssh' - from_ip: 0.0.0.0/0 - - rule: allow - to_port: 445 - comment: 'smb' - from_ip: 0.0.0.0/0 - - rule: allow - to_port: 139 - comment: 'smb' - from_ip: 0.0.0.0/0 +### oefenweb.ufw +ufw_rules: + - rule: allow + to_port: 22 + protocol: tcp + comment: 'ssh' + from_ip: 0.0.0.0/0 + - rule: allow + to_port: 445 + comment: 'smb' + from_ip: 0.0.0.0/0 + - rule: allow + to_port: 139 + comment: 'smb' + from_ip: 0.0.0.0/0 - ### mgrote.apt_manage_packages - apt_packages_internet: - - http://docker10.grote.lan:3344/bash-helper-scripts-mgrote-latest.deb +### mgrote.apt_manage_packages +apt_packages_internet: + - http://docker10.grote.lan:3344/bash-helper-scripts-mgrote-latest.deb - ### mgrote.youtubedl - ytdl_dl_url: "https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp" - ytdl_timer: "Tue,Sat 03:00" - ytdl_bin_path: /usr/local/bin/yt-dlp - ytdl_active: true - ytdl_video_urls: - - https://www.youtube.com/c/KurzgesagtDE/videos # Kurzgesagt - Deutsch - - https://www.youtube.com/c/inanutshell/videos # Kurzgesagt - Englisch - - https://www.youtube.com/c/MartinSonneborn/videos #martin sonneborn - - https://www.youtube.com/c/100SekundenPhysik/videos #100 sekunden physik - - https://www.youtube.com/c/Handwerkskunst/videos #swr handwerkskunst kanal - - https://www.youtube.com/c/PracticalEngineeringChannel/videos # pracrical engineering - - https://www.youtube.com/channel/UC0vFIgkGrbmfxKVhZ2hgMeg/videos #gaby weber - - https://www.youtube.com/playlist?list=PLPM-eyPokAWNhhDNO4YzC5cGRwuI2ykwE # music - - https://www.youtube.com/playlist?list=PLPM-eyPokAWNnDxuyX131R5wkl8fzvu7D # lost and found - - https://www.youtube.com/playlist?list=PLPM-eyPokAWPmStfh37roJge-JuLfgma0 # lost and found 2 - - https://www.youtube.com/playlist?list=PLcpuu5BzmasC7cI-B713EY3xdpWrLhDdH #Japan Day in the Life Series by Paolo fromTOKYO - - https://www.youtube.com/playlist?list=PLlQWnS27jXh9gX1kvMT1frhzvFnDgP_8M # arte die großen mythen - - https://www.youtube.com/playlist?list=PLrMX9ct-uNyOKfDG0WrRd6fQsB21MzorZ # JoBlo - Videos - WTF HAPPENED TO THIS MOVIE?! - - https://www.youtube.com/playlist?list=PLrMX9ct-uNyOt0Z-iqBGuyiZU9pFJyvD5 # JoBlo - Videos - THE MOVIE THAT ALMOST WAS - - https://www.youtube.com/playlist?list=PLrMX9ct-uNyMNMZgSkxRdNh2xa8GEZQn4 # JoBlo - Videos - WTF HAPPENED TO THIS CELEBRITY?! - - https://www.youtube.com/watch?v=TowKvEJcYDw&list=PLlQWnS27jXh9aEp7hl54xrk5CgiVbvMBy # arte - zu Tisch in... - - https://www.youtube.com/playlist?list=PLs4hTtftqnlAkiQNdWn6bbKUr-P1wuSm0 # jimmy kimmel mean tweets - - https://www.youtube.com/tomstantonengineering - - https://www.youtube.com/@liamcarps #englandvideos ironisch - ytdl_podcast_urls: - - https://sternengeschichten.podigee.io/feed/aac # Sternengeschichten - - https://feeds.br.de/radiowissen/feed.xml # BR2 RadioWissen +### mgrote.youtubedl +ytdl_dl_url: "https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp" +ytdl_timer: "Tue,Sat 03:00" +ytdl_bin_path: /usr/local/bin/yt-dlp +ytdl_active: true +ytdl_video_urls: + - https://www.youtube.com/c/KurzgesagtDE/videos # Kurzgesagt - Deutsch + - https://www.youtube.com/c/inanutshell/videos # Kurzgesagt - Englisch + - https://www.youtube.com/c/MartinSonneborn/videos #martin sonneborn + - https://www.youtube.com/c/100SekundenPhysik/videos #100 sekunden physik + - https://www.youtube.com/c/Handwerkskunst/videos #swr handwerkskunst kanal + - https://www.youtube.com/c/PracticalEngineeringChannel/videos # pracrical engineering + - https://www.youtube.com/channel/UC0vFIgkGrbmfxKVhZ2hgMeg/videos #gaby weber + - https://www.youtube.com/playlist?list=PLPM-eyPokAWNhhDNO4YzC5cGRwuI2ykwE # music + - https://www.youtube.com/playlist?list=PLPM-eyPokAWNnDxuyX131R5wkl8fzvu7D # lost and found + - https://www.youtube.com/playlist?list=PLPM-eyPokAWPmStfh37roJge-JuLfgma0 # lost and found 2 + - https://www.youtube.com/playlist?list=PLcpuu5BzmasC7cI-B713EY3xdpWrLhDdH #Japan Day in the Life Series by Paolo fromTOKYO + - https://www.youtube.com/playlist?list=PLlQWnS27jXh9gX1kvMT1frhzvFnDgP_8M # arte die großen mythen + - https://www.youtube.com/playlist?list=PLrMX9ct-uNyOKfDG0WrRd6fQsB21MzorZ # JoBlo - Videos - WTF HAPPENED TO THIS MOVIE?! + - https://www.youtube.com/playlist?list=PLrMX9ct-uNyOt0Z-iqBGuyiZU9pFJyvD5 # JoBlo - Videos - THE MOVIE THAT ALMOST WAS + - https://www.youtube.com/playlist?list=PLrMX9ct-uNyMNMZgSkxRdNh2xa8GEZQn4 # JoBlo - Videos - WTF HAPPENED TO THIS CELEBRITY?! + - https://www.youtube.com/watch?v=TowKvEJcYDw&list=PLlQWnS27jXh9aEp7hl54xrk5CgiVbvMBy # arte - zu Tisch in... + - https://www.youtube.com/playlist?list=PLs4hTtftqnlAkiQNdWn6bbKUr-P1wuSm0 # jimmy kimmel mean tweets + - https://www.youtube.com/tomstantonengineering + - https://www.youtube.com/@liamcarps #englandvideos ironisch +ytdl_podcast_urls: + - https://sternengeschichten.podigee.io/feed/aac # Sternengeschichten + - https://feeds.br.de/radiowissen/feed.xml # BR2 RadioWissen - ytdl_video_output: "/shares_videos/Youtube/%(uploader)s/%(title)s-%(id)s.%(ext)s" # Videos werden jetzt IMMEr nach "Uploader/Name.ext" geschrieben +ytdl_video_output: "/shares_videos/Youtube/%(uploader)s/%(title)s-%(id)s.%(ext)s" # Videos werden jetzt IMMEr nach "Uploader/Name.ext" geschrieben - ytdl_podcast_output: "/shares_music/Podcasts/%(playlist)s/%(id)s.%(ext)s" - ytdl_video_log_output: "/shares_videos/Youtube/archive-youtube.log" - ytdl_podcast_log_output: "/shares_music/Podcasts/archive-podcast.log" - ytdl_youtube_username: "{{ lookup('keepass', 'youtubedl_youtube_login', 'username') }}" - ytdl_youtube_password: "{{ lookup('keepass', 'youtubedl_youtube_login', 'password') }}" - ytdl_conf_dir: "/etc/youtubedl" #ohne / am ende - ytdl_download_limit: "10000K" +ytdl_podcast_output: "/shares_music/Podcasts/%(playlist)s/%(id)s.%(ext)s" +ytdl_video_log_output: "/shares_videos/Youtube/archive-youtube.log" +ytdl_podcast_log_output: "/shares_music/Podcasts/archive-podcast.log" +ytdl_youtube_username: "{{ lookup('keepass', 'youtubedl_youtube_login', 'username') }}" +ytdl_youtube_password: "{{ lookup('keepass', 'youtubedl_youtube_login', 'password') }}" +ytdl_conf_dir: "/etc/youtubedl" #ohne / am ende +ytdl_download_limit: "10000K" - ### mgrote.smb_fileserver - smb_shares: - - name: 'videos' - path: '/shares_videos' - users_ro: 'kodi' - users_rw: 'michaelgrote win10' - - name: 'scans' - path: '/shares_scans' - users_ro: ' michaelgrote' - users_rw: 'brother_ads2700w' - - name: 'papa_backup' - path: '/shares_papa_backup' - users_ro: 'michaelgrote' - users_rw: 'win10' - - name: 'backup' - path: '/shares_backup' - users_ro: '' - users_rw: 'win10 michaelgrote' - - name: 'archiv' - path: '/shares_archiv' - users_ro: '' - users_rw: 'michaelgrote win10' - - name: 'hm' - path: '/shares_hm' - users_ro: '' - users_rw: 'michaelgrote win10' - - name: 'musik' - path: '/shares_music' - users_ro: 'navidrome kodi ' - users_rw: 'win10 michaelgrote' - - name: 'tmp' - path: '/shares_tmp' - users_ro: 'win10' - users_rw: 'kodi win10 michaelgrote' - - name: 'bilder' - path: '/shares_bilder' - users_ro: 'photoprism' - users_rw: ' michaelgrote win10' - - name: 'proxmox' - path: '/shares_pve_backup' - users_ro: 'michaelgrote' - users_rw: 'pve win10' - - name: 'restic' - path: '/shares_restic' - users_ro: '' - users_rw: ' restic win10 michaelgrote' - - name: 'buecher' - path: '/shares_buecher' - users_ro: '' - users_rw: 'michaelgrote win10' - - name: 'programme' - path: '/shares_programme' - users_ro: '' - users_rw: 'michaelgrote win10' - - name: 'vm' - path: '/shares_vm' - users_ro: '' - users_rw: 'michaelgrote' +### mgrote.smb_fileserver +smb_shares: + - name: 'videos' + path: '/shares_videos' + users_ro: 'kodi' + users_rw: 'michaelgrote win10' + - name: 'scans' + path: '/shares_scans' + users_ro: ' michaelgrote' + users_rw: 'brother_ads2700w' + - name: 'papa_backup' + path: '/shares_papa_backup' + users_ro: 'michaelgrote' + users_rw: 'win10' + - name: 'backup' + path: '/shares_backup' + users_ro: '' + users_rw: 'win10 michaelgrote' + - name: 'archiv' + path: '/shares_archiv' + users_ro: '' + users_rw: 'michaelgrote win10' + - name: 'hm' + path: '/shares_hm' + users_ro: '' + users_rw: 'michaelgrote win10' + - name: 'musik' + path: '/shares_music' + users_ro: 'navidrome kodi ' + users_rw: 'win10 michaelgrote' + - name: 'tmp' + path: '/shares_tmp' + users_ro: 'win10' + users_rw: 'kodi win10 michaelgrote' + - name: 'bilder' + path: '/shares_bilder' + users_ro: 'photoprism' + users_rw: ' michaelgrote win10' + - name: 'proxmox' + path: '/shares_pve_backup' + users_ro: 'michaelgrote' + users_rw: 'pve win10' + - name: 'restic' + path: '/shares_restic' + users_ro: '' + users_rw: ' restic win10 michaelgrote' + - name: 'buecher' + path: '/shares_buecher' + users_ro: '' + users_rw: 'michaelgrote win10' + - name: 'programme' + path: '/shares_programme' + users_ro: '' + users_rw: 'michaelgrote win10' + - name: 'vm' + path: '/shares_vm' + users_ro: '' + users_rw: 'michaelgrote' diff --git a/group_vars/gitea.yml b/group_vars/gitea.yml index f420a34d..b0726503 100644 --- a/group_vars/gitea.yml +++ b/group_vars/gitea.yml @@ -1,99 +1,101 @@ --- - ### mrlesmithjr.ansible-manage-lvm - lvm_groups: - - vgname: vg_gitea_data - disks: - - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 - create: true - lvnames: - - lvname: lv_gitea_data - size: +100%FREE - create: true - filesystem: xfs - mount: true - mntp: /var/lib/gitea - manage_lvm: true - pvresize_to_max: true - ### mgrote.restic - restic_folders_to_backup: "/ /var/lib/gitea" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files - ### oefenweb.ufw - ufw_rules: - - rule: allow - to_port: 22 - protocol: tcp - comment: 'ssh' - from_ip: 0.0.0.0/0 - - rule: allow - to_port: "{{ gitea_http_port }}" - protocol: tcp - comment: 'gitea' - from_ip: 0.0.0.0/0 - - rule: allow - to_port: "{{ gitea_ssh_port }}" - protocol: tcp - comment: 'gitea' - from_ip: 0.0.0.0/0 +### mrlesmithjr.ansible-manage-lvm +lvm_groups: + - vgname: vg_gitea_data + disks: + - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 + create: true + lvnames: + - lvname: lv_gitea_data + size: +100%FREE + create: true + filesystem: xfs + mount: true + mntp: /var/lib/gitea +manage_lvm: true +pvresize_to_max: true - ### l3d.gitea - # config liegt in /etc/gitea/gitea.ini - gitea_version: "1.20.3" - gitea_app_name: "Gitea" - gitea_user: "gitea" - gitea_home: "/var/lib/gitea" - gitea_repository_root: "{{ gitea_home }}" - gitea_user_repo_limit: 300 - gitea_root_url: https://git.mgrote.net - gitea_offline_mode: true - gitea_lfs_server_enabled: false - gitea_secret_key: "{{ lookup('keepass', 'gitea_secret_key', 'password') }}" - gitea_internal_token: "{{ lookup('keepass', 'gitea_internal_token', 'password') }}" - gitea_disable_git_hooks: false - gitea_show_user_email: false - gitea_disable_gravatar: true - gitea_enable_captcha: true - gitea_only_allow_external_registration: false - gitea_enable_notify_mail: false - gitea_force_private: false - gitea_oauth2_enabled: true - gitea_repo_indexer_enabled: true +### mgrote.restic +restic_folders_to_backup: "/ /var/lib/gitea" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files - gitea_mailer_enabled: true - gitea_mailer_skip_verify: false - gitea_mailer_tls_enabled: true - gitea_mailer_host: smtp.strato.de:465 - gitea_mailer_from: info@mgrote.net - gitea_mailer_user: "info@mgrote.net" - gitea_mailer_password: "{{ lookup('keepass', 'postfix_absender_passwort', 'password') }}" - gitea_mailer_type: smtp +### oefenweb.ufw +ufw_rules: + - rule: allow + to_port: 22 + protocol: tcp + comment: 'ssh' + from_ip: 0.0.0.0/0 + - rule: allow + to_port: "{{ gitea_http_port }}" + protocol: tcp + comment: 'gitea' + from_ip: 0.0.0.0/0 + - rule: allow + to_port: "{{ gitea_ssh_port }}" + protocol: tcp + comment: 'gitea' + from_ip: 0.0.0.0/0 - gitea_default_branch: 'master' +### l3d.gitea +# config liegt in /etc/gitea/gitea.ini +gitea_version: "1.20.3" +gitea_app_name: "Gitea" +gitea_user: "gitea" +gitea_home: "/var/lib/gitea" +gitea_repository_root: "{{ gitea_home }}" +gitea_user_repo_limit: 300 +gitea_root_url: https://git.mgrote.net +gitea_offline_mode: true +gitea_lfs_server_enabled: false +gitea_secret_key: "{{ lookup('keepass', 'gitea_secret_key', 'password') }}" +gitea_internal_token: "{{ lookup('keepass', 'gitea_internal_token', 'password') }}" +gitea_disable_git_hooks: false +gitea_show_user_email: false +gitea_disable_gravatar: true +gitea_enable_captcha: true +gitea_only_allow_external_registration: false +gitea_enable_notify_mail: false +gitea_force_private: false +gitea_oauth2_enabled: true +gitea_repo_indexer_enabled: true - gitea_db_type: sqlite3 - gitea_db_path: "{{ gitea_home }}/data/gitea.db" # for sqlite3 +gitea_mailer_enabled: true +gitea_mailer_skip_verify: false +gitea_mailer_tls_enabled: true +gitea_mailer_host: smtp.strato.de:465 +gitea_mailer_from: info@mgrote.net +gitea_mailer_user: "info@mgrote.net" +gitea_mailer_password: "{{ lookup('keepass', 'postfix_absender_passwort', 'password') }}" +gitea_mailer_type: smtp - gitea_ssh_listen: 0.0.0.0 - gitea_ssh_domain: gitea.grote.lan - gitea_ssh_port: 2222 - gitea_start_ssh: true +gitea_default_branch: 'master' - gitea_http_domain: git.mgrote.net - gitea_http_listen: 0.0.0.0 - gitea_http_port: 3000 - gitea_disable_http_git: false - gitea_protocol: http +gitea_db_type: sqlite3 +gitea_db_path: "{{ gitea_home }}/data/gitea.db" # for sqlite3 - gitea_show_registration_button: false - gitea_require_signin: false - gitea_disable_registration: true +gitea_ssh_listen: 0.0.0.0 +gitea_ssh_domain: gitea.grote.lan +gitea_ssh_port: 2222 +gitea_start_ssh: true - gitea_fail2ban_enabled: true - gitea_fail2ban_jail_maxretry: 3 - gitea_fail2ban_jail_findtime: 300 - gitea_fail2ban_jail_bantime: 600 - # wird für drone benötigt, sonst wird der Webhook nicht "gesendet" - gitea_extra_config: | - [webhook] - ALLOWED_HOST_LIST = *.grote.lan +gitea_http_domain: git.mgrote.net +gitea_http_listen: 0.0.0.0 +gitea_http_port: 3000 +gitea_disable_http_git: false +gitea_protocol: http - gitea_backup_on_upgrade: false - gitea_backup_location: "{{ gitea_home }}/backups/" +gitea_show_registration_button: false +gitea_require_signin: false +gitea_disable_registration: true + +gitea_fail2ban_enabled: true +gitea_fail2ban_jail_maxretry: 3 +gitea_fail2ban_jail_findtime: 300 +gitea_fail2ban_jail_bantime: 600 +# wird für drone benötigt, sonst wird der Webhook nicht "gesendet" +gitea_extra_config: | + [webhook] + ALLOWED_HOST_LIST = *.grote.lan + +gitea_backup_on_upgrade: false +gitea_backup_location: "{{ gitea_home }}/backups/" diff --git a/group_vars/k3s.yml b/group_vars/k3s.yml index 882ee7d6..55160e56 100644 --- a/group_vars/k3s.yml +++ b/group_vars/k3s.yml @@ -1,81 +1,81 @@ --- - ### Allgemein - kubeconfig: /etc/rancher/k3s/k3s.yaml - - ### mgrote.restic - restic_folders_to_backup: "/ /var" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files +### Allgemein +kubeconfig: /etc/rancher/k3s/k3s.yaml - ### pandemonium1986.ansible-role-k9s - k9s_version: "v0.27.3" +### mgrote.restic +restic_folders_to_backup: "/ /var" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben; https://restic.readthedocs.io/en/latest/040_backup.html#excluding-files - ### mrlesmithjr.ansible-manage-lvm - #lvm_groups: - # - vgname: vg_gitea_data - # disks: - # - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 - # create: true - # lvnames: - # - lvname: lv_gitea_data - # size: +100%FREE - # create: true - # filesystem: xfs - # mount: true - # mntp: /var/lib/gitea - #manage_lvm: true - #pvresize_to_max: true +### pandemonium1986.ansible-role-k9s +k9s_version: "v0.27.3" - ### oefenweb.ufw - ufw_rules: - - rule: allow - comment: 'k3s - alles offen' - from_ip: 0.0.0.0/0 +### mrlesmithjr.ansible-manage-lvm +#lvm_groups: +# - vgname: vg_gitea_data +# disks: +# - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 +# create: true +# lvnames: +# - lvname: lv_gitea_data +# size: +100%FREE +# create: true +# filesystem: xfs +# mount: true +# mntp: /var/lib/gitea +#manage_lvm: true +#pvresize_to_max: true - ### pyratlabs.k3s - k3s_state: installed - k3s_release_version: v1.25.11+k3s1 - k3s_airgap: false - k3s_config_file: /etc/rancher/k3s/config.yaml - k3s_build_cluster: true - k3s_install_dir: /usr/local/bin - k3s_etcd_datastore: true - k3s_become: true - k3s_use_experimental: true - k3s_debug: false - k3s_server: - # siehe https://docs.k3s.io/reference/server-config - # cli parameter OHNE -- am anfang - write-kubeconfig-mode: '644' - cluster-cidr: "10.42.0.0/16" - service-cidr: "10.43.0.0/16" - disable: - - traefik - - local-storage # disables local-path-provisioner - - disable-helm-controller # https://fluxcd.io/flux/cheatsheets/troubleshooting/ +### oefenweb.ufw +ufw_rules: + - rule: allow + comment: 'k3s - alles offen' + from_ip: 0.0.0.0/0 - ### mgrote.fluxcd - flux_repo_host: gitea.grote.lan - flux_repo_host_port: 2222 - flux_repo_branch: master - flux_repo_url_complete: "ssh://gitea@{{ flux_repo_host }}:{{ flux_repo_host_port }}/mg/manifests.git" - flux_install_host: k3s4.grote.lan - flux_homedir: /home/flux - flux_path_ssh_dir: /home/flux/.ssh - flux_user_group: flux - flux_user: flux - flux_download_url: https://github.com/fluxcd/flux2/releases/download/v2.0.1/flux_2.0.1_linux_amd64.tar.gz # updaten - flux_path_bin: /usr/local/sbin - flux_path_ssh_id_file: id_rsa - flux_ssh_key_format: ed25519 - flux_sync_interval: 1m +### pyratlabs.k3s +k3s_state: installed +k3s_release_version: v1.25.11+k3s1 +k3s_airgap: false +k3s_config_file: /etc/rancher/k3s/config.yaml +k3s_build_cluster: true +k3s_install_dir: /usr/local/bin +k3s_etcd_datastore: true +k3s_become: true +k3s_use_experimental: true +k3s_debug: false +k3s_server: + # siehe https://docs.k3s.io/reference/server-config + # cli parameter OHNE -- am anfang + write-kubeconfig-mode: '644' + cluster-cidr: "10.42.0.0/16" + service-cidr: "10.43.0.0/16" + disable: + - traefik + - local-storage # disables local-path-provisioner + - disable-helm-controller # https://fluxcd.io/flux/cheatsheets/troubleshooting/ - ### mgrote.apt_manage_packages - apt_packages_extra: - - nfs-common # für nfs-subdir-external-provisioner +### mgrote.fluxcd +flux_repo_host: gitea.grote.lan +flux_repo_host_port: 2222 +flux_repo_branch: master +flux_repo_url_complete: "ssh://gitea@{{ flux_repo_host }}:{{ flux_repo_host_port }}/mg/manifests.git" +flux_install_host: k3s4.grote.lan +flux_homedir: /home/flux +flux_path_ssh_dir: /home/flux/.ssh +flux_user_group: flux +flux_user: flux +flux_download_url: https://github.com/fluxcd/flux2/releases/download/v2.0.1/flux_2.0.1_linux_amd64.tar.gz # updaten +flux_path_bin: /usr/local/sbin +flux_path_ssh_id_file: id_rsa +flux_ssh_key_format: ed25519 +flux_sync_interval: 1m - ### mgrote.sealed-secrets - sealed_secrets_homedir: /home/sealed_secrets - sealed_secrets_user_group: sealed_secrets - sealed_secrets_user: sealed_secrets - kubeseal_download_url: "https://github.com/bitnami-labs/sealed-secrets/releases/download/v0.19.1/kubeseal-0.19.1-linux-amd64.tar.gz" #updaten - kubeseal_path_bin: /usr/local/sbin - sealed_secrets_keepass_entry_name: "{{ lookup('keepass', 'k3s-sealed-secrets-private-key', 'notes') }}" +### mgrote.apt_manage_packages +apt_packages_extra: + - nfs-common # für nfs-subdir-external-provisioner + +### mgrote.sealed-secrets +sealed_secrets_homedir: /home/sealed_secrets +sealed_secrets_user_group: sealed_secrets +sealed_secrets_user: sealed_secrets +kubeseal_download_url: "https://github.com/bitnami-labs/sealed-secrets/releases/download/v0.19.1/kubeseal-0.19.1-linux-amd64.tar.gz" #updaten +kubeseal_path_bin: /usr/local/sbin +sealed_secrets_keepass_entry_name: "{{ lookup('keepass', 'k3s-sealed-secrets-private-key', 'notes') }}" diff --git a/group_vars/laptop.yml b/group_vars/laptop.yml deleted file mode 100644 index 3d481f13..00000000 --- a/group_vars/laptop.yml +++ /dev/null @@ -1,83 +0,0 @@ ---- - ### mgrote.tmux - tmux_auto_attach: absent - ### mgrote.dotfiles - dotfiles_repo_url: https://git.mgrote.net/mg/dotfiles - dotfiles_repo_path: /home/mg/dotfiles - dotfiles_files: - - repo_path: "{{ dotfiles_repo_path}}/.vimrc" - local_path: "/home/mg/.vimrc" - - repo_path: "{{ dotfiles_repo_path}}/.tmux.conf" - local_path: "/home/mg/.tmux.conf" - - repo_path: "{{ dotfiles_repo_path}}/.gitconfig" - local_path: "/home/mg/.gitconfig" - - repo_path: "{{ dotfiles_repo_path}}/i3/config" - local_path: "/home/mg/.config/i3/config" - - repo_path: "{{ dotfiles_repo_path}}/alacritty/alacritty.yml" - local_path: "/home/mg/.config/alacritty/alacritty.yml" - - repo_path: "{{ dotfiles_repo_path}}/flameshot/flameshot.ini" - local_path: "/home/mg/.config/flameshot/flameshot.ini" - - repo_path: "{{ dotfiles_repo_path}}/.ssh/config" - local_path: "/home/mg/.ssh/config" - - repo_path: "{{ dotfiles_repo_path}}/dunstrc" - local_path: "/home/mg/.config/dunst/dunstrc" - dotfiles_dirs: - - path: /home/mg/.config/i3 - - path: /home/mg/.config/polybar - - path: /home/mg/.config/alacritty - - path: /home/mg/.config/.ssh - - path: /home/mg/.config/flameshot - dotfiles_owner: mg - ### mgrote.apt_manage_packages - apt_packages_extra: - - bmon - - s-tui - - smartmontools - - lm-sensors - - ethtool - - nextcloud-desktop - - gnome-tweaks - - powertop - - caja # filemanager - - arandr - - keepassxc - - vlc - - libreoffice - - gnome-calculator - - supertux - - python3-pip - - gramps # stammbaum - - shellcheck - - vivaldi-stable - - cowsay - - lolcat - - fortune-mod - ### mgrote.apt_manage_sources - # Extra-Repositories, sollte pro Host gesetzt werden - extra_repos: - - "deb [arch=amd64] https://repo.vivaldi.com/stable/deb/ stable main" - ### oefenweb.ufw - ufw_rules: - - rule: allow - to_port: 22 - protocol: tcp - comment: 'ssh' - from_ip: 0.0.0.0/0 - ### mgrote.user - users: - - username: mg - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo, docker - state: present - public_ssh_key: "{{ ssh_public_key_mg }}" - allow_sudo: true - allow_passwordless_sudo: true - - username: ansible-user - password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCyqs0OE5RVqs6tIzyuGQWvq/OVDa/tfdSEqMIwcthFt+pwCCjpqtNc8L8FSXgphSwuNosFakqhMLDFD3pmII+t61NRExsoR3nGTDuCAQnTvTKXTEfhnunN3pwgXWVTI68j9pRzmSy+hMkSFbgN9EGMSXxGcNunY7ewS3ZkVe08SWFpiX9giYq6uiOiMHsZKdcP6s2QRXUhZlTx2cOc/9gJ5lD82EUXQRZzT6ww2xVrceIW9c3CZFmSmYWxvrR7dPcHrke90FPPd5WhU+Anz++6GsT6+OhZTk+uQnBHllFXn9NoFQIEUDO4zV+gFXITaAbTkLAcCwuKB2QcDZ6C2mhf ansible-generated on ansible-v2 - allow_sudo: true - allow_passwordless_sudo: true diff --git a/group_vars/pbs.yml b/group_vars/pbs.yml index f1abbd22..6c02e8db 100644 --- a/group_vars/pbs.yml +++ b/group_vars/pbs.yml @@ -1,32 +1,32 @@ --- - ### mgrote.postfix - postfix_erlaubte_netzwerke: "127.0.0.0/8 192.168.2.0/24 192.168.3.0/24" +### mgrote.postfix +postfix_erlaubte_netzwerke: "127.0.0.0/8 192.168.2.0/24 192.168.3.0/24" - ### mgrote.restic - restic_folders_to_backup: "/ /etc/proxmox-backup" +### mgrote.restic +restic_folders_to_backup: "/ /etc/proxmox-backup" - ### mgrote.user - users: - - username: root - password: "{{ lookup('keepass', 'root_linux_password_hash_proxmox', 'password') }}" - update_password: always - groups: ssh, sudo, root - state: present - allow_sudo: true - allow_passwordless_sudo: true - - username: mg - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: "{{ ssh_public_key_mg }}" - allow_sudo: true - allow_passwordless_sudo: true - - username: ansible-user - password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu - allow_sudo: true - allow_passwordless_sudo: true +### mgrote.user +users: + - username: root + password: "{{ lookup('keepass', 'root_linux_password_hash_proxmox', 'password') }}" + update_password: always + groups: ssh, sudo, root + state: present + allow_sudo: true + allow_passwordless_sudo: true + - username: mg + password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: "{{ ssh_public_key_mg }}" + allow_sudo: true + allow_passwordless_sudo: true + - username: ansible-user + password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu + allow_sudo: true + allow_passwordless_sudo: true diff --git a/group_vars/pve.yml b/group_vars/pve.yml index 198657d8..380c9560 100644 --- a/group_vars/pve.yml +++ b/group_vars/pve.yml @@ -1,40 +1,41 @@ --- - ### mgrote.restic - restic_folders_to_backup: "/ /etc/pve" - ### mgrote.user - users: - - username: root - password: "{{ lookup('keepass', 'root_linux_password_hash_proxmox', 'password') }}" - update_password: always - groups: ssh, sudo, root - state: present - allow_sudo: true - allow_passwordless_sudo: true - - username: mg - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: "{{ ssh_public_key_mg }}" - allow_sudo: true - allow_passwordless_sudo: true - - username: ansible-user - password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" - update_password: always - groups: ssh, sudo - state: present - public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu - allow_sudo: true - allow_passwordless_sudo: true +### mgrote.restic +restic_folders_to_backup: "/ /etc/pve" - ### mgrote.apt_manage_packages - apt_packages_extra: - - ifupdown2 - - bmon - - qemu-guest-agent - - open-vm-tools - - systemd-boot +### mgrote.user +users: + - username: root + password: "{{ lookup('keepass', 'root_linux_password_hash_proxmox', 'password') }}" + update_password: always + groups: ssh, sudo, root + state: present + allow_sudo: true + allow_passwordless_sudo: true + - username: mg + password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: "{{ ssh_public_key_mg }}" + allow_sudo: true + allow_passwordless_sudo: true + - username: ansible-user + password: "{{ lookup('keepass', 'ansible_user_linux_password_hash', 'password') }}" + update_password: always + groups: ssh, sudo + state: present + public_ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJcBwOjanQV6sFWaTetqpl20SVe3aRzGjKbsp7hKkDCE mg@irantu + allow_sudo: true + allow_passwordless_sudo: true - # Ansible Variablen - ### sudo - sudo: false +### mgrote.apt_manage_packages +apt_packages_extra: + - ifupdown2 + - bmon + - qemu-guest-agent + - open-vm-tools + - systemd-boot + +# Ansible Variablen +### sudo +sudo: false diff --git a/host_vars/docker10.grote.lan.yml b/host_vars/docker10.grote.lan.yml index ce4826cf..0beef40a 100644 --- a/host_vars/docker10.grote.lan.yml +++ b/host_vars/docker10.grote.lan.yml @@ -1,71 +1,73 @@ --- - ### mrlesmithjr.ansible-manage-lvm - lvm_groups: - - vgname: vg_docker - disks: - - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 - create: true - lvnames: - - lvname: docker - size: +100%FREE - create: true - filesystem: xfs - mount: true - mntp: /var/lib/docker - manage_lvm: true - pvresize_to_max: true - ### mgrote.restic - restic_folders_to_backup: "/ /var/lib/docker /mnt/oci-registry" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben +### mrlesmithjr.ansible-manage-lvm +lvm_groups: + - vgname: vg_docker + disks: + - /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 + create: true + lvnames: + - lvname: docker + size: +100%FREE + create: true + filesystem: xfs + mount: true + mntp: /var/lib/docker +manage_lvm: true +pvresize_to_max: true - ### mgrote.docker-compose-inline - compose_owner: "docker-user" - compose_group: "docker-user" - compose_file_permissions: "644" - compose_dir_permissions: "755" - compose_dest_basedir: "/docker" - compose_src_basedir: "{{ inventory_dir }}/docker-compose" - compose_files: - - name: homer - state: present - - name: drone - state: present - - name: nextcloud - state: present - network: traefik - - name: httpd - state: present - - name: unifi-controller - state: present - - name: miniflux - state: present - network: traefik - - name: traefik - state: present - network: traefik - - name: navidrome - state: present - network: traefik - - name: watchtower - state: present - - name: routeros-config-export - state: present - - name: registry - state: present - network: traefik - - name: whoami - state: absent - network: traefik - ### oefenweb.ufw - ufw_rules: - - rule: allow - to_port: 22 - protocol: tcp - comment: 'ssh' - from_ip: 0.0.0.0/0 - # docker network inspect $(docker network ls -q)|grep -E "IPv(4|6)A" | grep -v \"\" | sort -h - - rule: allow - from_ip: 192.168.0.0/16 - comment: 'docker networks' - - rule: allow - from_ip: 172.0.0.0/8 - comment: 'docker networks' +### mgrote.restic +restic_folders_to_backup: "/ /var/lib/docker /mnt/oci-registry" # --one-file-system ist gesetzt, also werden weitere Dateisysteme nicht eingeschlossen, es sei denn sie werden hier explizit angegeben + +### mgrote.docker-compose-inline +compose_owner: "docker-user" +compose_group: "docker-user" +compose_file_permissions: "644" +compose_dir_permissions: "755" +compose_dest_basedir: "/docker" +compose_src_basedir: "{{ inventory_dir }}/docker-compose" +compose_files: + - name: homer + state: present + - name: drone + state: present + - name: nextcloud + state: present + network: traefik + - name: httpd + state: present + - name: unifi-controller + state: present + - name: miniflux + state: present + network: traefik + - name: traefik + state: present + network: traefik + - name: navidrome + state: present + network: traefik + - name: watchtower + state: present + - name: routeros-config-export + state: present + - name: registry + state: present + network: traefik + - name: whoami + state: absent + network: traefik + +### oefenweb.ufw +ufw_rules: + - rule: allow + to_port: 22 + protocol: tcp + comment: 'ssh' + from_ip: 0.0.0.0/0 + # docker network inspect $(docker network ls -q)|grep -E "IPv(4|6)A" | grep -v \"\" | sort -h + - rule: allow + from_ip: 192.168.0.0/16 + comment: 'docker networks' + - rule: allow + from_ip: 172.0.0.0/8 + comment: 'docker networks' diff --git a/host_vars/k3s4.grote.lan.yml b/host_vars/k3s4.grote.lan.yml index b056ad12..752c9f70 100644 --- a/host_vars/k3s4.grote.lan.yml +++ b/host_vars/k3s4.grote.lan.yml @@ -1,3 +1,3 @@ --- - ### pyratlabs.k3s - k3s_control_node: true +### pyratlabs.k3s +k3s_control_node: true diff --git a/host_vars/pbs-test.grote.lan.yml b/host_vars/pbs-test.grote.lan.yml index fd03b8e0..6af3efe5 100644 --- a/host_vars/pbs-test.grote.lan.yml +++ b/host_vars/pbs-test.grote.lan.yml @@ -1,167 +1,168 @@ --- - # pbs_* - pbs_datastores: - - name: zfs_backup - path: /backup/pbs_data - gc_schedule: "sat 19:00" +# pbs_* +pbs_datastores: + - name: zfs_backup + path: /backup/pbs_data + gc_schedule: "sat 19:00" - pbs_prune_jobs: - - name: standard - schedule: "sat 18:15" - store: zfs_backup - keep_last: 3 - keep_hourly: 24 - keep_daily: 7 - keep_weekly: 2 +pbs_prune_jobs: + - name: standard + schedule: "sat 18:15" + store: zfs_backup + keep_last: 3 + keep_hourly: 24 + keep_daily: 7 + keep_weekly: 2 - pbs_permissions: - - user: user_pve5-test@pbs - datastore: zfs_backup - role: DatastoreBackup +pbs_permissions: + - user: user_pve5-test@pbs + datastore: zfs_backup + role: DatastoreBackup - pbs_users: - - name: user_pve5 - password: "{{ lookup('keepass', 'pbs_pve_user', 'password') }}" - realm: pbs - - name: user_pve5-test - password: "{{ lookup('keepass', 'pbs_pve_user-test', 'password') }}" - realm: pbs - # rpool ist unverschlüsselt als Boot-Medium - # entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l +pbs_users: + - name: user_pve5 + password: "{{ lookup('keepass', 'pbs_pve_user', 'password') }}" + realm: pbs + - name: user_pve5-test + password: "{{ lookup('keepass', 'pbs_pve_user-test', 'password') }}" + realm: pbs +# rpool ist unverschlüsselt als Boot-Medium +# entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l - ## backup - ### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase backup /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 +## backup +### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase backup /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1 - # mgrote.zfs_manage_datasets - ### mgrote.zfs_extra - # Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* - zfs_datasets: # DatenPools werden hier nicht verwaltet - # rpool - System-Datasets - - dataset: rpool - state: present - compression: zstd - sync: disabled - xattr: sa - dnodesize: auto - atime: on - snapdir: hidden - reservation: 1G - refreservation: 1G - - dataset: rpool/ROOT - state: present - refreservation: 1G - - dataset: rpool/ROOT/pbs-1 - state: present - refreservation: 1G - # backup-pool - - dataset: backup/pbs_data - state: present - quota: 10GB - - dataset: backup/pve5 - state: present - canmount: off - # Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* - zfs_extra_arc_max_size: "1073741824" # 1GB in Bytes - zfs_extra_zfs_pools: - - name: "rpool" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals - - name: "backup" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" +# mgrote.zfs_manage_datasets +### mgrote.zfs_extra +# Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* +zfs_datasets: # DatenPools werden hier nicht verwaltet + # rpool - System-Datasets + - dataset: rpool + state: present + compression: zstd + sync: disabled + xattr: sa + dnodesize: auto + atime: on # noqa yaml[truthy] + snapdir: hidden + reservation: 1G + refreservation: 1G + - dataset: rpool/ROOT + state: present + refreservation: 1G + - dataset: rpool/ROOT/pbs-1 + state: present + refreservation: 1G + # backup-pool + - dataset: backup/pbs_data + state: present + quota: 10GB + - dataset: backup/pve5 + state: present + canmount: off # noqa yaml[truthy] +# Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* +zfs_extra_arc_max_size: "1073741824" # 1GB in Bytes +zfs_extra_zfs_pools: + - name: "rpool" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals + - name: "backup" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" - ### mgrote.zfs_sanoid - sanoid_snaps_enable: true - ## syncoid - sanoid_syncoid_destination_host: false - sanoid_syncoid_ssh_privkey: "{{ lookup('keepass', 'sanoid_syncoid_private_key', 'notes') }}" - sanoid_syncoid_timer: '*-*-* *:00:00' # jede Stunde - sanoid_syncoid_bwlimit: 30m # 30MB/s - sanoid_syncoid_datasets_sync: - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/pve_backup - source_dataset: hdd_data_raidz/pve_backup +### mgrote.zfs_sanoid +sanoid_snaps_enable: true - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/videos - source_dataset: hdd_data_raidz/videos +## syncoid +sanoid_syncoid_destination_host: false +sanoid_syncoid_ssh_privkey: "{{ lookup('keepass', 'sanoid_syncoid_private_key', 'notes') }}" +sanoid_syncoid_timer: '*-*-* *:00:00' # jede Stunde +sanoid_syncoid_bwlimit: 30m # 30MB/s +sanoid_syncoid_datasets_sync: + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/pve_backup + source_dataset: hdd_data_raidz/pve_backup - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/music - source_dataset: hdd_data_raidz/music + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/videos + source_dataset: hdd_data_raidz/videos - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/tmp - source_dataset: hdd_data_raidz/tmp + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/music + source_dataset: hdd_data_raidz/music - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/archiv - source_dataset: hdd_data_raidz/archiv + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/tmp + source_dataset: hdd_data_raidz/tmp - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/bilder - source_dataset: hdd_data_raidz/bilder + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/archiv + source_dataset: hdd_data_raidz/archiv - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/hm - source_dataset: hdd_data_raidz/hm + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/bilder + source_dataset: hdd_data_raidz/bilder - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/scans - source_dataset: hdd_data_raidz/scans + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/hm + source_dataset: hdd_data_raidz/hm - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/restic - source_dataset: hdd_data_raidz/restic + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/scans + source_dataset: hdd_data_raidz/scans - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/backup - source_dataset: hdd_data_raidz/backup + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/restic + source_dataset: hdd_data_raidz/restic - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/buecher - source_dataset: hdd_data_raidz/buecher + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/backup + source_dataset: hdd_data_raidz/backup - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/programme - source_dataset: hdd_data_raidz/programme + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/buecher + source_dataset: hdd_data_raidz/buecher - - source_host: pve5.grote.lan - destination_mount_check: backup - destination_dataset: backup/pve5/vm - source_dataset: hdd_data_raidz/vm + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/programme + source_dataset: hdd_data_raidz/programme - # sanoid - sanoid_datasets: - ### rpool - - path: rpool - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT/pbs-1 - recursive: 'no' - snapshots: true - template: 'pve3tage' - ### backup - - path: backup - recursive: 'no' - snapshots: true - template: '14tage' - - path: backup/pbs_data - recursive: 'no' - snapshots: true - template: '14tage' + - source_host: pve5.grote.lan + destination_mount_check: backup + destination_dataset: backup/pve5/vm + source_dataset: hdd_data_raidz/vm + +# sanoid +sanoid_datasets: + ### rpool + - path: rpool + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT/pbs-1 + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + ### backup + - path: backup + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: backup/pbs_data + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' diff --git a/host_vars/pbs.grote.lan.yml b/host_vars/pbs.grote.lan.yml index 11a8f0de..cdd02de2 100644 --- a/host_vars/pbs.grote.lan.yml +++ b/host_vars/pbs.grote.lan.yml @@ -1,159 +1,159 @@ --- - # pbs_* - pbs_datastores: - - name: zfs_backup - path: /backup/pbs_data - gc_schedule: "sat 19:00" +# pbs_* +pbs_datastores: + - name: zfs_backup + path: /backup/pbs_data + gc_schedule: "sat 19:00" - pbs_prune_jobs: - - name: standard - schedule: "sat 18:15" - store: zfs_backup - keep_last: 1 - keep_hourly: 3 - keep_daily: 3 +pbs_prune_jobs: + - name: standard + schedule: "sat 18:15" + store: zfs_backup + keep_last: 1 + keep_hourly: 3 + keep_daily: 3 - pbs_permissions: - - user: user_pve5@pbs - datastore: zfs_backup - role: DatastoreBackup +pbs_permissions: + - user: user_pve5@pbs + datastore: zfs_backup + role: DatastoreBackup - pbs_users: - - name: user_pve5 - password: "{{ lookup('keepass', 'pbs_pve_user', 'password') }}" - realm: pbs - # rpool ist unverschlüsselt als Boot-Medium - # entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l +pbs_users: + - name: user_pve5 + password: "{{ lookup('keepass', 'pbs_pve_user', 'password') }}" + realm: pbs +# rpool ist unverschlüsselt als Boot-Medium +# entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l - ## backup - ### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase backup /dev/disk/by-id/ata-TOSHIBA_MG09ACA18TE_Z1B0A28LFJDH +## backup +### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase backup /dev/disk/by-id/ata-TOSHIBA_MG09ACA18TE_Z1B0A28LFJDH - # mgrote.zfs_manage_datasets - ### mgrote.zfs_extra - # Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* - zfs_datasets: # DatenPools werden hier nicht verwaltet - # rpool - System-Datasets - - dataset: rpool - state: present - compression: zstd - sync: disabled - xattr: sa - dnodesize: auto - atime: on - snapdir: hidden - reservation: 1G - refreservation: 10G - - dataset: rpool/ROOT - state: present - refreservation: 10G - - dataset: rpool/ROOT/pbs-1 - state: present - refreservation: 10G - # backup-pool - - dataset: backup/pbs_data - state: present - quota: 1TB - - dataset: backup/pve5 - state: present - canmount: off - # Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* - zfs_extra_arc_max_size: "4294967296" # 4GB in Bytes - zfs_extra_zfs_pools: - - name: "rpool" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals - - name: "backup" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" +# mgrote.zfs_manage_datasets +### mgrote.zfs_extra +# Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* +zfs_datasets: # DatenPools werden hier nicht verwaltet + # rpool - System-Datasets + - dataset: rpool + state: present + compression: zstd + sync: disabled + xattr: sa + dnodesize: auto + atime: on # noqa yaml[truthy] + snapdir: hidden + reservation: 1G + refreservation: 10G + - dataset: rpool/ROOT + state: present + refreservation: 10G + - dataset: rpool/ROOT/pbs-1 + state: present + refreservation: 10G + # backup-pool + - dataset: backup/pbs_data + state: present + quota: 1TB + - dataset: backup/pve5 + state: present + canmount: off # noqa yaml[truthy] +# Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* +zfs_extra_arc_max_size: "4294967296" # 4GB in Bytes +zfs_extra_zfs_pools: + - name: "rpool" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals + - name: "backup" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" - ### mgrote.zfs_sanoid - sanoid_snaps_enable: true - ## syncoid - sanoid_syncoid_destination_host: true - sanoid_syncoid_ssh_privkey: "{{ lookup('keepass', 'sanoid_syncoid_private_key', 'notes') }}" - sanoid_syncoid_timer: '*-*-* *:00:00' # jede Stunde - sanoid_syncoid_bwlimit: 50M # 30MB/s - sanoid_syncoid_datasets_sync: - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/pve_backup - source_dataset: hdd_data_raidz/pve_backup +### mgrote.zfs_sanoid +sanoid_snaps_enable: true +## syncoid +sanoid_syncoid_destination_host: true +sanoid_syncoid_ssh_privkey: "{{ lookup('keepass', 'sanoid_syncoid_private_key', 'notes') }}" +sanoid_syncoid_timer: '*-*-* *:00:00' # jede Stunde +sanoid_syncoid_bwlimit: 50M # 30MB/s +sanoid_syncoid_datasets_sync: + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/pve_backup + source_dataset: hdd_data_raidz/pve_backup - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/videos - source_dataset: hdd_data_raidz/videos + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/videos + source_dataset: hdd_data_raidz/videos - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/music - source_dataset: hdd_data_raidz/music + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/music + source_dataset: hdd_data_raidz/music - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/tmp - source_dataset: hdd_data_raidz/tmp + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/tmp + source_dataset: hdd_data_raidz/tmp - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/archiv - source_dataset: hdd_data_raidz/archiv + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/archiv + source_dataset: hdd_data_raidz/archiv - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/bilder - source_dataset: hdd_data_raidz/bilder + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/bilder + source_dataset: hdd_data_raidz/bilder - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/hm - source_dataset: hdd_data_raidz/hm + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/hm + source_dataset: hdd_data_raidz/hm - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/scans - source_dataset: hdd_data_raidz/scans + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/scans + source_dataset: hdd_data_raidz/scans - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/restic - source_dataset: hdd_data_raidz/restic + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/restic + source_dataset: hdd_data_raidz/restic - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/backup - source_dataset: hdd_data_raidz/backup + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/backup + source_dataset: hdd_data_raidz/backup - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/buecher - source_dataset: hdd_data_raidz/buecher + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/buecher + source_dataset: hdd_data_raidz/buecher - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/programme - source_dataset: hdd_data_raidz/programme + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/programme + source_dataset: hdd_data_raidz/programme - - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann - destination_mount_check: backup - destination_dataset: backup/pve5/vm - source_dataset: hdd_data_raidz/vm + - source_host: 192.168.2.16 # pve5, weil pbs den fqdn nicht auflösen kann + destination_mount_check: backup + destination_dataset: backup/pve5/vm + source_dataset: hdd_data_raidz/vm - # sanoid - sanoid_datasets: - ### rpool - - path: rpool - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT/pbs-1 - recursive: 'no' - snapshots: true - template: 'pve3tage' - ### backup - - path: backup/pbs_data - recursive: 'no' - snapshots: true - template: '3tage' +# sanoid +sanoid_datasets: + ### rpool + - path: rpool + recursive: 'no' + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT + recursive: 'no' + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT/pbs-1 + recursive: 'no' + snapshots: true + template: 'pve3tage' + ### backup + - path: backup/pbs_data + recursive: 'no' + snapshots: true + template: '3tage' diff --git a/host_vars/pve5-test.grote.lan.yml b/host_vars/pve5-test.grote.lan.yml index 44e5aa23..afa74ae4 100644 --- a/host_vars/pve5-test.grote.lan.yml +++ b/host_vars/pve5-test.grote.lan.yml @@ -1,232 +1,232 @@ --- - # rpool ist unverschlüsselt als Boot-Medium - # der Speicherort fur die VMs ist verschlüsselt - # zfs create -o encryption=aes-256-gcm -o keyformat=passphrase rpool/vm - # entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l - ## HDD_DATA_RAIDZ - ### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase hdd_data_raidz mirror /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi3 /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi2 +# rpool ist unverschlüsselt als Boot-Medium +# der Speicherort fur die VMs ist verschlüsselt +# zfs create -o encryption=aes-256-gcm -o keyformat=passphrase rpool/vm +# entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l +## HDD_DATA_RAIDZ +### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase hdd_data_raidz mirror /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi3 /dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi2 - # mgrote.zfs_manage_datasets - ### mgrote.zfs_extra - # Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* - zfs_datasets: # DatenPools werden hier nicht verwaltet - # rpool - System-Datasets - - dataset: rpool - state: present - compression: zstd - sync: disabled - xattr: sa - dnodesize: auto - atime: on - snapdir: hidden - reservation: 1G - refreservation: 1G - - dataset: rpool/ROOT - state: present - refreservation: 1G - - dataset: rpool/ROOT/pve-1 - state: present - refreservation: 1G +# mgrote.zfs_manage_datasets +### mgrote.zfs_extra +# Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* +zfs_datasets: # DatenPools werden hier nicht verwaltet + # rpool - System-Datasets + - dataset: rpool + state: present + compression: zstd + sync: disabled + xattr: sa + dnodesize: auto + atime: on # noqa yaml[truthy] + snapdir: hidden + reservation: 1G + refreservation: 1G + - dataset: rpool/ROOT + state: present + refreservation: 1G + - dataset: rpool/ROOT/pve-1 + state: present + refreservation: 1G - # rpool - VMs - - dataset: rpool/vm - state: present - - dataset: rpool/vm/zvol - state: present - - dataset: rpool/vm/lxc - state: present - # hdd_data_raidz - - dataset: hdd_data_raidz - state: present - compression: zstd - sync: disabled - xattr: sa - dnodesize: auto - atime: on - snapdir: hidden - reservation: 1G - - dataset: hdd_data_raidz/papa_backup - state: present - - dataset: hdd_data_raidz/pve_backup - state: present - recordsize: 1M - - dataset: hdd_data_raidz/videos - state: present - recordsize: 1M - - dataset: hdd_data_raidz/music - state: present - recordsize: 1M - - dataset: hdd_data_raidz/tmp - state: present - - dataset: hdd_data_raidz/archiv - state: present - - dataset: hdd_data_raidz/bilder - state: present - recordsize: 1M - - dataset: hdd_data_raidz/hm - state: present - - dataset: hdd_data_raidz/scans - state: present - - dataset: hdd_data_raidz/restic - state: present - - dataset: hdd_data_raidz/backup - state: present - - dataset: hdd_data_raidz/buecher - state: present - - dataset: hdd_data_raidz/programme - state: present - - dataset: hdd_data_raidz/vm - state: present + # rpool - VMs + - dataset: rpool/vm + state: present + - dataset: rpool/vm/zvol + state: present + - dataset: rpool/vm/lxc + state: present + # hdd_data_raidz + - dataset: hdd_data_raidz + state: present + compression: zstd + sync: disabled + xattr: sa + dnodesize: auto + atime: on # noqa yaml[truthy] + snapdir: hidden + reservation: 1G + - dataset: hdd_data_raidz/papa_backup + state: present + - dataset: hdd_data_raidz/pve_backup + state: present + recordsize: 1M + - dataset: hdd_data_raidz/videos + state: present + recordsize: 1M + - dataset: hdd_data_raidz/music + state: present + recordsize: 1M + - dataset: hdd_data_raidz/tmp + state: present + - dataset: hdd_data_raidz/archiv + state: present + - dataset: hdd_data_raidz/bilder + state: present + recordsize: 1M + - dataset: hdd_data_raidz/hm + state: present + - dataset: hdd_data_raidz/scans + state: present + - dataset: hdd_data_raidz/restic + state: present + - dataset: hdd_data_raidz/backup + state: present + - dataset: hdd_data_raidz/buecher + state: present + - dataset: hdd_data_raidz/programme + state: present + - dataset: hdd_data_raidz/vm + state: present - zfs_extra_arc_max_size: "1073741824" # 1GB in Bytes - zfs_extra_zfs_pools: - - name: "rpool" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals - - name: "hdd_data_raidz" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" +zfs_extra_arc_max_size: "1073741824" # 1GB in Bytes +zfs_extra_zfs_pools: + - name: "rpool" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals + - name: "hdd_data_raidz" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" - ### mgrote.zfs_sanoid - sanoid_datasets: - - path: 'hdd_data_raidz/videos' - template: '3tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/music' - template: '14tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/papa_backup' - template: '14tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/tmp' - template: '3tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/pve_backup' - template: '3tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/archiv' - template: '14tage' - recursive: 'yes' - snapshots: true - - path: hdd_data_raidz/bilder - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/hm - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/scans - recursive: 'no' - snapshots: true - template: '3tage' - - path: hdd_data_raidz/backup - recursive: 'no' - snapshots: true - template: '31tage' - - path: hdd_data_raidz/restic - recursive: 'no' - snapshots: true - template: '3tage' - - path: hdd_data_raidz/programme - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/buecher - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/vm - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT/pve-1 - recursive: 'no' - snapshots: true - template: '3tage' +### mgrote.zfs_sanoid +sanoid_datasets: + - path: 'hdd_data_raidz/videos' + template: '3tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/music' + template: '14tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/papa_backup' + template: '14tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/tmp' + template: '3tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/pve_backup' + template: '3tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/archiv' + template: '14tage' + recursive: 'yes' + snapshots: true + - path: hdd_data_raidz/bilder + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/hm + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/scans + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '3tage' + - path: hdd_data_raidz/backup + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '31tage' + - path: hdd_data_raidz/restic + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '3tage' + - path: hdd_data_raidz/programme + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/buecher + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/vm + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT/pve-1 + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '3tage' - ### mgrote.cv4pve-autosnap - cv4pve_api_user: root@pam!cv4pve-autosnap - cv4pve_api_token: "{{ lookup('keepass', 'cv4pve_api_token', 'password') }}" - cv4pve_vmid: all - cv4pve_keep_snapshots: 5 - cv4pve_dl_link: "https://github.com/Corsinvest/cv4pve-autosnap/releases/download/v1.10.0/cv4pve-autosnap-linux-x64.zip" +### mgrote.cv4pve-autosnap +cv4pve_api_user: root@pam!cv4pve-autosnap +cv4pve_api_token: "{{ lookup('keepass', 'cv4pve_api_token', 'password') }}" +cv4pve_vmid: all +cv4pve_keep_snapshots: 5 +cv4pve_dl_link: "https://github.com/Corsinvest/cv4pve-autosnap/releases/download/v1.10.0/cv4pve-autosnap-linux-x64.zip" - ### mgrote.proxmox_bind_mounts - pve_bind_mounts: - - vmid: 100 - mp_nr: 0 - mp_path_host: /hdd_data_raidz/videos - mp_path_guest: /shares_videos - - vmid: 100 - mp_nr: 2 - mp_path_host: /hdd_data_raidz/pve_backup - mp_path_guest: /shares_pve_backup - - vmid: 100 - mp_nr: 3 - mp_path_host: /hdd_data_raidz/papa_backup - mp_path_guest: /shares_papa_backup - - vmid: 100 - mp_nr: 4 - mp_path_host: /hdd_data_raidz/music - mp_path_guest: /shares_music - - vmid: 100 - mp_nr: 5 - mp_path_host: /hdd_data_raidz/tmp - mp_path_guest: /shares_tmp - - vmid: 100 - mp_nr: 6 - mp_path_host: /hdd_data_raidz/archiv - mp_path_guest: /shares_archiv - - vmid: 100 - mp_nr: 7 - mp_path_host: /hdd_data_raidz/bilder - mp_path_guest: /shares_bilder - - vmid: 100 - mp_nr: 8 - mp_path_host: /hdd_data_raidz/hm - mp_path_guest: /shares_hm - - vmid: 100 - mp_nr: 9 - mp_path_host: /hdd_data_raidz/scans - mp_path_guest: /shares_scans - - vmid: 100 - mp_nr: 10 - mp_path_host: /hdd_data_raidz/restic - mp_path_guest: /shares_restic - - vmid: 100 - mp_nr: 12 - mp_path_host: /hdd_data_raidz/backup - mp_path_guest: /shares_backup - - vmid: 100 - mp_nr: 14 - mp_path_host: /hdd_data_raidz/buecher - mp_path_guest: /shares_buecher - - vmid: 100 - mp_nr: 15 - mp_path_host: /hdd_data_raidz/programme - mp_path_guest: /shares_programme - - vmid: 100 - mp_nr: 16 - mp_path_host: /hdd_data_raidz/vm - mp_path_guest: /shares_vm +### mgrote.proxmox_bind_mounts +pve_bind_mounts: + - vmid: 100 + mp_nr: 0 + mp_path_host: /hdd_data_raidz/videos + mp_path_guest: /shares_videos + - vmid: 100 + mp_nr: 2 + mp_path_host: /hdd_data_raidz/pve_backup + mp_path_guest: /shares_pve_backup + - vmid: 100 + mp_nr: 3 + mp_path_host: /hdd_data_raidz/papa_backup + mp_path_guest: /shares_papa_backup + - vmid: 100 + mp_nr: 4 + mp_path_host: /hdd_data_raidz/music + mp_path_guest: /shares_music + - vmid: 100 + mp_nr: 5 + mp_path_host: /hdd_data_raidz/tmp + mp_path_guest: /shares_tmp + - vmid: 100 + mp_nr: 6 + mp_path_host: /hdd_data_raidz/archiv + mp_path_guest: /shares_archiv + - vmid: 100 + mp_nr: 7 + mp_path_host: /hdd_data_raidz/bilder + mp_path_guest: /shares_bilder + - vmid: 100 + mp_nr: 8 + mp_path_host: /hdd_data_raidz/hm + mp_path_guest: /shares_hm + - vmid: 100 + mp_nr: 9 + mp_path_host: /hdd_data_raidz/scans + mp_path_guest: /shares_scans + - vmid: 100 + mp_nr: 10 + mp_path_host: /hdd_data_raidz/restic + mp_path_guest: /shares_restic + - vmid: 100 + mp_nr: 12 + mp_path_host: /hdd_data_raidz/backup + mp_path_guest: /shares_backup + - vmid: 100 + mp_nr: 14 + mp_path_host: /hdd_data_raidz/buecher + mp_path_guest: /shares_buecher + - vmid: 100 + mp_nr: 15 + mp_path_host: /hdd_data_raidz/programme + mp_path_guest: /shares_programme + - vmid: 100 + mp_nr: 16 + mp_path_host: /hdd_data_raidz/vm + mp_path_guest: /shares_vm - # mgrote.pbs_pve_integration - pve_pbs_datastore: - - name: pbs - server: 192.168.2.18 - datastore: zfs_backup - username: user_pve5-test@pbs - password: "{{ lookup('keepass', 'pbs_pve_user-test', 'password') }}" - fingerprint: "38:53:f6:1e:99:99:76:78:c4:00:dd:90:1a:89:47:56:97:4e:f3:62:01:d2:2c:76:ba:f8:55:be:f8:05:d1:7a" +# mgrote.pbs_pve_integration +pve_pbs_datastore: + - name: pbs + server: 192.168.2.18 + datastore: zfs_backup + username: user_pve5-test@pbs + password: "{{ lookup('keepass', 'pbs_pve_user-test', 'password') }}" + fingerprint: "38:53:f6:1e:99:99:76:78:c4:00:dd:90:1a:89:47:56:97:4e:f3:62:01:d2:2c:76:ba:f8:55:be:f8:05:d1:7a" diff --git a/host_vars/pve5.grote.lan.yml b/host_vars/pve5.grote.lan.yml index 0ae4b8f8..659b0fc3 100644 --- a/host_vars/pve5.grote.lan.yml +++ b/host_vars/pve5.grote.lan.yml @@ -1,243 +1,243 @@ ---- - # rpool ist unverschlüsselt als Boot-Medium - # der Speicherort fur die VMs ist verschlüsselt - # zfs create -o encryption=aes-256-gcm -o keyformat=passphrase rpool/vm - # entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l - ## HDD_DATA_RAIDZ - ### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase hdd_data_raidz mirror /dev/disk/by-id/ata-TOSHIBA_MG09ACA18TE_Z1B0A27KFJDH /dev/disk/by-id/ata-TOSHIBA_MG09ACA18TE_Z1B0A28LFJDH + # noqa yaml[truthy]--- +# rpool ist unverschlüsselt als Boot-Medium +# der Speicherort fur die VMs ist verschlüsselt +# zfs create -o encryption=aes-256-gcm -o keyformat=passphrase rpool/vm +# entschlüsseln nach Boot mit: sudo zpool import -d /dev/disk/by-id/ -a && sudo zfs mount -a -l +## HDD_DATA_RAIDZ +### sudo zpool create -o ashift=12 -o feature@encryption=enabled -O encryption=on -O keylocation=prompt -O keyformat=passphrase hdd_data_raidz mirror /dev/disk/by-id/ata-TOSHIBA_MG09ACA18TE_Z1B0A27KFJDH /dev/disk/by-id/ata-TOSHIBA_MG09ACA18TE_Z1B0A28LFJDH - # mgrote.zfs_manage_datasets - ### mgrote.zfs_extra - # Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* - zfs_datasets: # DatenPools werden hier nicht verwaltet - # rpool - System-Datasets - - dataset: rpool - state: present - compression: zstd - sync: disabled - xattr: sa - dnodesize: auto - atime: on - snapdir: hidden - reservation: 1G - refreservation: 10G - - dataset: rpool/ROOT - state: present - refreservation: 10G - - dataset: rpool/ROOT/pve-1 - state: present - refreservation: 10G - # rpool - Data - - dataset: rpool/data - state: present - # rpool - VMs - - dataset: rpool/vm - state: present - - dataset: rpool/vm/zvol - state: present - - dataset: rpool/vm/lxc - state: present - - dataset: rpool/data - state: present - # hdd_data_raidz - - dataset: hdd_data_raidz - state: present - compression: zstd - sync: disabled - xattr: sa - dnodesize: auto - atime: on - snapdir: hidden - reservation: 1G - - dataset: hdd_data_raidz/papa_backup - state: present - - dataset: hdd_data_raidz/pve_backup - state: present - recordsize: 1M - - dataset: hdd_data_raidz/videos - state: present - recordsize: 1M - - dataset: hdd_data_raidz/music - state: present - recordsize: 1M - - dataset: hdd_data_raidz/tmp - state: present - - dataset: hdd_data_raidz/archiv - state: present - - dataset: hdd_data_raidz/bilder - state: present - recordsize: 1M - - dataset: hdd_data_raidz/hm - state: present - - dataset: hdd_data_raidz/scans - state: present - - dataset: hdd_data_raidz/restic - state: present - - dataset: hdd_data_raidz/backup - state: present - - dataset: hdd_data_raidz/buecher - state: present - - dataset: hdd_data_raidz/programme - state: present - - dataset: hdd_data_raidz/vm - state: present +# mgrote.zfs_manage_datasets +### mgrote.zfs_extra +# Variablen für mgrote.zfs_health/trim/scrub/zed/arc_mem/ sind zusammengefasst unter zfs_extra_* +zfs_datasets: # DatenPools werden hier nicht verwaltet + # rpool - System-Datasets + - dataset: rpool + state: present + compression: zstd + sync: disabled + xattr: sa + dnodesize: auto + atime: on # noqa yaml[truthy] + snapdir: hidden + reservation: 1G + refreservation: 10G + - dataset: rpool/ROOT + state: present + refreservation: 10G + - dataset: rpool/ROOT/pve-1 + state: present + refreservation: 10G + # rpool - Data + - dataset: rpool/data + state: present + # rpool - VMs + - dataset: rpool/vm + state: present + - dataset: rpool/vm/zvol + state: present + - dataset: rpool/vm/lxc + state: present + - dataset: rpool/data + state: present + # hdd_data_raidz + - dataset: hdd_data_raidz + state: present + compression: zstd + sync: disabled + xattr: sa + dnodesize: auto + atime: on # noqa yaml[truthy] + snapdir: hidden + reservation: 1G + - dataset: hdd_data_raidz/papa_backup + state: present + - dataset: hdd_data_raidz/pve_backup + state: present + recordsize: 1M + - dataset: hdd_data_raidz/videos + state: present + recordsize: 1M + - dataset: hdd_data_raidz/music + state: present + recordsize: 1M + - dataset: hdd_data_raidz/tmp + state: present + - dataset: hdd_data_raidz/archiv + state: present + - dataset: hdd_data_raidz/bilder + state: present + recordsize: 1M + - dataset: hdd_data_raidz/hm + state: present + - dataset: hdd_data_raidz/scans + state: present + - dataset: hdd_data_raidz/restic + state: present + - dataset: hdd_data_raidz/backup + state: present + - dataset: hdd_data_raidz/buecher + state: present + - dataset: hdd_data_raidz/programme + state: present + - dataset: hdd_data_raidz/vm + state: present - zfs_extra_arc_max_size: "8589934592" # 8GB in Bytes - zfs_extra_zfs_pools: - - name: "rpool" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals - - name: "hdd_data_raidz" - systemd_timer_schedule: "*-01,04,07,10-01 23:00" +zfs_extra_arc_max_size: "8589934592" # 8GB in Bytes +zfs_extra_zfs_pools: + - name: "rpool" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" # jeden ersten eines jeden Quartals + - name: "hdd_data_raidz" + systemd_timer_schedule: "*-01,04,07,10-01 23:00" - ### mgrote.zfs_sanoid - sanoid_snaps_enable: true - ## enable sending snaps - sanoid_syncoid_source_host: true - sanoid_syncoid_ssh_pubkey: "{{ lookup('keepass', 'sanoid_syncoid_public_key', 'notes') }}" - sanoid_datasets: - ### hdd_data_raidz - - path: 'hdd_data_raidz/videos' - template: '3tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/music' - template: '14tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/papa_backup' - template: '14tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/tmp' - template: '3tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/pve_backup' - template: '3tage' - recursive: 'yes' - snapshots: true - - path: 'hdd_data_raidz/archiv' - template: '14tage' - recursive: 'yes' - snapshots: true - - path: hdd_data_raidz/bilder - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/hm - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/scans - recursive: 'no' - snapshots: true - template: '3tage' - - path: hdd_data_raidz/backup - recursive: 'no' - snapshots: true - template: '31tage' - - path: hdd_data_raidz/restic - recursive: 'no' - snapshots: true - template: '3tage' - - path: hdd_data_raidz/programme - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/buecher - recursive: 'no' - snapshots: true - template: '14tage' - - path: hdd_data_raidz/vm - recursive: 'no' - snapshots: true - template: '3tage' - ### rpool - - path: rpool - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT - recursive: 'no' - snapshots: true - template: 'pve3tage' - - path: rpool/ROOT/pve-1 - recursive: 'no' - snapshots: true - template: 'pve3tage' +### mgrote.zfs_sanoid +sanoid_snaps_enable: true +## enable sending snaps +sanoid_syncoid_source_host: true +sanoid_syncoid_ssh_pubkey: "{{ lookup('keepass', 'sanoid_syncoid_public_key', 'notes') }}" +sanoid_datasets: + ### hdd_data_raidz + - path: 'hdd_data_raidz/videos' + template: '3tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/music' + template: '14tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/papa_backup' + template: '14tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/tmp' + template: '3tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/pve_backup' + template: '3tage' + recursive: 'yes' + snapshots: true + - path: 'hdd_data_raidz/archiv' + template: '14tage' + recursive: 'yes' + snapshots: true + - path: hdd_data_raidz/bilder + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/hm + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/scans + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '3tage' + - path: hdd_data_raidz/backup + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '31tage' + - path: hdd_data_raidz/restic + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '3tage' + - path: hdd_data_raidz/programme + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/buecher + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '14tage' + - path: hdd_data_raidz/vm + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: '3tage' + ### rpool + - path: rpool + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' + - path: rpool/ROOT/pve-1 + recursive: 'no' # noqa yaml[truthy] + snapshots: true + template: 'pve3tage' - ### mgrote.cv4pve-autosnap - cv4pve_api_user: root@pam!cv4pve-autosnap - cv4pve_api_token: "{{ lookup('keepass', 'cv4pve_api_token', 'password') }}" - cv4pve_vmid: all,-106,-112,-115 - cv4pve_keep_snapshots: 5 - cv4pve_dl_link: "https://github.com/Corsinvest/cv4pve-autosnap/releases/download/v1.14.7/cv4pve-autosnap-linux-x64.zip" +### mgrote.cv4pve-autosnap +cv4pve_api_user: root@pam!cv4pve-autosnap +cv4pve_api_token: "{{ lookup('keepass', 'cv4pve_api_token', 'password') }}" +cv4pve_vmid: all,-106,-112,-115 +cv4pve_keep_snapshots: 5 +cv4pve_dl_link: "https://github.com/Corsinvest/cv4pve-autosnap/releases/download/v1.14.7/cv4pve-autosnap-linux-x64.zip" - ### mgrote.proxmox_bind_mounts - pve_bind_mounts: - ### fileserver3 - - vmid: 115 - mp_nr: 0 - mp_path_host: /hdd_data_raidz/videos - mp_path_guest: /shares_videos - - vmid: 115 - mp_nr: 2 - mp_path_host: /hdd_data_raidz/pve_backup - mp_path_guest: /shares_pve_backup - - vmid: 115 - mp_nr: 3 - mp_path_host: /hdd_data_raidz/papa_backup - mp_path_guest: /shares_papa_backup - - vmid: 115 - mp_nr: 4 - mp_path_host: /hdd_data_raidz/music - mp_path_guest: /shares_music - - vmid: 115 - mp_nr: 5 - mp_path_host: /hdd_data_raidz/tmp - mp_path_guest: /shares_tmp - - vmid: 115 - mp_nr: 6 - mp_path_host: /hdd_data_raidz/archiv - mp_path_guest: /shares_archiv - - vmid: 115 - mp_nr: 7 - mp_path_host: /hdd_data_raidz/bilder - mp_path_guest: /shares_bilder - - vmid: 115 - mp_nr: 8 - mp_path_host: /hdd_data_raidz/hm - mp_path_guest: /shares_hm - - vmid: 115 - mp_nr: 9 - mp_path_host: /hdd_data_raidz/scans - mp_path_guest: /shares_scans - - vmid: 115 - mp_nr: 10 - mp_path_host: /hdd_data_raidz/restic - mp_path_guest: /shares_restic - - vmid: 115 - mp_nr: 12 - mp_path_host: /hdd_data_raidz/backup - mp_path_guest: /shares_backup - - vmid: 115 - mp_nr: 14 - mp_path_host: /hdd_data_raidz/buecher - mp_path_guest: /shares_buecher - - vmid: 115 - mp_nr: 15 - mp_path_host: /hdd_data_raidz/programme - mp_path_guest: /shares_programme - - vmid: 115 - mp_nr: 16 - mp_path_host: /hdd_data_raidz/vm - mp_path_guest: /shares_vm +### mgrote.proxmox_bind_mounts +pve_bind_mounts: + ### fileserver3 + - vmid: 115 + mp_nr: 0 + mp_path_host: /hdd_data_raidz/videos + mp_path_guest: /shares_videos + - vmid: 115 + mp_nr: 2 + mp_path_host: /hdd_data_raidz/pve_backup + mp_path_guest: /shares_pve_backup + - vmid: 115 + mp_nr: 3 + mp_path_host: /hdd_data_raidz/papa_backup + mp_path_guest: /shares_papa_backup + - vmid: 115 + mp_nr: 4 + mp_path_host: /hdd_data_raidz/music + mp_path_guest: /shares_music + - vmid: 115 + mp_nr: 5 + mp_path_host: /hdd_data_raidz/tmp + mp_path_guest: /shares_tmp + - vmid: 115 + mp_nr: 6 + mp_path_host: /hdd_data_raidz/archiv + mp_path_guest: /shares_archiv + - vmid: 115 + mp_nr: 7 + mp_path_host: /hdd_data_raidz/bilder + mp_path_guest: /shares_bilder + - vmid: 115 + mp_nr: 8 + mp_path_host: /hdd_data_raidz/hm + mp_path_guest: /shares_hm + - vmid: 115 + mp_nr: 9 + mp_path_host: /hdd_data_raidz/scans + mp_path_guest: /shares_scans + - vmid: 115 + mp_nr: 10 + mp_path_host: /hdd_data_raidz/restic + mp_path_guest: /shares_restic + - vmid: 115 + mp_nr: 12 + mp_path_host: /hdd_data_raidz/backup + mp_path_guest: /shares_backup + - vmid: 115 + mp_nr: 14 + mp_path_host: /hdd_data_raidz/buecher + mp_path_guest: /shares_buecher + - vmid: 115 + mp_nr: 15 + mp_path_host: /hdd_data_raidz/programme + mp_path_guest: /shares_programme + - vmid: 115 + mp_nr: 16 + mp_path_host: /hdd_data_raidz/vm + mp_path_guest: /shares_vm - # mgrote.pbs_pve_integration - pve_pbs_datastore: - - name: pbs - server: pbs.grote.lan - datastore: zfs_backup - username: user_pve5@pbs - password: "{{ lookup('keepass', 'pbs_pve_user', 'password') }}" - fingerprint: "7F:AC:54:75:1C:33:55:84:1E:1E:3A:15:5A:5E:AF:79:33:C9:D4:E1:C0:A0:1C:0D:9E:6A:EA:82:F9:27:57:79" +# mgrote.pbs_pve_integration +pve_pbs_datastore: + - name: pbs + server: pbs.grote.lan + datastore: zfs_backup + username: user_pve5@pbs + password: "{{ lookup('keepass', 'pbs_pve_user', 'password') }}" + fingerprint: "7F:AC:54:75:1C:33:55:84:1E:1E:3A:15:5A:5E:AF:79:33:C9:D4:E1:C0:A0:1C:0D:9E:6A:EA:82:F9:27:57:79" diff --git a/inventory_laptop b/inventory_laptop deleted file mode 100644 index f255a303..00000000 --- a/inventory_laptop +++ /dev/null @@ -1,5 +0,0 @@ -all: - children: - laptop: - hosts: - t410.grote.lan: diff --git a/playbooks/1_bootstrap.yml b/playbooks/1_bootstrap.yml index 17cf566a..c83f658d 100644 --- a/playbooks/1_bootstrap.yml +++ b/playbooks/1_bootstrap.yml @@ -1,34 +1,29 @@ --- - - hosts: all - gather_facts: false - max_fail_percentage: 20% - roles: - - { role: robertdebock.bootstrap, tags: "bootstrap", become: yes} - - { role: mgrote.users, tags: "user", become: yes} - - { role: mgrote.r8152_kernel_module } - - { role: mgrote.apt_manage_sources, tags: "apt_sources" } - - { role: mgrote.qemu_guest_agent } - - { role: mgrote.apt_update_packages, tags: "updates"} - post_tasks: - - name: Change user password - become: true - user: - name: mg - update_password: always - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" - - - vars: - ### reobertdebock.bootstrap - bootstrap_user: mg - bootstrap_wait_for_host: no - bootstrap_timeout: 1 - ### ansible - ansible_user: "mg" - ansible_password: hallowelt - ansible_become_password: hallowelt - ansible_ssh_common_args: "'-o StrictHostKeyChecking=no'" - +- hosts: all + gather_facts: false + roles: + - { role: robertdebock.bootstrap, tags: "bootstrap", become: true} + - { role: mgrote_users, tags: "user", become: true} + - { role: mgrote_apt_manage_sources, tags: "apt_sources" } + - { role: mgrote_qemu_guest_agent } + - { role: mgrote_apt_update_packages, tags: "updates"} + post_tasks: + - name: Change user password + become: true + ansible.builtin.user: + name: mg + update_password: always + password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" + vars: + ### reobertdebock.bootstrap + bootstrap_user: mg + bootstrap_wait_for_host: false + bootstrap_timeout: 1 + ### ansible + ansible_user: "mg" + ansible_password: hallowelt + ansible_become_password: hallowelt + ansible_ssh_common_args: "'-o StrictHostKeyChecking=no'" # Nach dem ersten durchlaufen ist keine Anmeldung mehr per Passwort & ssh möglich. Damit scheitert auch der Versuch das Playbook ein zweites mal durchlaufen zu lassen. diff --git a/playbooks/2_all.yml b/playbooks/2_all.yml index 08e5e646..020bb6db 100644 --- a/playbooks/2_all.yml +++ b/playbooks/2_all.yml @@ -1,18 +1,17 @@ --- - - import_playbook: base/apt_sources.yml - - import_playbook: base/packages.yml - - import_playbook: base/ntp_client.yml - - import_playbook: base/restic.yml - - import_playbook: base/users.yml - - import_playbook: base/motd.yml - - import_playbook: base/dotfiles.yml - - import_playbook: base/vim.yml - - import_playbook: base/postfix.yml - - import_playbook: base/ufw.yml - - import_playbook: base/ssh.yml - - import_playbook: base/f2b.yml - - import_playbook: base/remove_snapd.yml - - import_playbook: base/unattended_upgrades.yml - - import_playbook: base/update_packages.yml - - import_playbook: base/lvm.yml - - import_playbook: base/fwupd.yml +- ansible.builtin.import_playbook: base/apt_sources.yml +- ansible.builtin.import_playbook: base/packages.yml +- ansible.builtin.import_playbook: base/ntp_client.yml +- ansible.builtin.import_playbook: base/restic.yml +- ansible.builtin.import_playbook: base/users.yml +- ansible.builtin.import_playbook: base/dotfiles.yml +- ansible.builtin.import_playbook: base/vim.yml +- ansible.builtin.import_playbook: base/postfix.yml +- ansible.builtin.import_playbook: base/ufw.yml +- ansible.builtin.import_playbook: base/ssh.yml +- ansible.builtin.import_playbook: base/f2b.yml +- ansible.builtin.import_playbook: base/remove_snapd.yml +- ansible.builtin.import_playbook: base/unattended_upgrades.yml +- ansible.builtin.import_playbook: base/update_packages.yml +- ansible.builtin.import_playbook: base/lvm.yml +- ansible.builtin.import_playbook: base/fwupd.yml diff --git a/playbooks/3_service/acng.yml b/playbooks/3_service/acng.yml deleted file mode 100644 index 2dc9134a..00000000 --- a/playbooks/3_service/acng.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- -- hosts: acng - roles: - - { role: mgrote.acng, tags: "acng" } diff --git a/playbooks/3_service/dnsmasq.yml b/playbooks/3_service/dnsmasq.yml deleted file mode 100644 index 9c9e4d69..00000000 --- a/playbooks/3_service/dnsmasq.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - - hosts: dnsmasq - roles: - - { role: mgrote.dnsmasq_adblocker, tags: "dns", become: true } diff --git a/playbooks/3_service/docker.yml b/playbooks/3_service/docker.yml index cb55bce8..2dbb0a46 100644 --- a/playbooks/3_service/docker.yml +++ b/playbooks/3_service/docker.yml @@ -1,9 +1,9 @@ --- - hosts: docker roles: - - { role: mgrote.systemd-resolved, tags: "dns", become: true } + - { role: mgrote_systemd_resolved, tags: "dns", become: true } - { role: geerlingguy.pip, tags: "pip", become: true } - { role: geerlingguy.docker, tags: "docker", become: true } - { role: gantsign.ctop, tags: "ctop", become: true } - - { role: mgrote.set_permissions, tags: "perm", become: true } - - { role: mgrote.docker-compose-inline, tags: "compose", become: true } + - { role: mgrote_set_permissions, tags: "perm", become: true } + - { role: mgrote_docker_compose_inline, tags: "compose", become: true } diff --git a/playbooks/3_service/dokuwiki.yml b/playbooks/3_service/dokuwiki.yml index f2cde001..ce325b19 100644 --- a/playbooks/3_service/dokuwiki.yml +++ b/playbooks/3_service/dokuwiki.yml @@ -1,4 +1,4 @@ --- - hosts: dokuwiki roles: - - { role: mgrote.dokuwiki, tags: "dokuwiki" } + - { role: mgrote_dokuwiki, tags: "dokuwiki" } diff --git a/playbooks/3_service/fileserver.yml b/playbooks/3_service/fileserver.yml index fae4fe3a..a6b4d769 100644 --- a/playbooks/3_service/fileserver.yml +++ b/playbooks/3_service/fileserver.yml @@ -6,6 +6,6 @@ --- - hosts: fileserver roles: - - { role: mgrote.fileserver_smb, tags: "fileserver_smb" } - - { role: mgrote.youtubedl, tags: "youtubedl" } - - { role: mgrote.disable_oom_killer, tags: "oom" } + - { role: mgrote_fileserver_smb, tags: "fileserver_smb" } + - { role: mgrote_youtubedl, tags: "youtubedl" } + - { role: mgrote_disable_oom_killer, tags: "oom" } diff --git a/playbooks/3_service/gitea.yml b/playbooks/3_service/gitea.yml index e198ebaf..377e7239 100644 --- a/playbooks/3_service/gitea.yml +++ b/playbooks/3_service/gitea.yml @@ -1,5 +1,4 @@ --- - hosts: gitea roles: - - { role: mgrote.postfix, tags: "postfix" } - { role: l3d.gitea, tags: "gitea", become: true } diff --git a/playbooks/3_service/k3s.yml b/playbooks/3_service/k3s.yml index 80cd7795..33b76fbd 100644 --- a/playbooks/3_service/k3s.yml +++ b/playbooks/3_service/k3s.yml @@ -2,9 +2,9 @@ - hosts: k3s roles: - { role: PyratLabs.k3s, tags: "k3s" } - - { role: mgrote.k8s_autocompletion, tags: "autocomp" } + - { role: mgrote_k8s_autocompletion, tags: "autocomp" } - { role: pandemonium1986.ansible-role-k9s, tags: "k9s", become: true } - - { role: mgrote.fluxcd, tags: "flux", become: true } - - { role: mgrote.k8s_misc, tags: "misc", become: true } - - { role: mgrote.sealed-secrets, tags: "sealed-secrets", become: true } + - { role: mgrote_fluxcd, tags: "flux", become: true } + - { role: mgrote_k8s_misc, tags: "misc", become: true } + - { role: mgrote_sealed_secrets, tags: "sealed-secrets", become: true } - { role: geerlingguy.helm, tags: "helm", become: true } diff --git a/playbooks/3_service/laptop.yml b/playbooks/3_service/laptop.yml deleted file mode 100644 index c0fed905..00000000 --- a/playbooks/3_service/laptop.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -- hosts: laptop - roles: - - { role: mgrote.i3, tags: "i3", become: true } - - { role: mgrote.polybar, tags: "polybar", become: true } - - { role: mgrote.deactivate_caps, tags: "caps", become: true } - - { role: mgrote.alacritty, tags: "alacritty", become: true } - - { role: geerlingguy.pip, tags: "pip", become: true } - - { role: geerlingguy.docker, tags: "docker", become: true } - - { role: gantsign.ctop, tags: "ctop", become: true } - - { role: mgrote.xnview, tags: "xnview", become: true } diff --git a/playbooks/3_service/nfs.yml b/playbooks/3_service/nfs.yml deleted file mode 100644 index e4839948..00000000 --- a/playbooks/3_service/nfs.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- -- hosts: nfs - roles: - - { role: geerlingguy.nfs_server, tags: "nfs", become: true } diff --git a/playbooks/3_service/pbs.yml b/playbooks/3_service/pbs.yml index 42da6d1a..7abd58fe 100644 --- a/playbooks/3_service/pbs.yml +++ b/playbooks/3_service/pbs.yml @@ -1,15 +1,13 @@ --- - hosts: pbs roles: - - { role: mgrote.zfs_packages, tags: "zfs_packages" } - - { role: mgrote.zfs_arc_mem, tags: "zfs_arc_mem" } - - { role: mgrote.zfs_manage_datasets, tags: "datasets" } - - { role: mgrote.zfs_scrub, tags: "zfs_scrub" } - - { role: mgrote.zfs_zed, tags: "zfs_zed" } - - { role: mgrote.zfs_health, tags: "zfs_health" } - - { role: mgrote.zfs_sanoid, - tags: "sanoid" } - - { role: mgrote.smart, tags: "smart" } - - { role: mgrote.postfix, tags: "postfix" } - - { role: mgrote.pbs_users, tags: "pbs_users" } - - { role: mgrote.pbs_datastores, tags: "pbs_datastores" } + - { role: mgrote_zfs_packages, tags: "zfs_packages" } + - { role: mgrote_zfs_arc_mem, tags: "zfs_arc_mem" } + - { role: mgrote_zfs_manage_datasets, tags: "datasets" } + - { role: mgrote_zfs_scrub, tags: "zfs_scrub" } + - { role: mgrote_zfs_zed, tags: "zfs_zed" } + - { role: mgrote_zfs_health, tags: "zfs_health" } + - { role: mgrote_zfs_sanoid, tags: "sanoid" } + - { role: mgrote_smart, tags: "smart" } + - { role: mgrote_pbs_users, tags: "pbs_users" } + - { role: mgrote_pbs_datastores, tags: "pbs_datastores" } diff --git a/playbooks/3_service/pve.yml b/playbooks/3_service/pve.yml index 21c87206..96b0b085 100644 --- a/playbooks/3_service/pve.yml +++ b/playbooks/3_service/pve.yml @@ -1,21 +1,15 @@ --- - hosts: pve roles: - - { role: mgrote.zfs_packages, tags: "zfs_packages" } - - { role: mgrote.zfs_arc_mem, tags: "zfs_arc_mem" } - - { role: mgrote.zfs_manage_datasets, tags: "datasets" } - - { role: mgrote.zfs_scrub, tags: "zfs_scrub" } - - { role: mgrote.zfs_zed, tags: "zfs_zed" } - - { role: mgrote.zfs_health, tags: "zfs_health" } - - { role: mgrote.zfs_sanoid, - tags: "sanoid" } - - { role: mgrote.smart, tags: "smart" } - - { role: mgrote.postfix, tags: "postfix" } - - { role: mgrote.cv4pve-autosnap, - tags: "cv4pve" } - - { role: mgrote.r8152_kernel_module, - tags: "r8152" } - - { role: mgrote.proxmox_bind_mounts, - tags: "bindmounts" } - - { role: mgrote.proxmox_lxc_profiles, tags: "lxc-profile" } - - { role: mgrote.pbs_pve_integration, tags: "pbs" } + - { role: mgrote_zfs_packages, tags: "zfs_packages" } + - { role: mgrote_zfs_arc_mem, tags: "zfs_arc_mem" } + - { role: mgrote_zfs_manage_datasets, tags: "datasets" } + - { role: mgrote_zfs_scrub, tags: "zfs_scrub" } + - { role: mgrote_zfs_zed, tags: "zfs_zed" } + - { role: mgrote_zfs_health, tags: "zfs_health" } + - { role: mgrote_zfs_sanoid, tags: "sanoid" } + - { role: mgrote_smart, tags: "smart" } + - { role: mgrote_cv4pve_autosnap, tags: "cv4pve" } + - { role: mgrote_proxmox_bind_mounts, tags: "bindmounts" } + - { role: mgrote_proxmox_lxc_profiles, tags: "lxc-profile" } + - { role: mgrote_pbs_pve_integration, tags: "pbs" } diff --git a/playbooks/base/apt_sources.yml b/playbooks/base/apt_sources.yml index 1594c9d5..c63f6d5d 100644 --- a/playbooks/base/apt_sources.yml +++ b/playbooks/base/apt_sources.yml @@ -1,5 +1,5 @@ --- - - hosts: all - roles: - - role: mgrote.apt_manage_sources - tags: "apt_sources" +- hosts: all + roles: + - role: mgrote_apt_manage_sources + tags: "apt_sources" diff --git a/playbooks/base/dotfiles.yml b/playbooks/base/dotfiles.yml index 0560c703..60e6a7dd 100644 --- a/playbooks/base/dotfiles.yml +++ b/playbooks/base/dotfiles.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.dotfiles, become: true, tags: "dotfiles" } +- hosts: all + roles: + - { role: mgrote_dotfiles, become: true, tags: "dotfiles" } diff --git a/playbooks/base/f2b.yml b/playbooks/base/f2b.yml index 13a32dfb..910db28f 100644 --- a/playbooks/base/f2b.yml +++ b/playbooks/base/f2b.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.fail2ban, tags: "f2b" } +- hosts: all + roles: + - { role: mgrote_fail2ban, tags: "f2b" } diff --git a/playbooks/base/fwupd.yml b/playbooks/base/fwupd.yml index b43e4c5a..0dfe3b3a 100644 --- a/playbooks/base/fwupd.yml +++ b/playbooks/base/fwupd.yml @@ -1,7 +1,7 @@ --- - - hosts: all - roles: - - { role: mgrote.fwupd_settings, - become: true, - tags: fwupd, - when: "ansible_facts['distribution'] == 'Ubuntu'"} +- hosts: all + roles: + - role: mgrote_fwupd_settings + become: true + tags: fwupd + when: "ansible_facts['distribution'] == 'Ubuntu'" diff --git a/playbooks/base/lvm.yml b/playbooks/base/lvm.yml index 7bab0a9a..fd262037 100644 --- a/playbooks/base/lvm.yml +++ b/playbooks/base/lvm.yml @@ -1,8 +1,8 @@ --- - - hosts: all - roles: - - { role: mrlesmithjr.ansible-manage-lvm, - tags: "lvm", - become: true, - when: manage_lvm == true and manage_lvm is defined } - # $manage_lvm gehört zu dieser Rolle, wird aber extra abgefragt um das PLaybook zu "aktivieren" +- hosts: all + roles: + - { role: mrlesmithjr.ansible-manage-lvm, + tags: "lvm", + become: true, + when: manage_lvm == true and manage_lvm is defined } + # $manage_lvm gehört zu dieser Rolle, wird aber extra abgefragt um das PLaybook zu "aktivieren" diff --git a/playbooks/base/motd.yml b/playbooks/base/motd.yml deleted file mode 100644 index 174523e0..00000000 --- a/playbooks/base/motd.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - - hosts: all - roles: - - { role: mgrote.motd, tags: "motd" } diff --git a/playbooks/base/ntp_client.yml b/playbooks/base/ntp_client.yml index 33ac0e8c..d09c1e08 100644 --- a/playbooks/base/ntp_client.yml +++ b/playbooks/base/ntp_client.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.ntp_chrony_client, tags: "ntp"} +- hosts: all + roles: + - { role: mgrote_ntp_chrony_client, tags: "ntp"} diff --git a/playbooks/base/packages.yml b/playbooks/base/packages.yml index 7781910c..1b0d6581 100644 --- a/playbooks/base/packages.yml +++ b/playbooks/base/packages.yml @@ -1,6 +1,6 @@ --- - - hosts: all - serial: 3 - roles: - - { role: mgrote.apt_manage_packages, tags: "install"} - - { role: mgrote.exa, tags: "exa"} +- hosts: all + serial: 3 + roles: + - { role: mgrote_apt_manage_packages, tags: "install"} + - { role: mgrote_exa, tags: "exa"} diff --git a/playbooks/base/postfix.yml b/playbooks/base/postfix.yml index 34bf8094..5170c75b 100644 --- a/playbooks/base/postfix.yml +++ b/playbooks/base/postfix.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.postfix, tags: "postfix" } +- hosts: all + roles: + - { role: mgrote_postfix, tags: "postfix" } diff --git a/playbooks/base/remove_snapd.yml b/playbooks/base/remove_snapd.yml index b1dc2617..c7091171 100644 --- a/playbooks/base/remove_snapd.yml +++ b/playbooks/base/remove_snapd.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.remove_snapd, become: true, tags: "snapd" } +- hosts: all + roles: + - { role: mgrote_remove_snapd, become: true, tags: "snapd" } diff --git a/playbooks/base/restic.yml b/playbooks/base/restic.yml index f592f96c..2eca23f1 100644 --- a/playbooks/base/restic.yml +++ b/playbooks/base/restic.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.restic, tags: "restic" } +- hosts: all + roles: + - { role: mgrote_restic, tags: "restic" } diff --git a/playbooks/base/ssh.yml b/playbooks/base/ssh.yml index 42bb3ef7..7816715d 100644 --- a/playbooks/base/ssh.yml +++ b/playbooks/base/ssh.yml @@ -1,5 +1,5 @@ --- - - hosts: all - roles: - - { role: mgrote.ssh, - tags: "ssh"} +- hosts: all + roles: + - { role: mgrote_ssh, + tags: "ssh"} diff --git a/playbooks/base/ufw.yml b/playbooks/base/ufw.yml index e051ec18..6361cbe4 100644 --- a/playbooks/base/ufw.yml +++ b/playbooks/base/ufw.yml @@ -1,6 +1,6 @@ --- - - hosts: all:!pve:!pbs - roles: - - { role: oefenweb.ufw, # Regeln werden in den Group/Host-Vars gesetzt - tags: "ufw", - become: true} +- hosts: all:!pve:!pbs + roles: + - { role: oefenweb.ufw, # Regeln werden in den Group/Host-Vars gesetzt + tags: "ufw", + become: true} diff --git a/playbooks/base/unattended_upgrades.yml b/playbooks/base/unattended_upgrades.yml index bb4ddae9..d1b77f7c 100644 --- a/playbooks/base/unattended_upgrades.yml +++ b/playbooks/base/unattended_upgrades.yml @@ -1,7 +1,7 @@ --- - - hosts: all:!pve,!pbs - roles: - - { role: hifis-net.unattended_upgrades, - become: true, - tags: unattended, - when: "ansible_facts['distribution'] == 'Ubuntu'"} +- hosts: all,!pve,!pbs + roles: + - { role: hifis-net.unattended_upgrades, + become: true, + tags: unattended, + when: "ansible_facts['distribution'] == 'Ubuntu'"} diff --git a/playbooks/base/update_packages.yml b/playbooks/base/update_packages.yml index e06b001f..facc9e2e 100644 --- a/playbooks/base/update_packages.yml +++ b/playbooks/base/update_packages.yml @@ -1,5 +1,5 @@ --- - - hosts: all - serial: 3 - roles: - - { role: mgrote.apt_update_packages, tags: "updates"} +- hosts: all + serial: 3 + roles: + - { role: mgrote_apt_update_packages, tags: "updates"} diff --git a/playbooks/base/users.yml b/playbooks/base/users.yml index 3dd2eae1..617009d1 100644 --- a/playbooks/base/users.yml +++ b/playbooks/base/users.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.users, tags: "user", become: yes } +- hosts: all + roles: + - { role: mgrote_users, tags: "user", become: true } diff --git a/playbooks/base/vim.yml b/playbooks/base/vim.yml index e9f821e3..6083f349 100644 --- a/playbooks/base/vim.yml +++ b/playbooks/base/vim.yml @@ -1,4 +1,4 @@ --- - - hosts: all - roles: - - { role: mgrote.vim, tags: "vim", become: true } +- hosts: all + roles: + - { role: mgrote_vim, tags: "vim", become: true } diff --git a/playbooks/on-off/activate_ssh_password_login.yml b/playbooks/on-off/activate_ssh_password_login.yml deleted file mode 100644 index 253616bf..00000000 --- a/playbooks/on-off/activate_ssh_password_login.yml +++ /dev/null @@ -1,22 +0,0 @@ ---- -- hosts: proxmox - become: yes - - tasks: - - name: allow ssh login with password - become: yes - ansible.builtin.lineinfile: - path: /etc/ssh/sshd_config - regexp: 'PasswordAuthentication no' - line: '#PasswordAuthentication yes' - state: present - validate: "/usr/sbin/sshd -T -f %s" - notify: restart_sshd - - handlers: - - name: restart_sshd - become: yes - systemd: - name: sshd - enabled: yes - state: restarted diff --git a/playbooks/on-off/apt_autoremove.yml b/playbooks/on-off/apt_autoremove.yml deleted file mode 100644 index ca36b3f8..00000000 --- a/playbooks/on-off/apt_autoremove.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- hosts: all - become: yes - serial: 5 - - tasks: - - name: apt autoremove - become: yes - ansible.builtin.apt: - autoremove: yes diff --git a/playbooks/on-off/apt_update.yml b/playbooks/on-off/apt_update.yml deleted file mode 100644 index 5b574bff..00000000 --- a/playbooks/on-off/apt_update.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- hosts: all - become: yes - serial: 5 - - tasks: - - name: update apt cache - become: yes - ansible.builtin.apt: - update_cache: yes diff --git a/playbooks/on-off/delete_old_upgrades_config.yml b/playbooks/on-off/delete_old_upgrades_config.yml deleted file mode 100644 index 16e0f316..00000000 --- a/playbooks/on-off/delete_old_upgrades_config.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -- hosts: all - tasks: - - name: delete_old_upgrades_config - become: yes - ansible.builtin.file: - name: "{{ item }}" - state: absent - loop: - - /etc/apt/apt.conf.d/20auto-upgrades - - /etc/apt/apt.conf.d/50unattended-upgrades diff --git a/playbooks/on-off/delete_ssh.yml b/playbooks/on-off/delete_ssh.yml deleted file mode 100644 index 4843f0b6..00000000 --- a/playbooks/on-off/delete_ssh.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- -- hosts: all - tasks: - - name: delete /home/mg/.ssh/authorized_keys - become: yes - ansible.builtin.file: - name: /home/mg/.ssh/authorized_keys - state: absent - - name: delete /home/ansible-user/.ssh/authorized_keys - become: yes - ansible.builtin.file: - name: /home/ansible-user/.ssh/authorized_keys - state: absent - - name: prohibit ssh login with password - become: yes - ansible.builtin.lineinfile: - path: /etc/ssh/sshd_config - regexp: 'PasswordAuthentication no' - line: 'PasswordAuthentication yes' - state: present - - name: restart_sshd - become: yes - systemd: - name: sshd - enabled: yes - state: restarted diff --git a/playbooks/on-off/f2b.yml b/playbooks/on-off/f2b.yml deleted file mode 100644 index 5eed98cd..00000000 --- a/playbooks/on-off/f2b.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- -- hosts: testeinzeln - become: yes - roles: - - { role: mgrote.postfix, tags: "postfix" } - - { role: mgrote.fail2ban, tags: "f2b" } diff --git a/playbooks/on-off/remove_bash-helper-scripts.yml b/playbooks/on-off/remove_bash-helper-scripts.yml index 4600123f..dd942bc0 100644 --- a/playbooks/on-off/remove_bash-helper-scripts.yml +++ b/playbooks/on-off/remove_bash-helper-scripts.yml @@ -2,7 +2,7 @@ - hosts: all tasks: - name: bash-helper-scripts-mgrote deinstallieren - become: yes + become: true ansible.builtin.package: name: bash-helper-scripts-mgrote state: absent diff --git a/playbooks/on-off/remove_chrony.yml b/playbooks/on-off/remove_chrony.yml deleted file mode 100644 index 2be4d61f..00000000 --- a/playbooks/on-off/remove_chrony.yml +++ /dev/null @@ -1,29 +0,0 @@ ---- -- hosts: all - tasks: - # deinstalliere andere ntp-implementationen - - name: removed chrony/ntp packages - become: yes - ansible.builtin.package: - name: - - chrony - - ntp - state: absent - - - name: remove chrony config - become: yes - ansible.builtin.file: - dest: /etc/chrony/chrony.conf - state: absent - - - name: remove logrotate config - become: yes - ansible.builtin.file: - dest: /etc/logrotate.d/chrony - state: absent - - - name: remove chrony driftfile folder - become: yes - file: - state: absent - path: /var/lib/chrony diff --git a/playbooks/on-off/remove_cowsay.yml b/playbooks/on-off/remove_cowsay.yml deleted file mode 100644 index 25ea0fc1..00000000 --- a/playbooks/on-off/remove_cowsay.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- hosts: all - tasks: - - name: cowsay deinstallieren - become: yes - ansible.builtin.package: - name: cowsay - state: absent diff --git a/playbooks/on-off/remove_dotfiles_dir.yml b/playbooks/on-off/remove_dotfiles_dir.yml deleted file mode 100644 index 09219c12..00000000 --- a/playbooks/on-off/remove_dotfiles_dir.yml +++ /dev/null @@ -1,54 +0,0 @@ ---- -- hosts: all - become: yes - tasks: - - name: delete /home/mg/dotfiles-repo - become: yes - ansible.builtin.file: - path: /home/mg/dotfiles-repo - state: absent - - name: delete /home/mg/.bash_aliases - become: yes - ansible.builtin.file: - path: /home/mg/.bash_aliases - state: absent - - name: delete /home/mg/.vimrc - become: yes - ansible.builtin.file: - path: /home/mg/.vimrc - state: absent - - name: delete /home/mg/.tmux.conf - become: yes - ansible.builtin.file: - path: /home/mg/.tmux.conf - state: absent - - name: delete /home/mg/.gitconfig - become: yes - ansible.builtin.file: - path: /home/mg/.gitconfig - state: absent - - name: delete /root/dotfiles-repo - become: yes - ansible.builtin.file: - path: /root/dotfiles-repo - state: absent - - name: delete /root/.bash_aliases - become: yes - ansible.builtin.file: - path: /root/.bash_aliases - state: absent - - name: delete /root/.tmux.conf - become: yes - ansible.builtin.file: - path: /root/.tmux.conf - state: absent - - name: delete /root/.gitconfig - become: yes - ansible.builtin.file: - path: /root/.gitconfig - state: absent - - name: delete /root/.vimrc - become: yes - ansible.builtin.file: - path: /root/.vimrc - state: absent diff --git a/playbooks/on-off/remove_ipmitool.yml b/playbooks/on-off/remove_ipmitool.yml deleted file mode 100644 index ae260e01..00000000 --- a/playbooks/on-off/remove_ipmitool.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -- hosts: all - become: yes - - tasks: - - name: remove Packages - become: yes - ansible.builtin.package: - name: - - hddtemp - - ipmitool - - powertop - state: absent diff --git a/playbooks/on-off/remove_munin_node.yml b/playbooks/on-off/remove_munin_node.yml deleted file mode 100644 index bb43b550..00000000 --- a/playbooks/on-off/remove_munin_node.yml +++ /dev/null @@ -1,27 +0,0 @@ ---- -- hosts: all - become: yes - - tasks: - - name: remove Packages - become: yes - ansible.builtin.apt: - autoremove: yes - autoclean: yes - purge: yes - name: - - munin-node - state: absent - - - name: remove folder - become: yes - ansible.builtin.file: - path: /etc/munin - state: absent - - - name: ensure user is absent - become: true - ansible.builtin.user: - name: munin - state: absent - remove: true diff --git a/playbooks/on-off/remove_ntpd.yml b/playbooks/on-off/remove_ntpd.yml deleted file mode 100644 index 16b8312d..00000000 --- a/playbooks/on-off/remove_ntpd.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- -- hosts: all - tasks: - - name: ntp deinstallieren - become: yes - ansible.builtin.package: - name: ntp - state: absent - - name: config file - become: yes - file: - path: /etc/ntp.conf - state: absent - - name: config folder - become: yes - file: - path: /var/lib/ntp - state: absent diff --git a/playbooks/on-off/remove_old_restic_config.yml b/playbooks/on-off/remove_old_restic_config.yml deleted file mode 100644 index d108add8..00000000 --- a/playbooks/on-off/remove_old_restic_config.yml +++ /dev/null @@ -1,71 +0,0 @@ ---- -- hosts: all - become: yes - tasks: - - name: remove /etc/restic - become: yes - ansible.builtin.file: - path: /etc/restic - state: absent - - - name: ensure user exists - become: true - ansible.builtin.user: - name: restic - state: absent - - - name: add user to sudoers - become: true - ansible.builtin.blockinfile: - path: /etc/sudoers - state: absent - block: | - restic ALL=(ALL) NOPASSWD:ALL - validate: '/usr/sbin/visudo -cf %s' - backup: yes - marker_begin: restic-sudoers BEGIN - marker_end: restic-sudoers END - - - name: copy smb_password.txt - become: yes - ansible.builtin.file: - dest: "/etc/restic/smb_password.txt" - state: absent - - - name: copy restic_backup.sh - become: yes - ansible.builtin.file: - state: absent - dest: "/usr/local/bin/restic_backup.sh" - - - name: remove exclude.txt - become: yes - ansible.builtin.file: - path: "/etc/restic/exclude.txt" - state: absent - - - name: copy password.txt - become: yes - ansible.builtin.file: - state: absent - dest: "/etc/restic/password.txt" - - - name: remove restic cronjob - become: yes - ansible.builtin.cron: - name: restic - state: absent - job: "/usr/local/bin/restic_backup.sh" - minute: "{{ 59|random(seed=inventory_hostname) }}" - - - name: remove restic log - become: true - ansible.builtin.file: - path: /var/log/restic.log - state: absent - - - name: copy logrotate config - become: yes - ansible.builtin.file: - state: absent - dest: /etc/logrotate.d/restic diff --git a/playbooks/on-off/remove_old_restic_cronjob.yml b/playbooks/on-off/remove_old_restic_cronjob.yml deleted file mode 100644 index 0c687ac3..00000000 --- a/playbooks/on-off/remove_old_restic_cronjob.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- -- hosts: all - tasks: - - name: remove restic cronjob - become: yes - ansible.builtin.cron: - name: restic - state: absent - job: "/usr/local/bin/restic_backup.sh" - minute: "{{ 59|random(seed=inventory_hostname) }}" - hour: "{{ restic_cron_hours }}" - # siehe: https://stackoverflow.com/questions/33379378/idempotence-and-random-variables-in-ansible diff --git a/playbooks/on-off/remove_old_ssh_key.yml b/playbooks/on-off/remove_old_ssh_key.yml index 1efe73f8..0ec7ee94 100644 --- a/playbooks/on-off/remove_old_ssh_key.yml +++ b/playbooks/on-off/remove_old_ssh_key.yml @@ -1,10 +1,10 @@ --- - hosts: all - become: yes + become: true tasks: - name: Set authorized key taken from file - become: yes + become: true ansible.posix.authorized_key: user: ansible-user state: present diff --git a/playbooks/on-off/remove_sanoid.yml b/playbooks/on-off/remove_sanoid.yml deleted file mode 100644 index bf2a6d6f..00000000 --- a/playbooks/on-off/remove_sanoid.yml +++ /dev/null @@ -1,62 +0,0 @@ ---- -- hosts: all - become: yes - - tasks: - - - - name: Create Sanoid Directory - become: true - ansible.builtin.file: - path: "{{ item }}" - state: absent - owner: root - group: root - # recurse: true - with_items: - - /etc/sanoid - - - - - name: Install Sanoid Binary - become: true - ansible.builtin.file: - dest: /usr/local/bin/sanoid - state: absent - - - name: Install Sanoid Defaults Configuration - become: true - ansible.builtin.file: - dest: /etc/sanoid/sanoid.defaults.conf - state: absent - - - name: Generate Sanoid Configuration - become: true - ansible.builtin.file: - dest: /etc/sanoid/sanoid.conf - state: absent - - - name: Create Sanoid Log - become: true - ansible.builtin.file: - path: "{{ sanoid_log_file }}" - state: absent - - - name: Add Sanoid Log to be Rotated - become: true - ansible.builtin.file: - path: /etc/logrotate.d/sanoid - state: absent - - - name: Generate Sanoid Cron Scripts - become: true - ansible.builtin.file: - dest: /usr/local/bin/sanoid-cron.sh - state: absent - - - name: Configure Sanoid Cron Job - become: true - ansible.builtin.cron: - name: sanoid-cron - job: /usr/local/bin/sanoid-cron.sh - state: absent diff --git a/playbooks/on-off/remove_telegraf.yml b/playbooks/on-off/remove_telegraf.yml deleted file mode 100644 index 56aa25b8..00000000 --- a/playbooks/on-off/remove_telegraf.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -- hosts: all - tasks: - - name: telegraf deinstallieren - become: yes - ansible.builtin.package: - name: telegraf - state: absent - - name: telegraf-repository entfernen - become: yes - apt_repository: - repo: 'deb https://repos.influxdata.com/ubuntu {{ ansible_distribution_release }} stable' - state: absent - filename: telegraf_repo diff --git a/playbooks/on-off/repair_syslog.yml b/playbooks/on-off/repair_syslog.yml deleted file mode 100644 index db39eb16..00000000 --- a/playbooks/on-off/repair_syslog.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- -- hosts: all:!proxmox - become: yes - serial: 5 - - tasks: - - name: write logrotate config rsyslog - become: yes - template: - src: rsyslog_template - dest: /etc/logrotate.d/rsyslog - - name: remove line - ansible.builtin.lineinfile: - path: /etc/rsyslog.conf - state: absent - regexp: '. @@rsyslog.grote.lan:514' diff --git a/playbooks/on-off/root_bash.yml b/playbooks/on-off/root_bash.yml deleted file mode 100644 index d3fce9e9..00000000 --- a/playbooks/on-off/root_bash.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- hosts: all - tasks: - - name: ensure root has /bin/bash - become: true - ansible.builtin.user: - name: root - shell: /bin/bash diff --git a/playbooks/on-off/rsyslog_template b/playbooks/on-off/rsyslog_template deleted file mode 100644 index 54b753f8..00000000 --- a/playbooks/on-off/rsyslog_template +++ /dev/null @@ -1,37 +0,0 @@ -/var/log/syslog -{ - rotate 7 - daily - missingok - notifempty - delaycompress - compress - postrotate - /usr/lib/rsyslog/rsyslog-rotate - endscript -} - -/var/log/mail.info -/var/log/mail.warn -/var/log/mail.err -/var/log/mail.log -/var/log/daemon.log -/var/log/kern.log -/var/log/auth.log -/var/log/user.log -/var/log/lpr.log -/var/log/cron.log -/var/log/debug -/var/log/messages -{ - rotate 4 - weekly - missingok - notifempty - compress - delaycompress - sharedscripts - postrotate - /usr/lib/rsyslog/rsyslog-rotate - endscript -} diff --git a/playbooks/on-off/set_dns_resolver.yml b/playbooks/on-off/set_dns_resolver.yml deleted file mode 100644 index 78a22bdc..00000000 --- a/playbooks/on-off/set_dns_resolver.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- -- hosts: dns - become: yes - - tasks: - - name: Setze DNS-Resolver fuer pihole-* - ansible.builtin.lineinfile: - path: /etc/resolv.conf.head - line: nameserver 192.168.2.3 - create: yes - backrefs: false - mode: 0664 diff --git a/playbooks/on-off/set_id0.yml b/playbooks/on-off/set_id0.yml deleted file mode 100644 index 4636177d..00000000 --- a/playbooks/on-off/set_id0.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -- hosts: all - become: yes - tasks: - - name: set root gid to 0 - become: true - ansible.builtin.user: - name: root - group: root diff --git a/playbooks/on-off/set_password_mg.yml b/playbooks/on-off/set_password_mg.yml deleted file mode 100644 index bdfa5722..00000000 --- a/playbooks/on-off/set_password_mg.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -- hosts: all - become: yes - tasks: - - name: Change user password - user: - name: mg - update_password: always - password: "{{ lookup('keepass', 'mg_linux_password_hash', 'password') }}" #hier muss der hash rein - -# Hash erstellen -# python -c 'import crypt,getpass; print(getpass.getpass("Name: ")+":"+crypt.crypt(getpass.getpass(),crypt.mksalt(crypt.METHOD_SHA512)))' -# oder -# mkpasswd --method=SHA-512 diff --git a/playbooks/on-off/set_r8152_driver.yml b/playbooks/on-off/set_r8152_driver.yml deleted file mode 100644 index df91a5e8..00000000 --- a/playbooks/on-off/set_r8152_driver.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- hosts: all - become: yes - roles: - - { role: mgrote.r8152_kernel_module_on_off } diff --git a/roles/_mgrote.musterrolle/defaults/main.yml b/roles/_mgrote.musterrolle/defaults/main.yml deleted file mode 100644 index ac1e0e2d..00000000 --- a/roles/_mgrote.musterrolle/defaults/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - acng_exthreshold: "60" - acng_server_port: "9999" - acng_security_conf_path: "/etc/apt-cacher-ng/security.conf" - acng_server_auth_user: acngadmin - acng_server_auth_pass: klauspeter diff --git a/roles/_mgrote.musterrolle/handlers/main.yml b/roles/_mgrote.musterrolle/handlers/main.yml deleted file mode 100644 index 0abd29d1..00000000 --- a/roles/_mgrote.musterrolle/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: acng starten aktivieren - become: yes - systemd: - name: apt-cacher-ng - enabled: yes - state: restarted diff --git a/roles/_mgrote.musterrolle/tasks/main.yml b/roles/_mgrote.musterrolle/tasks/main.yml deleted file mode 100644 index 7e0225b6..00000000 --- a/roles/_mgrote.musterrolle/tasks/main.yml +++ /dev/null @@ -1,49 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - name: install apt-cacher-ng packages - become: yes - ansible.builtin.package: - name: apt-cacher-ng - state: present - - - name: templating acng.conf - become: yes - ansible.builtin.template: - src: "acng.conf" - dest: "/etc/apt-cacher-ng/acng.conf" - mode: 0664 - notify: acng_starten_aktivieren - - - name: Create restic log - become: true - ansible.builtin.file: - path: /var/log/restic.log - state: touch - owner: root - group: root - mode: 0640 - access_time: preserve - modification_time: preserve - - - name: copy logrotate config - become: yes - ansible.builtin.template: - src: logrotate_restic - dest: /etc/logrotate.d/restic - owner: root # muss root sein, sonst führt logrotate die datei nicht aus - group: root # muss root sein, sonst führt logrotate die datei nicht aus - mode: 0644 - - - name: add bind mounts to container - become: true - command: "pct set {{ item.vmid }} -mp{{ item.mp_nr }} {{ item.mp_path_host }},mp={{ item.mp_path_guest }}" - register: restart - notify: restart lxc - # füge bind-mount hinzu falls er fehlt, also rc ungleich 0 - # pro bind-mount - when: - - not ansible_check_mode - - not config.rc == 0 - # überspringe wenn in check-mode diff --git a/roles/_mgrote.musterrolle/tasks/user.yml b/roles/_mgrote.musterrolle/tasks/user.yml deleted file mode 100644 index cc4fa2d7..00000000 --- a/roles/_mgrote.musterrolle/tasks/user.yml +++ /dev/null @@ -1,34 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ sanoid_user_group }}" - state: present - when: - - sanoid_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ sanoid_user }}" - group: "{{ sanoid_user_group }}" - shell: /usr/sbin/nologin - create_home: no - when: - - sanoid_user_group is defined - - sanoid_user is defined - - - name: add user to sudoers - become: true - ansible.builtin.blockinfile: - path: /etc/sudoers - state: present - block: | - {{ sanoid_user }} ALL=(ALL) NOPASSWD:ALL - validate: '/usr/sbin/visudo -cf %s' - backup: yes - marker_begin: sanoid-sudoers BEGIN - marker_end: sanoid-sudoers END - when: - - sanoid_user_group is defined - - sanoid_user is defined diff --git a/roles/_mgrote.musterrolle_systemd/README.md b/roles/_mgrote.musterrolle_systemd/README.md deleted file mode 100644 index 9e750969..00000000 --- a/roles/_mgrote.musterrolle_systemd/README.md +++ /dev/null @@ -1,14 +0,0 @@ -## mgrote.rclone - -### Beschreibung -Installiert und konfiguriert rclone zur Datensicherung. - -### getestet auf -- [x] Ubuntu 20.04 (LXC) - -### Variablen + Defaults -- see [defaults](./defaults/main.yml) - -## Altes rclone Repository - -https://git.mgrote.net/mg/rclone diff --git a/roles/_mgrote.musterrolle_systemd/defaults/main.yml b/roles/_mgrote.musterrolle_systemd/defaults/main.yml deleted file mode 100644 index f5a7abdc..00000000 --- a/roles/_mgrote.musterrolle_systemd/defaults/main.yml +++ /dev/null @@ -1,17 +0,0 @@ ---- - -# rclone_config: "{{ lookup('keepass', 'rclone.conf', 'notes') }}" # rclone Config, use as Block - -# ### mgote.rclone -# rclone_jobs: # Array of Jobs -# - name: smb_musik_glacier # Jobname -# quelle: "/shares_music" # Source -# ziel: "scaleway-encrypt-glacier:/musik" # Destination -# timer: "*-*-* 23:15" # Timer -# loglevel: DEBUG # Optional: Loglevel -# state: true # true = present // false = remove -# bwlimit: 2M # Optional: Bandwidthlimit -# mode: "--size-only" # Optional: mode (https://rclone.org/s3/) -# transfers # Optional: Transfers -# checkers # Optional: Checkers -# retries # Optional: Retries diff --git a/roles/_mgrote.musterrolle_systemd/handlers/main.yml b/roles/_mgrote.musterrolle_systemd/handlers/main.yml deleted file mode 100644 index c73886d6..00000000 --- a/roles/_mgrote.musterrolle_systemd/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes diff --git a/roles/_mgrote.musterrolle_systemd/tasks/main.yml b/roles/_mgrote.musterrolle_systemd/tasks/main.yml deleted file mode 100644 index 24465c3d..00000000 --- a/roles/_mgrote.musterrolle_systemd/tasks/main.yml +++ /dev/null @@ -1,67 +0,0 @@ ---- - - name: template systemd services - become: yes - ansible.builtin.template: - src: "rclone.service.j2" - dest: "/etc/systemd/system/name.service" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - # wenn die unit über einen timer aktiviert wird muss sie nicht selber enabled werden, nur der timer muss enabled werden - - name: template rclone timer - become: yes - ansible.builtin.template: - src: "rclone.timer.j2" - dest: "/etc/systemd/system/rclone_{{ item.name }}.timer" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - with_items: - - "{{ rclone_jobs }}" - - # erstelle systemd-template - - name: template rclone_mail@.service.j2 - become: yes - ansible.builtin.template: - src: "rclone_mail@.service.j2" - dest: "/etc/systemd/system/rclone_mail@.service" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - # enable units, muss hier erfolgen statt als handler da sonst schonmit den units weiter gearbeitet wird obwohl sie noch nciht aktiv sind - - name: systemctl enable timer units - become: yes - ansible.builtin.systemd: - name: "rclone_{{ item.name }}.timer" - enabled: yes - masked: no - state: started - with_items: - - "{{ rclone_jobs }}" - notify: - - systemctl daemon-reload - - # ändere vorhandene unit; override.d statt direkte änderungen - - name: set timer - become: true - ansible.builtin.blockinfile: - create: yes - mode: 0644 - owner: root - group: root - path: /lib/systemd/system/sanoid.timer.d/override.conf - block: | - [Timer] - OnCalendar = {{ sanoid_timer }} - when: sanoid_timer is defined - notify: - - systemctl daemon-reload diff --git a/roles/_mgrote.musterrolle_systemd/templates/rclone.service.j2 b/roles/_mgrote.musterrolle_systemd/templates/rclone.service.j2 deleted file mode 100644 index 18abe54b..00000000 --- a/roles/_mgrote.musterrolle_systemd/templates/rclone.service.j2 +++ /dev/null @@ -1,10 +0,0 @@ -{{ file_header | default () }} - -[Unit] -Description=Sync data with rclone. -OnFailure=rclone_mail@{{ item.name }}.service - - -[Service] -Type=simple -ExecStart=/usr/bin/rclone --config "/etc/rclone/rclone.conf" sync --log-level {{ item.loglevel | default ("INFO") }} --transfers {{ item.transfers | default ("8") }} --checkers {{ item.checkers | default ("8") }} --retries {{ item.retries | default ("5") }} --bwlimit {{ item.bwlimit | default ("0") }} {% if item.mode is defined %}{{ item.mode }}{% endif %} --delete-after "{{ item.quelle }}" "{{item.ziel }}" diff --git a/roles/_mgrote.musterrolle_systemd/templates/rclone_mail@.service.j2 b/roles/_mgrote.musterrolle_systemd/templates/rclone_mail@.service.j2 deleted file mode 100644 index c68413cf..00000000 --- a/roles/_mgrote.musterrolle_systemd/templates/rclone_mail@.service.j2 +++ /dev/null @@ -1,8 +0,0 @@ -{{ file_header | default () }} - -[Unit] -Description=Send a Mail in case of an error in sanoid.service. - -[Service] -Type=oneshot -ExecStart=/bin/bash -c '/bin/systemctl status rclone_%i.service | mail -s "[ERROR] rclone - %i" {{ empfaenger_mail }}' diff --git a/roles/mgrote.acng/defaults/main.yml b/roles/mgrote.acng/defaults/main.yml deleted file mode 100644 index ac1e0e2d..00000000 --- a/roles/mgrote.acng/defaults/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - acng_exthreshold: "60" - acng_server_port: "9999" - acng_security_conf_path: "/etc/apt-cacher-ng/security.conf" - acng_server_auth_user: acngadmin - acng_server_auth_pass: klauspeter diff --git a/roles/mgrote.acng/handlers/main.yml b/roles/mgrote.acng/handlers/main.yml deleted file mode 100644 index e6b6b72b..00000000 --- a/roles/mgrote.acng/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: acng_starten_aktivieren - become: yes - systemd: - name: apt-cacher-ng - enabled: yes - state: restarted diff --git a/roles/mgrote.acng/tasks/main.yml b/roles/mgrote.acng/tasks/main.yml deleted file mode 100644 index 39ad7972..00000000 --- a/roles/mgrote.acng/tasks/main.yml +++ /dev/null @@ -1,42 +0,0 @@ ---- - - name: ensure directories exists - become: yes - ansible.builtin.file: - path: "{{ item }}" - state: directory - loop: - - /etc/apt-cacher-ng - - /var/cache/apt-cacher-ng - - - name: ensure directories have the right permissions - become: yes - ansible.builtin.file: - path: "{{ item }}" - state: directory - owner: apt-cacher-ng - group: apt-cacher-ng - loop: - - /var/cache/apt-cacher-ng - - - name: templating acng.conf - become: yes - ansible.builtin.template: - src: "acng.conf" - dest: "/etc/apt-cacher-ng/acng.conf" - mode: 0664 - notify: acng_starten_aktivieren - - - name: install apt-cacher-ng packages - become: yes - ansible.builtin.package: - name: apt-cacher-ng - state: present - - - name: templating security.conf - become: yes - ansible.builtin.template: - src: "security.conf" - dest: "{{ acng_security_conf_path }}" - mode: 0640 - notify: acng_starten_aktivieren - no_log: true diff --git a/roles/mgrote.alacritty/defaults/main.yml b/roles/mgrote.alacritty/defaults/main.yml deleted file mode 100644 index 3240c6e2..00000000 --- a/roles/mgrote.alacritty/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - alacritty_url: http://docker10.grote.lan:3344/alacritty-latest.tar.gz diff --git a/roles/mgrote.alacritty/tasks/main.yml b/roles/mgrote.alacritty/tasks/main.yml deleted file mode 100644 index 18b5f1dd..00000000 --- a/roles/mgrote.alacritty/tasks/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - - name: download binary - ansible.builtin.unarchive: - src: "{{ alacritty_url }}" - dest: /usr/local/bin - remote_src: yes - - - name: set permissions - ansible.builtin.file: - path: /usr/local/bin/alacritty - mode: '0755' diff --git a/roles/mgrote.apcupsd/defaults/main.yml b/roles/mgrote.apcupsd/defaults/main.yml deleted file mode 100644 index 6e1a912c..00000000 --- a/roles/mgrote.apcupsd/defaults/main.yml +++ /dev/null @@ -1,40 +0,0 @@ ---- - ## Values: http://www.apcupsd.org/manual/manual.html - - ## Master - # Wenn "true" ist dieser Host master. - apcupsd_nis_master: true - - # Interface auf dem der "Master" erreichbar ist. - apcupsd_nis_master_listen_ip: 0.0.0.0 - - # Post auf dem der "Master" erreichbar ist. - apcupsd_nis_master_listen_port: 3551 - - # Name der USV - apcupsd_ups_name: APC-BX950U-GR - - ## Slave - # Zeitspanne zwischen dem pollen - apcupsd_slave_polltime: 10 #in Sekunden - - - ## Master & Slave - # FQDN oder IP des "master" - apcupsd_nis_master_hostname: pve2.grote.lan - - # Zeitspanne in Sekunden, ab der der Systemdienst einen Stromausfall annimmt. Nuetzlich, um sehr kurze Ausfaelle ignorieren zu koennen. - apcupsd_master_onbatterydelay: 10 - apcupsd_slave_onbatterydelay: 10 - - # Durch die USV gemeldete Restkapazitaet in Prozent, ab der der Rechner heruntergefahren wird. - apcupsd_master_batterylevel_for_shutdown: 50 - apcupsd_slave_batterylevel_for_shutdown: 60 - - # apcupsd will shutdown the system during a power failure when the remaining runtime on batteries as internally calculated by the UPS falls below the specified minutes. Jeweils Master und Slave. - apcupsd_master_minutes_for_shutdown: 10 - apcupsd_slave_minutes_for_shutdown: 11 - - # Specifies when apcupsd should create the NOLOGON file to prevent users from logging on to the system. Jeweils Master und Slave. - apcupsd_master_nologon_when_active: always - apcupsd_slave_nologon_when_active: always diff --git a/roles/mgrote.apcupsd/handlers/main.yml b/roles/mgrote.apcupsd/handlers/main.yml deleted file mode 100644 index 361ea0e2..00000000 --- a/roles/mgrote.apcupsd/handlers/main.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- - - name: restart_apcupsd #wird aufgerufen wenn apcupsd.conf_kopieren nach aenderungen den status "changed hat" - become: yes - systemd: - name: apcupsd - state: restarted - enabled: yes - - - name: apc_access_mail - shell: /usr/sbin/apcaccess | mail -s "{{ ansible_hostname }}" {{ empfaenger_mail }} diff --git a/roles/mgrote.apcupsd/meta/main.yml b/roles/mgrote.apcupsd/meta/main.yml deleted file mode 100644 index 56314662..00000000 --- a/roles/mgrote.apcupsd/meta/main.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- - dependencies: - - role: mgrote.postfix - galaxy_info: - author: mgrote - description: installs apcupsd - min_ansible_version: 2.0 - license: GPLv3 - platforms: - - name: Proxmox - versions: - - all - galaxy_tags: - - system diff --git a/roles/mgrote.apcupsd/tasks/main.yml b/roles/mgrote.apcupsd/tasks/main.yml deleted file mode 100644 index a16f89c2..00000000 --- a/roles/mgrote.apcupsd/tasks/main.yml +++ /dev/null @@ -1,42 +0,0 @@ ---- - - name: install apcupsd packages - ansible.builtin.package: - name: - - apcupsd - - apcupsd-cgi - - apcupsd-doc - state: present - become: yes - notify: apc_access_mail - - - name: create master config - include_tasks: master.yml - when: - - apcupsd_nis_master - - apcupsd_nis_master is defined - - - name: create slave config - include_tasks: slave.yml - when: - - not apcupsd_nis_master - - apcupsd_nis_master is defined - - - name: copy apcupsd file - become: yes - ansible.builtin.template: - src: "apcupsd" - dest: "/etc/default/apcupsd" - - - name: set mail recipient - become: yes - ansible.builtin.lineinfile: - path: /etc/apcupsd/apccontrol #wo - regexp: export SYSADMIN=root #suche nach - line: export SYSADMIN={{ empfaenger_mail }} #ersetze durch... - backrefs: yes #verhindert das die zeile bei "nicht zutreffen" am ende der datei angefuegt wird: https://docs.ansible.com/ansible/latest/modules/lineinfile_module.html#parameters - - - name: copy test script - become: yes - ansible.builtin.template: - src: "apccontrol.save" - dest: "/etc/apcupsd/apccontrol.save" diff --git a/roles/mgrote.apcupsd/tasks/master.yml b/roles/mgrote.apcupsd/tasks/master.yml deleted file mode 100644 index 6f989fd3..00000000 --- a/roles/mgrote.apcupsd/tasks/master.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: templating master_apcupsd.conf - become: yes - ansible.builtin.template: - src: "master_apcupsd.conf" - dest: "/etc/apcupsd/apcupsd.conf" - notify: restart_apcupsd #benachrichtigt handlers/main.yml-restart-apcupsd_restart um den dient neuzustarten, nur wenn hier status "changed" ausgeworfen wird" diff --git a/roles/mgrote.apcupsd/tasks/slave.yml b/roles/mgrote.apcupsd/tasks/slave.yml deleted file mode 100644 index 171c68d0..00000000 --- a/roles/mgrote.apcupsd/tasks/slave.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: templating slave_apcupsd.conf - become: yes - ansible.builtin.template: - src: "slave_apcupsd.conf" - dest: "/etc/apcupsd/apcupsd.conf" - notify: restart_apcupsd #benachrichtigt handlers/main.yml-restart-apcupsd_restart um den dient neuzustarten, nur wenn hier status "changed" ausgeworfen wird" diff --git a/roles/mgrote.apt_manage_packages/defaults/main.yml b/roles/mgrote.apt_manage_packages/defaults/main.yml deleted file mode 100644 index 4872db06..00000000 --- a/roles/mgrote.apt_manage_packages/defaults/main.yml +++ /dev/null @@ -1,35 +0,0 @@ ---- - apt_packages_common: - - locales - - build-essential - - ntp - - htop - - git - - dnsutils - - nano - - mc - - cifs-utils - - netdiscover - - tree - - curl - - logrotate - - ncdu - - net-tools - - sysstat - - apt-transport-https - - neofetch - - ntpdate - - acl - - python3 - - vim - apt_packages_physical: - - hddtemp - - ipmitool - - powertop - - s-tui - apt_packages_vm: - - qemu-guest-agent - - open-vm-tools - apt_packages_extra: - apt_packages_absent: - apt_packages_internet: diff --git a/roles/mgrote.apt_manage_packages/tasks/main.yml b/roles/mgrote.apt_manage_packages/tasks/main.yml deleted file mode 100644 index 3f1782d4..00000000 --- a/roles/mgrote.apt_manage_packages/tasks/main.yml +++ /dev/null @@ -1,41 +0,0 @@ ---- - - name: install common-packages - become: yes - ansible.builtin.package: - name: "{{ apt_packages_common }}" - state: present - - - name: install extra-packages - become: yes - ansible.builtin.package: - name: "{{ apt_packages_extra }}" - state: present - when: apt_packages_extra is defined - - - name: install vm-packages - become: yes - ansible.builtin.package: - name: "{{ apt_packages_vm }}" - state: present - when: ansible_virtualization_role == 'guest' - - - name: install physical-packages - become: yes - ansible.builtin.package: - name: "{{ apt_packages_physical }}" - state: present - when: ansible_virtualization_role != 'guest' - - - name: install packages from the internet - become: yes - ansible.builtin.apt: - deb: "{{ item }}" - state: present - when: apt_packages_internet is defined - loop: "{{ apt_packages_internet }}" - - - name: remove packages - become: yes - ansible.builtin.package: - name: "{{ apt_packages_absent }}" - state: absent diff --git a/roles/mgrote.apt_manage_sources/handlers/main.yml b/roles/mgrote.apt_manage_sources/handlers/main.yml deleted file mode 100644 index 4b88c5f0..00000000 --- a/roles/mgrote.apt_manage_sources/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: update package lists # noqa no-handler - become: yes - ansible.builtin.apt: - update_cache: yes diff --git a/roles/mgrote.apt_update_packages/tasks/main.yml b/roles/mgrote.apt_update_packages/tasks/main.yml deleted file mode 100644 index fe20b127..00000000 --- a/roles/mgrote.apt_update_packages/tasks/main.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- - - name: update apt cache - become: yes - ansible.builtin.apt: - update_cache: yes - - - name: update installed packages - become: yes - ansible.builtin.package: - upgrade: dist diff --git a/roles/mgrote.cv4pve-autosnap/defaults/main.yml b/roles/mgrote.cv4pve-autosnap/defaults/main.yml deleted file mode 100644 index 4935e342..00000000 --- a/roles/mgrote.cv4pve-autosnap/defaults/main.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- - # when should cv4pve be run - cv4pve_cron_minute: "39" - cv4pve_cron_hour: "5" - # proxmox api-token and user - cv4pve_api_token: "XXXXXXXXXXXXXXXXXXXXXX" - cv4pve_api_user: "root@pam!test2" - # which vm to snapshot - cv4pve_vmid: all - # how many snapshots to keep - cv4pve_keep_snapshots: 3 - # under which user the script is run - cv4pve_user_group: cv4pve - cv4pve_user: cv4pve diff --git a/roles/mgrote.cv4pve-autosnap/handlers/main.yml b/roles/mgrote.cv4pve-autosnap/handlers/main.yml deleted file mode 100644 index 510b17fe..00000000 --- a/roles/mgrote.cv4pve-autosnap/handlers/main.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes - - - name: systemctl enable units - become: yes - ansible.builtin.systemd: - name: "{{ item }}" - enabled: yes - masked: no - with_items: - - cv4pve.service - - cv4pve_mail.service - - cv4pve.timer - - - name: systemctl start units - become: yes - ansible.builtin.systemd: - name: "{{ item }}" - state: restarted - enabled: yes - with_items: - - cv4pve.timer - notify: systemctl daemon-reload diff --git a/roles/mgrote.cv4pve-autosnap/tasks/main.yml b/roles/mgrote.cv4pve-autosnap/tasks/main.yml deleted file mode 100644 index 84aab1d2..00000000 --- a/roles/mgrote.cv4pve-autosnap/tasks/main.yml +++ /dev/null @@ -1,73 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - - name: create directories - become: yes - ansible.builtin.file: - path: "{{ item }}" - state: directory - owner: "{{ cv4pve_user }}" - group: "{{ cv4pve_user_group }}" - loop: - - '/tmp/cv4pve' - - '/usr/local/bin/cv4pve' - - - name: download archives - become: yes - ansible.builtin.get_url: - url: "{{ cv4pve_dl_link }}" - dest: /tmp/cv4pve/cv4pve-autosnap-linux-x64.zip - mode: '0775' - - - name: extract archives - become: yes - ansible.builtin.unarchive: - src: /tmp/cv4pve/cv4pve-autosnap-linux-x64.zip - dest: /usr/local/bin/cv4pve - remote_src: yes - mode: a+x - owner: "{{ cv4pve_user }}" - group: "{{ cv4pve_user_group }}" - - - name: template cv4pve.service - become: yes - ansible.builtin.template: - src: cv4pve.service.j2 - dest: /etc/systemd/system/cv4pve.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: template cv4pve_mail.service - become: yes - ansible.builtin.template: - src: cv4pve_mail.service.j2 - dest: /etc/systemd/system/cv4pve_mail.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - - name: template cv4pve.timer - become: yes - ansible.builtin.template: - src: cv4pve.timer.j2 - dest: /etc/systemd/system/cv4pve.timer - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: systemctl start cv4pve.timer - become: yes - ansible.builtin.systemd: - name: cv4pve.timer - state: started - enabled: yes diff --git a/roles/mgrote.cv4pve-autosnap/tasks/user.yml b/roles/mgrote.cv4pve-autosnap/tasks/user.yml deleted file mode 100644 index b346fb0b..00000000 --- a/roles/mgrote.cv4pve-autosnap/tasks/user.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ cv4pve_user_group }}" - state: present - when: - - cv4pve_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ cv4pve_user }}" - group: "{{ cv4pve_user_group }}" - shell: /usr/sbin/nologin - create_home: no - when: - - cv4pve_user_group is defined - - cv4pve_user is defined diff --git a/roles/mgrote.deactivate_caps/handlers/main.yml b/roles/mgrote.deactivate_caps/handlers/main.yml deleted file mode 100644 index 45c84358..00000000 --- a/roles/mgrote.deactivate_caps/handlers/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - - name: deactivate caps - become: true - ansible.builtin.shell: setxkbmap -option caps:none diff --git a/roles/mgrote.deactivate_caps/tasks/main.yml b/roles/mgrote.deactivate_caps/tasks/main.yml deleted file mode 100644 index 0debb058..00000000 --- a/roles/mgrote.deactivate_caps/tasks/main.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - x11-xkb-utils - state: present - notify: deactivate caps diff --git a/roles/mgrote.disable_oom_killer/tasks/main.yml b/roles/mgrote.disable_oom_killer/tasks/main.yml deleted file mode 100644 index afe665a6..00000000 --- a/roles/mgrote.disable_oom_killer/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- - - name: disable oom-killer in sysctl.conf (works after a reboot) - become: true - blockinfile: - path: /etc/sysctl.conf - block: | - vm.oom-kill = 0 - register: sysctl - - - name: disable oom-killer through /proc - become: true - ansible.builtin.command: echo 2 > /proc/sys/vm/overcommit_memory - when: sysctl.changed diff --git a/roles/mgrote.dnsmasq_adblocker/defaults/main.yml b/roles/mgrote.dnsmasq_adblocker/defaults/main.yml deleted file mode 100644 index afa48cd0..00000000 --- a/roles/mgrote.dnsmasq_adblocker/defaults/main.yml +++ /dev/null @@ -1,41 +0,0 @@ ---- - # Welche DNS-Server soll dnsmasq anfragen? - dnsmasq_resolver: - - 9.9.9.9 - - 1.1.1.1 - # Soll dnsmasq alle Anfragen loggen? - dnsmasq_log_queries: false - # Wohin soll das Log geschrieben werden? - dnsmasq_logfile: /var/log/dnsmasq.log - # Welche BLocklisten sollen verwendet werden? - dnsmasq_blocklists: - - name: sysctl.org - state: present - url: http://sysctl.org/cameleon/hosts - - name: StevenBlack.1 - state: present - url: https://raw.githubusercontent.com/StevenBlack/hosts/master/data/KADhosts/hosts - - name: StevenBlack.2 - state: present - url: https://raw.githubusercontent.com/StevenBlack/hosts/master/data/add.Spam/hosts - - name: adaway.org - state: present - url: https://adaway.org/hosts.txt - - name: StevenBlack.3 - state: present - url: https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts - - name: developerdan.1 - state: present - url: https://www.github.developerdan.com/hosts/lists/ads-and-tracking-extended.txt - - name: developerdan.2 - state: present - url: https://www.github.developerdan.com/hosts/lists/amp-hosts-extended.txt - # Wie groß soll der Cache sein? - dnsmasq_cache_size: 10000 - # Auf welchem Port soll dnsmasq laufen? - dnsmasq_port: 53 - # User und Gruppe für dnsmasq - dnsmasq_user_group: dnsmasq - dnsmasq_user: dnsmasq - # Which domain should never be forwarded tor the "dnsmasq_resolvers" - dnsmasq_never_forward_domain: local.lan diff --git a/roles/mgrote.dnsmasq_adblocker/handlers/main.yml b/roles/mgrote.dnsmasq_adblocker/handlers/main.yml deleted file mode 100644 index eb7a0ac2..00000000 --- a/roles/mgrote.dnsmasq_adblocker/handlers/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - - name: restart dnsmasq - become: yes - ansible.builtin.systemd: - name: dnsmasq - state: restarted diff --git a/roles/mgrote.dnsmasq_adblocker/tasks/blocklist.yml b/roles/mgrote.dnsmasq_adblocker/tasks/blocklist.yml deleted file mode 100644 index 418e9c6e..00000000 --- a/roles/mgrote.dnsmasq_adblocker/tasks/blocklist.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: download blocklist(s) - ansible.builtin.get_url: - url: "{{ item.url }}" - dest: "/etc/dnsmasq.d/blocklists/{{ item.name }}" - owner: "{{ dnsmasq_user }}" - group: "{{ dnsmasq_user_group }}" - loop: "{{ dnsmasq_blocklists }}" - when: item.state == "present" - notify: restart dnsmasq - register: download - - - name: remove blocklist(s) - ansible.builtin.file: - path: "/etc/dnsmasq.d/blocklists/{{ item.name }}" - state: absent - loop: "{{ dnsmasq_blocklists }}" - when: item.state == "absent" - notify: restart dnsmasq diff --git a/roles/mgrote.dnsmasq_adblocker/tasks/config.yml b/roles/mgrote.dnsmasq_adblocker/tasks/config.yml deleted file mode 100644 index 7a77ee60..00000000 --- a/roles/mgrote.dnsmasq_adblocker/tasks/config.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- - - name: template /etc/dnsmasq.conf - become: yes - ansible.builtin.template: - src: dnsmasq.conf.j2 - dest: /etc/dnsmasq.conf - owner: "{{ dnsmasq_user }}" - group: "{{ dnsmasq_user_group }}" - notify: restart dnsmasq diff --git a/roles/mgrote.dnsmasq_adblocker/tasks/install.yml b/roles/mgrote.dnsmasq_adblocker/tasks/install.yml deleted file mode 100644 index daa91fa4..00000000 --- a/roles/mgrote.dnsmasq_adblocker/tasks/install.yml +++ /dev/null @@ -1,62 +0,0 @@ ---- - - name: ensure packages are installed - become: yes - ansible.builtin.package: - name: - - dnsmasq - - wget - state: present - register: install - - - name: stop dnsmasq (to prevent accidental DHCP-Server after installation) - become: yes - ansible.builtin.service: - name: dnsmasq - state: stopped - when: install.changed - - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ dnsmasq_user_group }}" - state: present - when: - - dnsmasq_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ dnsmasq_user }}" - group: "{{ dnsmasq_user_group }}" - shell: /usr/sbin/nologin - create_home: no - when: - - dnsmasq_user_group is defined - - dnsmasq_user is defined - - - name: ensure needed directories exists - become: yes - ansible.builtin.file: - path: "{{ item }}" - state: directory - owner: "{{ dnsmasq_user }}" - group: "{{ dnsmasq_user_group }}" - loop: - - /etc/dnsmasq.d - - /etc/dnsmasq.d/blocklists - - - name: clear default directories - become: yes - ansible.builtin.file: - path: "{{ item }}" - state: absent - loop: - - /etc/dnsmasq.d/README - - - name: template logrotate config - become: yes - ansible.builtin.template: - src: logrotate.j2 - dest: /etc/logrotate.d/dnsmasq - owner: root - group: root diff --git a/roles/mgrote.dnsmasq_adblocker/tasks/main.yml b/roles/mgrote.dnsmasq_adblocker/tasks/main.yml deleted file mode 100644 index 09283b9a..00000000 --- a/roles/mgrote.dnsmasq_adblocker/tasks/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- - - name: include install tasks - include_tasks: install.yml - - - name: include configuration tasks - include_tasks: config.yml - - - name: include systemd tasks - include_tasks: services.yml - - - name: include blocklist tasks - include_tasks: blocklist.yml diff --git a/roles/mgrote.dnsmasq_adblocker/tasks/services.yml b/roles/mgrote.dnsmasq_adblocker/tasks/services.yml deleted file mode 100644 index d75777bf..00000000 --- a/roles/mgrote.dnsmasq_adblocker/tasks/services.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - - name: stop systemd-resolved service - ansible.builtin.systemd: - name: systemd-resolved - state: stopped - - - name: mask systemd-resolved service - ansible.builtin.systemd: - name: systemd-resolved - masked: yes - state: stopped - - - name: template /etc/resolv.conf - ansible.builtin.template: - src: resolv.conf.j2 - dest: /etc/resolv.conf - backup: yes - notify: restart dnsmasq diff --git a/roles/mgrote.docker-compose-deploy/tasks/dockercompose-down.yml b/roles/mgrote.docker-compose-deploy/tasks/dockercompose-down.yml deleted file mode 100644 index cb7eb86f..00000000 --- a/roles/mgrote.docker-compose-deploy/tasks/dockercompose-down.yml +++ /dev/null @@ -1,24 +0,0 @@ ---- - - name: set dir - "{{ item.name }}" - set_fact: - project_dir: "{{ docker_compose_base_dir }}/{{ item.dir_name | default (item.name) }}" - when: - - docker_compose_base_dir is defined - - docker_compose_projects is defined - - - name: check if dir exists - stat: - path: "{{ project_dir }}" - register: dir - - - name: stop container - "{{ item.name }}" - ansible.builtin.shell: docker-compose down - args: - chdir: "{{ project_dir }}" - when: dir.stat.exists == true - - - name: remove repository - "{{ item.name }}" - ansible.builtin.file: - state: absent - dest: "{{ project_dir }}" - when: dir.stat.exists == true diff --git a/roles/mgrote.docker-compose-deploy/tasks/dockercompose-up.yml b/roles/mgrote.docker-compose-deploy/tasks/dockercompose-up.yml deleted file mode 100644 index 68989430..00000000 --- a/roles/mgrote.docker-compose-deploy/tasks/dockercompose-up.yml +++ /dev/null @@ -1,64 +0,0 @@ ---- - - name: set username and passwort - "{{ item.name }}" - set_fact: - login: "{{ item.repository_user }}:{{ item.repository_user_password }}@" - when: - - item.repository_user is defined - - item.repository_user_password is defined - - - name: set dir - "{{ item.name }}" - set_fact: - project_dir: "{{ docker_compose_base_dir }}/{{ item.dir_name | default (item.name) }}" - when: - - docker_compose_base_dir is defined - - docker_compose_projects is defined - - - name: check if repo exists - "{{ item.name }}" (wenn der Task >30s dauert sind die Login-Daten falsch) - stat: - path: "{{ project_dir }}" - register: repo_exists - - - name: set safe directory - become: true - ansible.builtin.shell: - cmd: git config --global --add safe.directory "{{ project_dir }}" - changed_when: false - - - name: stash changes - "{{ item.name }}" - ansible.builtin.shell: git stash - args: - chdir: "{{ project_dir }}" - changed_when: false - when: repo_exists.stat.exists == true - - - name: clone repository - "{{ item.name }}" - ansible.builtin.git: - repo: "https://{{ login | default () }}{{ item.repository_url }}" - dest: "{{ project_dir }}" - version: "{{ item.git_branch | default ('master') }}" - register: repo - - - name: set owner recursive for repo - file: - path: "{{ project_dir }}" - owner: "{{ item.os_username }}" - group: "{{ item.os_username }}" - recurse: yes - when: repo is changed - - - name: create networks - "{{ item.name }}" - ansible.builtin.shell: "docker network create {{ item.network_name }}" # erstelle network - when: "item.network_name is defined" # wenn network_name definiert ist - register: network_result # speichere ergebnis in var - changed_when: "network_result.rc == 0" # markiere tasks als changed when exit-code == 0 - ignore_errors: yes # ignoriere fehler - - - name: (re)start container - "{{ item.name }}" - ansible.builtin.shell: docker-compose down && docker-compose up -d - args: - chdir: "{{ project_dir }}" - when: repo.changed - - - name: unset username and passwort - "{{ item.name }}" - set_fact: - login: "" diff --git a/roles/mgrote.docker-compose-deploy/tasks/main.yml b/roles/mgrote.docker-compose-deploy/tasks/main.yml deleted file mode 100644 index c02d0ab1..00000000 --- a/roles/mgrote.docker-compose-deploy/tasks/main.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- - - name: loop docker tasks - up - include_tasks: dockercompose-up.yml - loop: "{{ docker_compose_projects }}" - when: - - item.state == "present" - - docker_compose_projects is defined - no_log: true - - - name: loop docker tasks - down - include_tasks: dockercompose-down.yml - loop: "{{ docker_compose_projects }}" - when: - - item.state == "absent" - - docker_compose_projects is defined - no_log: true diff --git a/roles/mgrote.docker-compose-inline/defaults/main.yml b/roles/mgrote.docker-compose-inline/defaults/main.yml deleted file mode 100644 index 8d9cb9e5..00000000 --- a/roles/mgrote.docker-compose-inline/defaults/main.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - # owner and group of all files and directories - compose_owner: "docker-user" - compose_group: "docker-user" - # default permissions for all files and directories - compose_file_permissions: "644" - compose_dir_permissions: "755" - # where to store the compose-files on the destination system - compose_dest_basedir: "/docker" # without trailing "/" - # where are the docker-compose-files located on the ansible controller - compose_src_basedir: "{{ inventory_dir }}/docker-compose" # without trailing "/" - # dict of compose-files to deploy - #compose_files: - # - name: hastebin # used for directory name; starting & stopping - # state: present - # #network: test_nw # external network (optional) - # - name: ara - # state: present diff --git a/roles/mgrote.docker-compose-inline/tasks/main.yml b/roles/mgrote.docker-compose-inline/tasks/main.yml deleted file mode 100644 index 9dfda2aa..00000000 --- a/roles/mgrote.docker-compose-inline/tasks/main.yml +++ /dev/null @@ -1,97 +0,0 @@ ---- - - name: ensure basedir exists - become: true - ansible.builtin.file: - path: "{{ compose_dest_basedir }}" - state: directory - mode: "{{ compose_dir_permissions }}" - owner: "{{ compose_owner }}" - group: "{{ compose_group }}" - -# https://codeutility.org/ansible-can-the-templates-module-handle-multiple-templates-directories-stack-overflow/ - - name: copy all directories recursively - ansible.builtin.file: - dest: "{{compose_dest_basedir}}/{{ item|replace(compose_src_basedir+'/', '') }}" - state: directory - mode: "{{ compose_dir_permissions }}" - owner: "{{ compose_owner }}" - group: "{{ compose_group }}" - with_items: "{{ lookup('pipe', 'find '+ compose_src_basedir +'/ -type d').split('\n') }}" - - - name: copy all files recursively (can take a long time) - ansible.builtin.copy: - mode: "{{ compose_file_permissions }}" - owner: "{{ compose_owner }}" - group: "{{ compose_group }}" - src: "{{ item }}" - dest: "{{compose_dest_basedir}}/{{ item|replace(compose_src_basedir+'/', '') }}" - with_items: "{{ lookup('pipe', 'find '+ compose_src_basedir +'/ -type f -not -name *.j2 ').split('\n') }}" - no_log: true - - - name: copy templates files recursively - ansible.builtin.template: - mode: "{{ compose_file_permissions }}" - owner: "{{ compose_owner }}" - group: "{{ compose_group }}" - src: "{{ item }}" - dest: "{{compose_dest_basedir}}/{{ item|replace(compose_src_basedir+'/', '')|replace('.j2', '') }}" - with_items: "{{ lookup('pipe', 'find '+ compose_src_basedir +'/ -type f -name *.j2').split('\n') }}" - register: copy_template - no_log: true - -# - name: print $copy_template -# ansible.builtin.debug: -# var: copy_template - - - name: create networks - become: true - ansible.builtin.shell: "docker network create {{ item.network }}" # erstelle network - register: network_result # speichere ergebnis in var - changed_when: "network_result.rc == 0" # markiere tasks als changed when exit-code == 0 - ignore_errors: yes # ignoriere fehler - loop: "{{ compose_files }}" - when: - - item.state == "present" - - item.network is defined - - - name: (re)start container - become: true - ansible.builtin.shell: docker-compose up -d - args: - chdir: "{{ compose_dest_basedir }}/{{ item.name }}" - register: start_result # speichere ergebnis in var - changed_when: "start_result.rc == 0" # markiere tasks als changed when exit-code == 0 - loop: "{{ compose_files }}" - when: - - item.state == "present" - - copy_template is changed - - - name: stop old container - become: true - ansible.builtin.shell: docker-compose down - args: - chdir: "{{ compose_dest_basedir }}/{{ item.name }}" - loop: "{{ compose_files }}" - when: - - item.state == "absent" - ignore_errors: yes # ignoriere fehler - - - name: remove old networks - become: true - ansible.builtin.shell: "docker network remove {{ item.network }}" # erstelle network - register: network_result # speichere ergebnis in var - changed_when: "network_result.rc == 0" # markiere tasks als changed when exit-code == 0 - ignore_errors: yes # ignoriere fehler - loop: "{{ compose_files }}" - when: - - item.state == "absent" - - item.network is defined - - - name: remove old docker-compose files & directories - become: true - ansible.builtin.file: - path: "{{ compose_dest_basedir }}/{{ item.name }}/" - state: absent - loop: "{{ compose_files }}" - when: - - item.state == "absent" diff --git a/roles/mgrote.dokuwiki/defaults/main.yml b/roles/mgrote.dokuwiki/defaults/main.yml deleted file mode 100644 index cf83addb..00000000 --- a/roles/mgrote.dokuwiki/defaults/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - dokuwiki_install_path: /var/www/dokuwiki # wohin soll dokuwiki installiert werden - dokuwiki_download_url: https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz # wo soll dokuwiki heruntergeladen werden - dokuwiki_version_name: 2020-07-29 "Hogfather" # aus /var/www/dokuwiki/VERSION # welche Version, damit wird abgeglichen ob das Archiv heruntergeladen werden muss - dokuwiki_user: www-data # dokuwiki nutzer - dokuwiki_group: www-data # dokuwiki gruppe diff --git a/roles/mgrote.dokuwiki/handlers/main.yml b/roles/mgrote.dokuwiki/handlers/main.yml deleted file mode 100644 index b04ed67b..00000000 --- a/roles/mgrote.dokuwiki/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart_apache2 - become: yes - systemd: - name: apache2 - state: restarted - enabled: yes diff --git a/roles/mgrote.dokuwiki/meta/main.yml b/roles/mgrote.dokuwiki/meta/main.yml deleted file mode 100644 index 698c58af..00000000 --- a/roles/mgrote.dokuwiki/meta/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - dependencies: - - role: mgrote.postfix diff --git a/roles/mgrote.dokuwiki/tasks/apache2.yml b/roles/mgrote.dokuwiki/tasks/apache2.yml deleted file mode 100644 index f3a07940..00000000 --- a/roles/mgrote.dokuwiki/tasks/apache2.yml +++ /dev/null @@ -1,21 +0,0 @@ ---- - # aktiviert das module rewrite = a2enmod rewrite - - name: activate a2enmod rewrite - become: yes - ansible.builtin.apache2_module: - state: present - name: rewrite - - - name: copy default apache2.conf - become: yes - ansible.builtin.template: - src: "apache2.conf" - dest: "/etc/apache2/apache2.conf" - notify: restart_apache2 - - - name: copy 000-default.conf - become: yes - ansible.builtin.template: - src: "000-default.conf" - dest: "/etc/apache2/sites-enabled/000-default.conf" - notify: restart_apache2 diff --git a/roles/mgrote.dokuwiki/tasks/dokuwiki.yml b/roles/mgrote.dokuwiki/tasks/dokuwiki.yml deleted file mode 100644 index e34b4b09..00000000 --- a/roles/mgrote.dokuwiki/tasks/dokuwiki.yml +++ /dev/null @@ -1,72 +0,0 @@ ---- - - name: create dokuwiki install path - become: yes - ansible.builtin.file: - path: "{{ dokuwiki_install_path }}" - state: directory - owner: "{{ dokuwiki_user }}" - group: "{{ dokuwiki_group }}" - - - name: check if dokuwiki is installed - become: yes - stat: - path: /var/www/dokuwiki/VERSION - register: dokuwiki_install_status - - - name: check if desired version is installed - become: yes - ignore_errors: yes - lineinfile: - path: /var/www/dokuwiki/VERSION - line: "{{ dokuwiki_version_name }}" - state: present - check_mode: yes - register: dokuwiki_desired_version - when: - - dokuwiki_install_status.stat.exists == true - # falls Dokuwiki schon installiert ist existiert var/www/dokuwiki/VERSION mit - # dem Inhalt der Version: z.B. 2020-07-29 "Hogfather" - # when die Version die selbe wie in der Variable ist - # ist der status ok, ist die Version unterschiedlich ist der status changed, die Datei - # selber wird aber nicht geändert weil check_mode gleich yes ist - # das Ergebnis wird in der Variable dokuwiki_desired_version gespeichert - # https://raymii.org/s/tutorials/Ansible_-_Only-do-something-if-another-action-changed.html - - - name: download latest dokuwiki archive & unarchive to {{ dokuwiki_install_path }} - become: yes - ansible.builtin.unarchive: - src: "{{ dokuwiki_download_url }}" - dest: "{{ dokuwiki_install_path }}" - remote_src: yes - extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives - owner: "{{ dokuwiki_user }}" - mode: 0744 - when: - - (dokuwiki_desired_version.changed) or - (dokuwiki_install_status.stat.exists == false) - # Dise Variable wird hier abgefragt, so wird das Paket nur heruntergeladen wenn die - # Version Unterschiedlich ist - - - name: Remove default plugins - become: yes - ansible.builtin.file: - path: '{{ dokuwiki_install_path }}/lib/plugins/{{ item }}' - state: absent - with_items: - - authpdo - - authmysql - - authpgsql - - authad - - - name: Change file ownership, group and permissions - become: yes - ansible.builtin.file: - path: "{{ dokuwiki_install_path }}" - owner: "{{ dokuwiki_user }}" - group: "{{ dokuwiki_group }}" - mode: 0744 - - - name: remove installer - file: - path: "{{ dokuwiki_install_path }}/install.php" - state: absent diff --git a/roles/mgrote.dokuwiki/tasks/install.yml b/roles/mgrote.dokuwiki/tasks/install.yml deleted file mode 100644 index 2894d09e..00000000 --- a/roles/mgrote.dokuwiki/tasks/install.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - php - - php-mbstring - - php-xml - - apache2 - - libapache2-mod-php - - php-xml - - php-gd - state: present diff --git a/roles/mgrote.dokuwiki/tasks/main.yml b/roles/mgrote.dokuwiki/tasks/main.yml deleted file mode 100644 index da2d69d1..00000000 --- a/roles/mgrote.dokuwiki/tasks/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: include install tasks - include_tasks: install.yml - - name: include apache2 tasks - include_tasks: apache2.yml - - name: include dokuwiki tasks - include_tasks: dokuwiki.yml diff --git a/roles/mgrote.dotfiles/defaults/main.yml b/roles/mgrote.dotfiles/defaults/main.yml deleted file mode 100644 index 2a50b1e6..00000000 --- a/roles/mgrote.dotfiles/defaults/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - dotfiles_repo_url: https://git.mgrote.net/mg/dotfiles # url zum repo - dotfiles_repo_path: /home/mg/dotfiles # wo soll das repo lokal gespeichert werden - dotfiles_repo_branch: master #default branch for checking out - dotfiles_files: # welche dateien sollen wohin verlinkt werden (ln -s) - - repo_path: "{{ dotfiles_repo_path}}/.vimrc" - local_path: "/home/mg/.vimrc" - dotfiles_dirs: # welche ordner sollen erstellt werden - - path: /home/mg/.config/i3 - - path: /home/mg/.config/polybar - dotfiles_owner: mg # chown diff --git a/roles/mgrote.dotfiles/tasks/main.yml b/roles/mgrote.dotfiles/tasks/main.yml deleted file mode 100644 index 2b758908..00000000 --- a/roles/mgrote.dotfiles/tasks/main.yml +++ /dev/null @@ -1,62 +0,0 @@ ---- - - name: install acl package - become: yes - ansible.builtin.package: - name: acl - state: present - - - name: check if repo exists - stat: - path: "{{ dotfiles_repo_path }}" - register: repo_exists - - - name: set safe directory - become: true - ansible.builtin.shell: - cmd: git config --global --add safe.directory "{{ dotfiles_repo_path }}" - changed_when: false - - - name: stash changes - ansible.builtin.shell: git stash - args: - chdir: "{{ dotfiles_repo_path }}" - changed_when: false - when: repo_exists.stat.exists == true - - - name: Ensure dotfiles repository is cloned locally. - git: - repo: "{{ dotfiles_repo_url }}" - dest: "{{ dotfiles_repo_path }}" - depth: 1 - version: "{{ dotfiles_repo_branch }}" - register: git_clone - - - name: set owner recursive for repo - file: - path: "{{ dotfiles_repo_path }}" - owner: "{{ dotfiles_owner }}" - group: "{{ dotfiles_owner }}" - recurse: yes - when: (git_clone.changed == true) - - - name: Ensure needed dirs exist. - file: - path: "{{ item.path }}" - state: directory - with_items: "{{ dotfiles_dirs }}" - - - name: Link dotfiles into home folder - file: - src: "{{ item.repo_path }}" - dest: "{{ item.local_path }}" - state: link - force: yes - owner: "{{ dotfiles_owner }}" - group: "{{ dotfiles_owner }}" - with_items: "{{ dotfiles_files }}" - - - name: add .bash_extra to .bashrc - ansible.builtin.lineinfile: - path: /home/{{ dotfiles_owner }}/.bashrc - line: "source {{ dotfiles_repo_path }}/.bash_extra" - state: present diff --git a/roles/mgrote.exa/defaults/main.yml b/roles/mgrote.exa/defaults/main.yml deleted file mode 100644 index 2e025db5..00000000 --- a/roles/mgrote.exa/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - exa_url: https://github.com/ogham/exa/releases/download/v0.10.1/exa-linux-x86_64-v0.10.1.zip diff --git a/roles/mgrote.exa/tasks/main.yml b/roles/mgrote.exa/tasks/main.yml deleted file mode 100644 index cca33213..00000000 --- a/roles/mgrote.exa/tasks/main.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- - - name: download & extract exa - become: true - ansible.builtin.unarchive: - src: "{{ exa_url }}" - dest: /usr/local/ - remote_src: yes - owner: root - group: root - mode: 0755 diff --git a/roles/mgrote.fail2ban/defaults/main.yml b/roles/mgrote.fail2ban/defaults/main.yml deleted file mode 100644 index 476f0c81..00000000 --- a/roles/mgrote.fail2ban/defaults/main.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- - # Werte in Sekunden - f2b_bantime: 60 - f2b_findtime: 600 - f2b_maxretry: 5 - f2b_destemail: michael.grote@posteo.de - f2b_sender: info@mgrote.net - f2b_send_email_report: true diff --git a/roles/mgrote.fail2ban/handlers/main.yml b/roles/mgrote.fail2ban/handlers/main.yml deleted file mode 100644 index 33852c6b..00000000 --- a/roles/mgrote.fail2ban/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart_f2b - become: yes - systemd: - name: fail2ban - enabled: yes - state: restarted diff --git a/roles/mgrote.fail2ban/meta/main.yml b/roles/mgrote.fail2ban/meta/main.yml deleted file mode 100644 index 698c58af..00000000 --- a/roles/mgrote.fail2ban/meta/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - dependencies: - - role: mgrote.postfix diff --git a/roles/mgrote.fail2ban/tasks/main.yml b/roles/mgrote.fail2ban/tasks/main.yml deleted file mode 100644 index 174a0bbc..00000000 --- a/roles/mgrote.fail2ban/tasks/main.yml +++ /dev/null @@ -1,22 +0,0 @@ ---- - - name: install fail2ban-packages - become: yes - ansible.builtin.package: - name: fail2ban - state: present - - - name: copy jail.local - become: yes - ansible.builtin.template: - src: jail.local - dest: /etc/fail2ban/jail.local - mode: 0750 - notify: restart_f2b - - - name: copy sendmail-common.local - become: yes - ansible.builtin.template: - src: sendmail-common.local - dest: /etc/fail2ban/action.d/sendmail-common.local - mode: 0750 - notify: restart_f2b diff --git a/roles/mgrote.fileserver_smb/defaults/main.yml b/roles/mgrote.fileserver_smb/defaults/main.yml deleted file mode 100644 index 5c9932ea..00000000 --- a/roles/mgrote.fileserver_smb/defaults/main.yml +++ /dev/null @@ -1,107 +0,0 @@ ---- - # Global SMB options - ## "smb_global_options" = dict - ## -option: "smbd option name" <-- value - ## value: "smbd value" <-- value - ## neue Optionen konnen einfach angehangen werden bzw. alte entfernt werden - smb_global_options: - - option: min protocol - value: "SMB2_02" - - option: client min protocol - value: "SMB2_02" - - option: client max protocol - value: "SMB3_00" - - option: log level - value: "1" - - option: log file - value: "/var/log/samba/log" - - option: max log size - value: "1000" - - option: logging - value: "syslog" - - option: panic action - value: "/usr/share/samba/panic-action_%d" - - option: passdb backend - value: "tdbsam" - - option: obey pam restrictions - value: "no" - - option: unix password sync - value: "no" - - option: passwd program - value: "/usr/bin/passwd_%u" - - option: passwd chat - value: '*Enter\snew\s*\spassword:*_%n\n_*Retype\snew\s*\spassword:*_%n\n_*password\supdated\ssuccessfully*_.' - - option: pam password change - value: "yes" - - option: guest account - value: "nobody" - - option: load printers - value: "no" - - option: unix extensions - value: "yes" - - option: wide links - value: "no" - - option: create mask - value: "0777" - - option: directory mask - value: "0777" - - option: map to guest - value: "Bad User" - - option: use sendfile - value: "yes" - - option: aio read size - value: "16384" - - option: aio write size - value: "16384" - - option: local master - value: "yes" - - option: time server - value: "no" - - option: wins support - value: "no" - - option: acl allow execute always - value: "yes" - - option: force user - value: "root" - - option: force group - value: "users" - - option: workgroup - value: WORKGROUP - - option: server string - value: "%h_server" - - # packages - smb_packages: - - samba - - cifs-utils - - samba-common - - samba-common-bin - - samba-vfs-modules - - # zfs-snapshots einbinden - ## als \.zfs\snapshot einbinden - ## sorgt dafur das statt "A0KDC9~F" die Ordnernamen als "autosnap_2021-11-04_23÷59÷02_daily" angezeigt werden - ## https://www.samba.org/samba/docs/current/man-html/vfs_catia.8.html - # aktiv? - smb_enable_snapshots_dir: true - # welche Character/zeichen-Ersetzungen soll catia ausführen - smb_catia_mappings: "0x3a:0xf7" # ersetzt ":" durch "÷" - - # als Windows-Shattenkopien einbinden - ## https://www.samba.org/samba/docs/current/man-html/vfs_shadow_copy2.8.html - ## BUG: Windows sieht die Schattenkopien, kann die Ausgewählte Datei aber nicht öffnen wenn sie seit dem Snapshot gelöscht wurde, vmtl da Windows nicht den kompletten Snapshot-Pfad verwendet - ## Format ist passend fur sanoid-Snapshots - # aktiv? - smb_enable_snapshots_shadow: false - # wo liegen die Snapshots - smb_shadow_snapdir: ".zfs/snapshot" - # Sortierung - smb_shadow_sort: "desc" - # Datumsformat der Snapshots - smb_shadow_format: "_%Y-%m-%d_%H:%M:%S" - # Snapshot-Präfix - smb_shadow_snapprefix: "^autosnap" - # Snapshot-"Trenner" - smb_shadow_delimiter: "_" - # zeitformat Snapshots - smb_shadow_localtime: "no" diff --git a/roles/mgrote.fileserver_smb/handlers/main.yml b/roles/mgrote.fileserver_smb/handlers/main.yml deleted file mode 100644 index edebb285..00000000 --- a/roles/mgrote.fileserver_smb/handlers/main.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- - - name: restart smbd - become: yes - systemd: - name: smbd - enabled: yes - state: restarted - - - name: set samba passwords - become: yes - shell: "printf '{{ item.password }}\n{{ item.password }}\n' | smbpasswd -a {{ item.name }}" # noqa no-changed-when risky-shell-pipe - #pipefail: https://blog.christophersmart.com/2019/09/28/using-pipefail-with-shell-module-in-ansible/ - with_items: - - "{{ smb_users }}" - no_log: True diff --git a/roles/mgrote.fileserver_smb/tasks/main.yml b/roles/mgrote.fileserver_smb/tasks/main.yml deleted file mode 100644 index 0b808ce3..00000000 --- a/roles/mgrote.fileserver_smb/tasks/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - - name: include install tasks - include_tasks: packages.yml - - - name: include user tasks - include_tasks: users.yml - when: smb_users is defined - - - name: include share tasks - include_tasks: shares.yml - when: smb_shares is defined diff --git a/roles/mgrote.fileserver_smb/tasks/packages.yml b/roles/mgrote.fileserver_smb/tasks/packages.yml deleted file mode 100644 index a306a2ca..00000000 --- a/roles/mgrote.fileserver_smb/tasks/packages.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - - name: ensure packages are installed - become: yes - ansible.builtin.package: - name: "{{ smb_packages }}" - state: present diff --git a/roles/mgrote.fileserver_smb/tasks/shares.yml b/roles/mgrote.fileserver_smb/tasks/shares.yml deleted file mode 100644 index 3ad48a1c..00000000 --- a/roles/mgrote.fileserver_smb/tasks/shares.yml +++ /dev/null @@ -1,21 +0,0 @@ ---- - - name: ensure smb share directories exist - become: yes - ansible.builtin.file: - path: "{{ item.path }}" - state: directory - mode: 0777 - loop: "{{ smb_shares }}" - notify: set samba passwords - - - name: template share configuration - become: yes - ansible.builtin.template: - src: smb.conf.j2 - dest: /etc/samba/smb.conf - validate: 'testparm -s %s' - with_items: - - "{{ smb_shares }}" - notify: - - restart smbd - - set samba passwords diff --git a/roles/mgrote.fileserver_smb/tasks/users.yml b/roles/mgrote.fileserver_smb/tasks/users.yml deleted file mode 100644 index d20d81af..00000000 --- a/roles/mgrote.fileserver_smb/tasks/users.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - - name: ensure group exist - become: yes - ansible.builtin.group: - name: smb_users - state: present - - - name: configure linux-users - become: yes - ansible.builtin.user: - name: "{{ item.name }}" - group: smb_users - state: "{{ item.state | default('present') }}" - remove: "{{ item.remove_dir | default('false') }}" - create_home: no - loop: "{{ smb_users }}" - no_log: True - notify: set samba passwords diff --git a/roles/mgrote.fluxcd/defaults/main.yml b/roles/mgrote.fluxcd/defaults/main.yml deleted file mode 100644 index 98110d90..00000000 --- a/roles/mgrote.fluxcd/defaults/main.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- - flux_repo_host: gitea.grote.lan - flux_repo_host_port: 2222 - flux_repo_branch: master - flux_repo_url_complete: "ssh://gitea@{{ flux_repo_host }}:{{ flux_repo_host_port }}/mg/manifests.git" - flux_install_host: k3s1.grote.lan - flux_homedir: /home/flux - flux_path_ssh_dir: /home/flux/.ssh - flux_user_group: flux - flux_user: flux - flux_download_url: https://github.com/fluxcd/flux2/releases/download/v0.35.0/flux_0.35.0_linux_amd64.tar.gz - flux_path_bin: /usr/local/sbin - flux_path_ssh_id_file: id_rsa - flux_ssh_key_format: ed25519 - kubeconfig: /etc/rancher/k3s/k3s.yaml - flux_sync_interval: 1m diff --git a/roles/mgrote.fluxcd/tasks/main.yml b/roles/mgrote.fluxcd/tasks/main.yml deleted file mode 100644 index 1a7c09e2..00000000 --- a/roles/mgrote.fluxcd/tasks/main.yml +++ /dev/null @@ -1,95 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - name: check if flux is installed - command: which flux - changed_when: false - failed_when: flux_installed.rc not in [0,1] - register: flux_installed - - - name: download flux binary - ansible.builtin.unarchive: - src: "{{ flux_download_url }}" - dest: "{{ flux_path_bin }}" - mode: 0755 - owner: "{{ flux_user }}" - group: "{{ flux_user_group }}" - remote_src: yes - creates: "{{ flux_path_bin }}/flux" - when: flux_installed.rc not in [ 0 ] - - - name: install bash-completion packages - become: yes - ansible.builtin.package: - name: bash-completion - state: present - - - name: activate autocompletion for flux - become: yes - ansible.builtin.shell: - cmd: "flux completion bash | sudo tee /etc/bash_completion.d/flux" - args: - creates: /etc/bash_completion.d/flux - - - name: install flux - block: - - name: ensure .ssh directory exists - ansible.builtin.file: - path: "{{ flux_path_ssh_dir }}" - owner: "{{ flux_user }}" - group: "{{ flux_user_group }}" - state: directory - - - name: check if OpenSSH keypair exists - stat: - path: "{{ flux_path_ssh_dir }}/{{ flux_path_ssh_id_file }}" - register: ssh_exist - - - name: generate SSH keypair - community.crypto.openssh_keypair: - path: "{{ flux_path_ssh_dir }}/{{ flux_path_ssh_id_file }}" - owner: "{{ flux_user }}" - group: "{{ flux_user_group }}" - type: "{{ flux_ssh_key_format }}" - when: ssh_exist.stat.exists == False - register: create_ssh_key - - - name: get publickey - ansible.builtin.command: cat "{{ flux_path_ssh_dir }}/{{ flux_path_ssh_id_file }}.pub" - when: create_ssh_key.changed - register: ssh_public_key - - - name: show publickey - debug: - msg: "{{ ssh_public_key.stdout }}" - when: create_ssh_key.changed - - - name: copy publickey to gitea as deploy-key WITH write-permissions! - ansible.builtin.pause: - prompt: "Make sure the key is saved!" - when: create_ssh_key.changed - - - name: set permissions for $kubeconfig - ansible.builtin.file: - path: "{{ kubeconfig }}" - owner: root - group: root - mode: '0644' - - - name: template bootstrap script - ansible.builtin.template: - src: bootstrap.sh - dest: "{{ flux_homedir }}/bootstrap.sh" - mode: 0544 - owner: "{{ flux_user }}" - group: "{{ flux_user_group }}" - register: bootstrap - - - name: flux install - ansible.builtin.shell: "{{ flux_homedir }}/bootstrap.sh" - become_user: "{{ flux_user }}" - when: bootstrap.changed - # der ganze block nur auf einem host - run_once: true - when: ansible_host == flux_install_host diff --git a/roles/mgrote.fluxcd/tasks/user.yml b/roles/mgrote.fluxcd/tasks/user.yml deleted file mode 100644 index 83c47487..00000000 --- a/roles/mgrote.fluxcd/tasks/user.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ flux_user_group }}" - state: present - when: - - flux_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ flux_user }}" - group: "{{ flux_user_group }}" - create_home: no - when: - - flux_user_group is defined - - flux_user is defined diff --git a/roles/mgrote.fwupd_settings/defaults/main.yml b/roles/mgrote.fwupd_settings/defaults/main.yml deleted file mode 100644 index 3ee85da2..00000000 --- a/roles/mgrote.fwupd_settings/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - fwupd_dynamic_user: false diff --git a/roles/mgrote.fwupd_settings/handlers/main.yml b/roles/mgrote.fwupd_settings/handlers/main.yml deleted file mode 100644 index 4d2e5c5f..00000000 --- a/roles/mgrote.fwupd_settings/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - state: restarted - daemon_reload: yes - name: fwupd-refresh.service diff --git a/roles/mgrote.fwupd_settings/tasks/main.yml b/roles/mgrote.fwupd_settings/tasks/main.yml deleted file mode 100644 index a43c5467..00000000 --- a/roles/mgrote.fwupd_settings/tasks/main.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- - - name: gather service facts - service_facts: - - - name: set DynamicUser=no - ansible.builtin.blockinfile: - path: /etc/systemd/system/fwupd-refresh.service.d/override.conf - block: | - [Service] - DynamicUser=no - create: yes - when: - - "not fwupd_dynamic_user and 'fwupd-refresh.service' in services" - notify: systemctl daemon-reload diff --git a/roles/mgrote.i3/tasks/main.yml b/roles/mgrote.i3/tasks/main.yml deleted file mode 100644 index ad771e9a..00000000 --- a/roles/mgrote.i3/tasks/main.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - i3 - - i3lock - - arandr - - x11-xserver-utils # xrandr - - feh # wallpaper - - rofi - - xautolock #bildschirmsperre nach x min - - flameshot #screenshots - - dunst #notification daemon - state: present diff --git a/roles/mgrote.k8s_autocompletion/tasks/main.yml b/roles/mgrote.k8s_autocompletion/tasks/main.yml deleted file mode 100644 index 1502f9f5..00000000 --- a/roles/mgrote.k8s_autocompletion/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- - - name: install bash-completion packages - become: yes - ansible.builtin.package: - name: bash-completion - state: present - - - name: activate autocompletion for kubectl - become: yes - ansible.builtin.shell: - cmd: "kubectl completion bash | sudo tee /etc/bash_completion.d/kubectl" - args: - creates: /etc/bash_completion.d/kubectl diff --git a/roles/mgrote.k8s_misc/tasks/main.yml b/roles/mgrote.k8s_misc/tasks/main.yml deleted file mode 100644 index 9393cade..00000000 --- a/roles/mgrote.k8s_misc/tasks/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: set $KUBECONFIG for root - ansible.builtin.blockinfile: - path: /root/.bashrc - block: | - export KUBECONFIG=/etc/rancher/k3s/k3s.yaml - marker: "# {mark} ANSIBLE MANAGED BLOCK - K3S" diff --git a/roles/mgrote.minio/defaults/main.yml b/roles/mgrote.minio/defaults/main.yml deleted file mode 100644 index eb80b63f..00000000 --- a/roles/mgrote.minio/defaults/main.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- - minio_download_url: https://dl.min.io/server/minio/release/linux-amd64/minio # downloadlink - - minio_bin_path: /usr/local/bin # where to put the binary - minio_volumes_base_dir: /usr/local/share/minio/ # where to store the buckets - minio_config_dir: /etc/minio # where to store the config - - minio_fqdn: minio-test.grote.lan - minio_port: 9000 # s3 port - minio_console_port: 34081 # mgmt-gui port - - minio_root_user: minio # default web user - minio_root_password: miniostorage # defaut pass - - minio_user: minio-user # linux user - minio_group: minio-user # linux group - - minio_server_url: "" # see https://docs.min.io/minio/baremetal/reference/minio-server/minio-server.html - - minio_browser_redirect_url: "" # see https://docs.min.io/minio/baremetal/reference/minio-server/minio-server.html diff --git a/roles/mgrote.minio/handlers/main.yml b/roles/mgrote.minio/handlers/main.yml deleted file mode 100644 index 7a274555..00000000 --- a/roles/mgrote.minio/handlers/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - - name: (re)start service - become: yes - ansible.builtin.systemd: - name: minio - state: restarted diff --git a/roles/mgrote.minio/tasks/main.yml b/roles/mgrote.minio/tasks/main.yml deleted file mode 100644 index 22674944..00000000 --- a/roles/mgrote.minio/tasks/main.yml +++ /dev/null @@ -1,62 +0,0 @@ ---- - - name: ensure group exists - ansible.builtin.group: - name: "{{ minio_group }}" - state: present - - - name: ensure user exists - ansible.builtin.user: - name: "{{ minio_user }}" - group: "{{ minio_group }}" - shell: /sbin/nologin - state: present - create_home: no - - - name: ensure needed directories are present - file: - path: "{{ item }}" - state: directory - owner: "{{ minio_user }}" - group: "{{ minio_user }}" - with_items: - - "{{ minio_volumes_base_dir }}" - - "{{ minio_config_dir }}" - - - name: download binary - get_url: - url: "{{ minio_download_url }}" - dest: "{{ minio_bin_path }}/minio" - mode: 0744 - owner: "{{ minio_user }}" - group: "{{ minio_user }}" - - - name: template default config - become: yes - ansible.builtin.template: - src: "default.j2" - dest: "/etc/default/minio" - owner: "{{ minio_user }}" - group: "{{ minio_user }}" - notify: (re)start service - no_log: true - - - name: template systemd-unit - become: yes - ansible.builtin.template: - src: "minio.service.j2" - dest: "/etc/systemd/system/minio.service" - mode: a+x - owner: "{{ minio_user }}" - group: "{{ minio_user }}" - notify: (re)start service - - - name: systemd daemon reload - become: yes - ansible.builtin.systemd: - daemon_reload: true - - - name: enable systemd service - become: yes - ansible.builtin.systemd: - name: minio - enabled: true diff --git a/roles/mgrote.motd/defaults/main.yml b/roles/mgrote.motd/defaults/main.yml deleted file mode 100644 index 34204f27..00000000 --- a/roles/mgrote.motd/defaults/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- - motd_wetter_ort: "Magdeburg" - motd_wetter_aktiv: false - motd_fortune_aktiv: false - - managed_files: - - 00-ansible - - 05-fortune - - 10-wetter - - 20-facts - - 90-updates - - 91-reboot diff --git a/roles/mgrote.motd/handlers/main.yml b/roles/mgrote.motd/handlers/main.yml deleted file mode 100644 index c3eb3398..00000000 --- a/roles/mgrote.motd/handlers/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - - name: restart_sshd - become: yes - systemd: - name: sshd - state: restarted diff --git a/roles/mgrote.motd/tasks/base.yml b/roles/mgrote.motd/tasks/base.yml deleted file mode 100644 index a0429a0e..00000000 --- a/roles/mgrote.motd/tasks/base.yml +++ /dev/null @@ -1,70 +0,0 @@ ---- -# - name: install packages -# become: yes -# ansible.builtin.package: -# name: -# - update-motd -# state: present -# when: "ansible_facts['distribution'] == 'Ubuntu'" - - - name: remove default packages - become: yes - ansible.builtin.package: - name: - - motd-news-config - state: absent - - - name: 'remove unwanted motd messages' - become: yes - ansible.builtin.file: - path: '/etc/update-motd.d/{{ item }}' - state: absent - with_items: - - 00-header - - 10-help-text - - 10-uname - - 50-motd-news - - 80-livepatch - - 50-landscape-sysinfo - - 51-cloudguest - - 99-esm - - 00-ansible - - 20-facts - - 90-updates - - 91-reboot - - 90-updates-available - - 91-release-upgrade - - - name: delete "no warranty" - Message - become: yes - ansible.builtin.file: - path: /etc/motd - state: absent - - - name: setup new motd - become: yes - ansible.builtin.template: - src: '{{ item }}' - dest: '/etc/update-motd.d/{{ item }}' - owner: root - group: root - mode: '755' - with_items: - - 00-ansible-mgrote - - 20-facts-mgrote - - 90-updates-mgrote - - 91-reboot-mgrote - - - name: delete fortune - become: yes - ansible.builtin.file: - path: /etc/update-motd.d/05-fortune-mgrote - state: absent - when: not motd_fortune_aktiv - - - name: delete Wetter - become: yes - ansible.builtin.file: - path: '/etc/update-motd.d/10-wetter-mgrote' - state: absent - when: not motd_wetter_aktiv diff --git a/roles/mgrote.motd/tasks/fortune.yml b/roles/mgrote.motd/tasks/fortune.yml deleted file mode 100644 index 3547f27b..00000000 --- a/roles/mgrote.motd/tasks/fortune.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- - - name: install fortune - become: yes - ansible.builtin.package: - name: - - fortune - state: present - - - name: setup new motd - fortune - become: yes - ansible.builtin.template: - src: '05-fortune-mgrote' - dest: '/etc/update-motd.d/05-fortune-mgrote' - owner: root - group: root - mode: '755' diff --git a/roles/mgrote.motd/tasks/main.yml b/roles/mgrote.motd/tasks/main.yml deleted file mode 100644 index 493099ef..00000000 --- a/roles/mgrote.motd/tasks/main.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- - - name: include systemctl tasks - include_tasks: systemctl.yml - - - name: include base tasks - include_tasks: base.yml - - name: include fortune tasks - include_tasks: fortune.yml - when: - - motd_wetter_aktiv - - - name: include weather tasks - include_tasks: weather.yml - when: - - motd_wetter_aktiv diff --git a/roles/mgrote.motd/tasks/systemctl.yml b/roles/mgrote.motd/tasks/systemctl.yml deleted file mode 100644 index 36727804..00000000 --- a/roles/mgrote.motd/tasks/systemctl.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- - - name: stop units - become: yes - ansible.builtin.systemd: - name: motd-news - masked: yes - state: stopped - enabled: no - daemon_reload: yes - ignore_errors: true diff --git a/roles/mgrote.motd/tasks/weather.yml b/roles/mgrote.motd/tasks/weather.yml deleted file mode 100644 index eea72ea6..00000000 --- a/roles/mgrote.motd/tasks/weather.yml +++ /dev/null @@ -1,8 +0,0 @@ - - name: setup new motd - wetter - become: yes - ansible.builtin.template: - src: '10-wetter-mgrote' - dest: '/etc/update-motd.d/10-wetter-mgrote' - owner: root - group: root - mode: '755' diff --git a/roles/mgrote.mount_cifs/defaults/main.yml b/roles/mgrote.mount_cifs/defaults/main.yml deleted file mode 100644 index 1acff73b..00000000 --- a/roles/mgrote.mount_cifs/defaults/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- - cifs_mounts: - - name: pve_backup_mount_fileserver3 - type: cifs - state: absent - dest: /pve_backup_mount - src: //fileserver3.grote.lan/proxmox - user: pve - password: XXXXXXXXXXXXXXX - domain: grote.lan - uid: 1000 - gid: 1000 diff --git a/roles/mgrote.mount_cifs/handlers/main.yml b/roles/mgrote.mount_cifs/handlers/main.yml deleted file mode 100644 index 1ac62ba0..00000000 --- a/roles/mgrote.mount_cifs/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: reboot - become: true - reboot: - reboot_timeout: 120 diff --git a/roles/mgrote.mount_cifs/meta/main.yml b/roles/mgrote.mount_cifs/meta/main.yml deleted file mode 100644 index 083a97f6..00000000 --- a/roles/mgrote.mount_cifs/meta/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - collections: - - ansible.posix diff --git a/roles/mgrote.mount_cifs/tasks/main.yml b/roles/mgrote.mount_cifs/tasks/main.yml deleted file mode 100644 index 4146d161..00000000 --- a/roles/mgrote.mount_cifs/tasks/main.yml +++ /dev/null @@ -1,41 +0,0 @@ ---- - - name: install cifs-utils - become: yes - ansible.builtin.package: - name: cifs-utils - state: present - - - name: create mount directory - become: yes - ansible.builtin.file: - path: "{{ item.dest }}" - state: directory - mode: 0777 - loop: "{{ cifs_mounts }}" - no_log: true - - - name: create credential-file - become: yes - ansible.builtin.template: - src: smb_passwords - dest: /root/.smb_passwords_{{ item.name }} - owner: root - group: root - mode: '0400' - loop: "{{ cifs_mounts }}" - no_log: true - - - name: mount cifs volumes - become: yes - ansible.posix.mount: - src: "{{ item.src }}" - path: "{{ item.dest }}" - opts: credentials=/root/.smb_passwords_{{ item.name }},domain={{ item.domain }},uid={{ item.uid | default('1000') }},gid={{ item.gid | default('1000') }}" - state: "{{ item.state }}" - fstype: "{{ item.type }}" - backup: yes - dump: "0" - passno: "0" - loop: "{{ cifs_mounts }}" - no_log: true - notify: reboot diff --git a/roles/mgrote.munin-node/defaults/main.yml b/roles/mgrote.munin-node/defaults/main.yml deleted file mode 100644 index 2723ad8e..00000000 --- a/roles/mgrote.munin-node/defaults/main.yml +++ /dev/null @@ -1,33 +0,0 @@ ---- - munin_user_group: root # group to which the user belongs - munin_node_log: /var/log/munin/munin-node.log - munin_node_pid: /var/run/munin/munin-node.pid - munin_node_plugin_timeout: 60 # in sec - munin_node_global_timeout: 900 # in sec - munin_node_host_name: '' # Set this if the client doesn't report the correct hostname - munin_node_allowed_ips: # A list of addresses that are allowed to connect Munin requires IPs be added as regular expressions. - - '^127\.0\.0\.1$' - - '^::1$' - munin_node_allowed_cidrs: [192.168.2.0/24] # A list of addresses that are allowed to connect - munin_node_denied_cidrs: [] # a list of addresses that are not allowed to connect - munin_node_bind_host: "0.0.0.0" # bind to interface - munin_node_bind_port: "4949" # bind to port - munin_node_log_level: 4 # Loglevel - - # Plugin configuration options (the key is the plugin heading, items within will - # be options for the plugin). - # Source and destination of munin plugins. - munin_plugin_src_path: /usr/share/munin/plugins/ - munin_plugin_dest_path: /etc/munin/plugins/ - munin_plugin_conf_dest_path: /etc/munin/plugin-conf.d/ -# munin_node_plugins: #plugins to install -# - name: docker_volumes # name -# src: https://git.mgrote.net/mg/mirror-munin-contrib/raw/branch/master/plugins/docker/docker_ #src -# config_file_name: /etc/munin/plugin-conf.d/docker # where to put plugin config - # content of config -# config: | -# user root -# env.DOCKER_HOST unix://run/docker.sock - -# munin_node_disabled_plugins: # remove plugins from running config -# - name: meminfo diff --git a/roles/mgrote.munin-node/handlers/main.yml b/roles/mgrote.munin-node/handlers/main.yml deleted file mode 100644 index 0b7f394e..00000000 --- a/roles/mgrote.munin-node/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: restart munin-node - service: - name: munin-node - state: restarted diff --git a/roles/mgrote.munin-node/tasks/additional.yml b/roles/mgrote.munin-node/tasks/additional.yml deleted file mode 100644 index de6ae4b5..00000000 --- a/roles/mgrote.munin-node/tasks/additional.yml +++ /dev/null @@ -1,34 +0,0 @@ ---- - - name: download additional plugins - get_url: - url: "{{ item.src }}" - dest: "{{ munin_plugin_src_path }}{{ item.name }}" - mode: '0755' - loop: "{{ munin_node_plugins }}" - notify: restart munin-node - no_log: true - check_mode: no # damit werden auch im check-mode die Plugins heruntergeladen, sonst schlägt der nächste Task fehl - - - name: enable additional plugins - file: - src: "{{ munin_plugin_src_path }}{{ item.name }}" - dest: "{{ munin_plugin_dest_path }}{{ item.name }}" - state: link - notify: restart munin-node - loop: "{{ munin_node_plugins }}" - no_log: true - - - name: copy additional plugin-config - copy: - content: "{{ item.config }}" - dest: "{{ munin_plugin_conf_dest_path }}{{ item.name }}" - notify: restart munin-node - loop: "{{ munin_node_plugins }}" - when: item.config is defined - no_log: true - - - name: Ensure munin-node is running. - service: - name: munin-node - state: started - enabled: yes diff --git a/roles/mgrote.munin-node/tasks/install.yml b/roles/mgrote.munin-node/tasks/install.yml deleted file mode 100644 index 0efd0fa0..00000000 --- a/roles/mgrote.munin-node/tasks/install.yml +++ /dev/null @@ -1,36 +0,0 @@ ---- - - name: install packages - apt: - name: munin-node - state: present - register: install - - - name: create directories - file: - path: "{{ item }}" - state: directory - loop: - - /etc/munin - - /etc/munin/plugin-conf.d - - /etc/munin/plugins - - - name: Copy munin-node configuration. - template: - src: munin-node.conf.j2 - dest: /etc/munin/munin-node.conf - owner: root - group: root - mode: 0644 - notify: restart munin-node - - - name: munin-node-configure --shell - ansible.builtin.shell: munin-node-configure --shell - register: output_conf - changed_when: "output_conf.rc != 0" - ignore_errors: yes # ignoriere fehler - when: install.changed - - - name: munin-node-configure --shell - 2 - ansible.builtin.shell: munin-node-configure --shell --families=contrib,auto | sh -x - ignore_errors: yes # ignoriere fehler - when: install.changed diff --git a/roles/mgrote.munin-node/tasks/main.yml b/roles/mgrote.munin-node/tasks/main.yml deleted file mode 100644 index b8074b34..00000000 --- a/roles/mgrote.munin-node/tasks/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - - name: include install-tasks - include_tasks: install.yml - - name: include user tasks - include_tasks: user.yml - - name: include plugin-tasks - include_tasks: additional.yml - when: munin_node_plugins is defined - - name: include remove-tasks - include_tasks: remove.yml - when: munin_node_disabled_plugins is defined diff --git a/roles/mgrote.munin-node/tasks/remove.yml b/roles/mgrote.munin-node/tasks/remove.yml deleted file mode 100644 index 356a1ce0..00000000 --- a/roles/mgrote.munin-node/tasks/remove.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- - - name: remove unwanted plugins - file: - path: "{{ munin_plugin_dest_path }}{{ item.name }}" - state: absent - loop: "{{ munin_node_disabled_plugins }}" - notify: restart munin-node - when: munin_node_disabled_plugins is defined - - - name: remove additional plugin-config - file: - state: absent - dest: "{{ munin_plugin_conf_dest_path }}{{ item.name }}" - notify: restart munin-node - loop: "{{ munin_node_disabled_plugins }}" - when: munin_node_disabled_plugins is defined diff --git a/roles/mgrote.munin-node/tasks/user.yml b/roles/mgrote.munin-node/tasks/user.yml deleted file mode 100644 index e6b41fce..00000000 --- a/roles/mgrote.munin-node/tasks/user.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ munin_user_group }}" - state: present - - - name: ensure user exists - become: true - ansible.builtin.user: - name: munin - group: "{{ munin_user_group }}" - shell: /usr/sbin/nologin - create_home: no - - - name: add user to sudoers - become: true - ansible.builtin.blockinfile: - path: /etc/sudoers - state: present - block: | - munin ALL=(ALL) NOPASSWD:ALL - validate: '/usr/sbin/visudo -cf %s' - backup: yes - marker_begin: munin-sudoers BEGIN - marker_end: munin-sudoers END diff --git a/roles/mgrote.ntp_chrony_client/defaults/main.yml b/roles/mgrote.ntp_chrony_client/defaults/main.yml deleted file mode 100644 index 77b7c1c0..00000000 --- a/roles/mgrote.ntp_chrony_client/defaults/main.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- - ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet - ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile - ntp_chrony_servers: # welche Server sollen befragt werden - - address: ptbtime1.ptb.de - options: iburst #optionaler parameter - ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst - ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst - ntp_chrony_logging: false diff --git a/roles/mgrote.ntp_chrony_client/handlers/main.yml b/roles/mgrote.ntp_chrony_client/handlers/main.yml deleted file mode 100644 index 89bbb0db..00000000 --- a/roles/mgrote.ntp_chrony_client/handlers/main.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- - - name: restart_chrony - become: yes - systemd: - name: chrony - enabled: yes - masked: false - state: restarted diff --git a/roles/mgrote.ntp_chrony_client/tasks/main.yml b/roles/mgrote.ntp_chrony_client/tasks/main.yml deleted file mode 100644 index 76aa6763..00000000 --- a/roles/mgrote.ntp_chrony_client/tasks/main.yml +++ /dev/null @@ -1,67 +0,0 @@ ---- - - name: Check systemd-timesyncd status - become: true - shell: systemctl is-active --quiet systemd-timesyncd && echo "Active" || echo "Inactive" - register: timesyncd_status - changed_when: false - - - name: Disable systemd-timesyncd - become: true - ansible.builtin.systemd: - name: systemd-timesyncd - masked: yes - state: stopped - when: timesyncd_status.stdout == "Active" - - - name: gather package facts - become: yes - ansible.builtin.package_facts: - manager: auto - - - name: stop and mask ntp service - become: yes - systemd: - name: ntp - masked: yes - state: stopped - when: "'ntp' in ansible_facts.packages" - - - name: install chrony packages - become: yes - ansible.builtin.package: - name: - - chrony - state: present - notify: restart_chrony - - - name: copy chrony config - become: yes - ansible.builtin.template: - src: chrony.conf.j2 - dest: /etc/chrony/chrony.conf - mode: 0755 - notify: restart_chrony - - - name: copy logrotate config - become: yes - ansible.builtin.template: - src: logrotate_chrony - dest: /etc/logrotate.d/chrony - owner: root - group: root - mode: 0644 - - - name: Create chrony driftfile folder - become: yes - file: - state: directory - path: "{{ ntp_chrony_driftfile_directory }}" - mode: 0755 - owner: "{{ ntp_chrony_user }}" - group: "{{ ntp_chrony_group }}" - notify: restart_chrony - - - name: set timezone to {{ ntp_chrony_timezone }} - become: yes - community.general.timezone: - name: "{{ ntp_chrony_timezone }}" diff --git a/roles/mgrote.ntp_chrony_server/defaults/main.yml b/roles/mgrote.ntp_chrony_server/defaults/main.yml deleted file mode 100644 index b443e1d9..00000000 --- a/roles/mgrote.ntp_chrony_server/defaults/main.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet - ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile - ntp_chrony_servers: # welche Server sollen befragt werden - - address: ptbtime1.ptb.de - options: iburst #optionaler parameter - - address: ptbtime2.ptb.de - options: iburst - - address: ptbtime3.ptb.de - options: iburst - - address: time3.google.com - options: iburst - - address: ntp0.fau.de - options: iburst - ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst - ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst - ntp_chrony_logging: false # logging an/aus - ntp_chrony_subnet_allow: 192.168.2.0/24 # welche Netze dürfen den Server befragen diff --git a/roles/mgrote.ntp_chrony_server/handlers/main.yml b/roles/mgrote.ntp_chrony_server/handlers/main.yml deleted file mode 100644 index b0edc26f..00000000 --- a/roles/mgrote.ntp_chrony_server/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart_chrony - become: yes - systemd: - name: chrony - enabled: yes - state: restarted diff --git a/roles/mgrote.ntp_chrony_server/tasks/main.yml b/roles/mgrote.ntp_chrony_server/tasks/main.yml deleted file mode 100644 index 1c5420ca..00000000 --- a/roles/mgrote.ntp_chrony_server/tasks/main.yml +++ /dev/null @@ -1,59 +0,0 @@ ---- - - name: mask systemd-timesyncd service - become: yes - systemd: - name: systemd-timesyncd - state: stopped - masked: yes - - - name: gather package facts - become: yes - ansible.builtin.package_facts: - manager: auto - - - name: stop and mask ntp service - become: yes - systemd: - name: ntp - masked: yes - state: stopped - when: "'ntp' in ansible_facts.packages" - - - name: install chrony packages - become: yes - ansible.builtin.package: - name: - - chrony - state: present - notify: restart_chrony - - - name: copy chrony config - become: yes - ansible.builtin.template: - src: chrony.conf.j2 - dest: /etc/chrony/chrony.conf - mode: 0755 - notify: restart_chrony - - - name: copy logrotate config - become: yes - ansible.builtin.template: - src: logrotate_chrony - dest: /etc/logrotate.d/chrony - owner: root - group: root - mode: 0644 - - name: Create chrony driftfile folder - become: yes - file: - state: directory - path: "{{ ntp_chrony_driftfile_directory }}" - mode: 0755 - owner: "{{ ntp_chrony_user }}" - group: "{{ ntp_chrony_group }}" - notify: restart_chrony - - - name: set timezone to {{ ntp_chrony_timezone }} - become: yes - community.general.timezone: - name: "{{ ntp_chrony_timezone }}" diff --git a/roles/mgrote.pbs_datastores/tasks/main.yml b/roles/mgrote.pbs_datastores/tasks/main.yml deleted file mode 100644 index 6136fbdc..00000000 --- a/roles/mgrote.pbs_datastores/tasks/main.yml +++ /dev/null @@ -1,42 +0,0 @@ ---- - - name: check if datastores exist - become: yes - ansible.builtin.command: "proxmox-backup-manager datastore list --output-format json" - register: datastores - changed_when: false - - - name: ensure datastores exist - become: yes - ansible.builtin.command: "proxmox-backup-manager datastore create {{ item.name }} {{ item.path }}" - loop: "{{ pbs_datastores }}" - when: "item.name not in datastores.stdout" - - - name: ensure datastores are configured - become: yes - ansible.builtin.template: - src: datastores.j2 - dest: /etc/proxmox-backup/datastore.cfg - owner: root - group: backup - mode: "640" - backup: yes - - - name: ensure prune-jobs are configured - become: yes - ansible.builtin.template: - src: prune-jobs.j2 - dest: /etc/proxmox-backup/prune.cfg - owner: root - group: backup - mode: "640" - backup: yes - - - name: ensure permissions are configured - become: yes - ansible.builtin.template: - src: permissions.j2 - dest: /etc/proxmox-backup/acl.cfg - owner: root - group: backup - mode: "640" - backup: yes diff --git a/roles/mgrote.pbs_pve_integration/tasks/main.yml b/roles/mgrote.pbs_pve_integration/tasks/main.yml deleted file mode 100644 index 0425807e..00000000 --- a/roles/mgrote.pbs_pve_integration/tasks/main.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: check which storages exist - become: yes - ansible.builtin.shell: "pvesm status | awk '{ print $1}'" - register: storages - changed_when: false - - - name: ensure datastore exist - become: yes - ansible.builtin.command: "pvesm add pbs {{ item.name }} --server {{ item.server }} --datastore {{ item.datastore }} --username {{ item.username }} --password {{ item.password }} --fingerprint {{ item.fingerprint }}" - loop: "{{ pve_pbs_datastore }}" - when: "item.name not in storages.stdout" - - - name: ensure datastore is configured - become: yes - ansible.builtin.command: "pvesm set {{ item.name }} --username {{ item.username }} --password {{ item.password }}" - loop: "{{ pve_pbs_datastore }}" - when: "item.name in storages.stdout" - changed_when: false diff --git a/roles/mgrote.pbs_users/tasks/main.yml b/roles/mgrote.pbs_users/tasks/main.yml deleted file mode 100644 index a03788ae..00000000 --- a/roles/mgrote.pbs_users/tasks/main.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- - - name: check which users exist - become: yes - ansible.builtin.command: "proxmox-backup-manager user list --output-format json" - register: users - changed_when: false - - - name: ensure users exist - become: yes - ansible.builtin.command: "proxmox-backup-manager user create {{ item.name }}@{{ item.realm }}" - loop: "{{ pbs_users }}" - when: "item.name not in users.stdout" - - - name: check again which users exist - become: yes - ansible.builtin.command: "proxmox-backup-manager user list --output-format json" - register: users - changed_when: false - - - name: ensure user password - become: yes - ansible.builtin.command: "proxmox-backup-manager user update {{ item.name }}@{{ item.realm }} --password {{ item.password }} --expire 0" - loop: "{{ pbs_users }}" - when: "item.name in users.stdout" - changed_when: false - no_log: true diff --git a/roles/mgrote.polybar/defaults/main.yml b/roles/mgrote.polybar/defaults/main.yml deleted file mode 100644 index 7c48ef1b..00000000 --- a/roles/mgrote.polybar/defaults/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - polybar_siji_repo: https://github.com/stark/siji - polybar_siji_local: /home/mg/siji - polybar_siji_fonts_dir: /home/mg/.fonts diff --git a/roles/mgrote.polybar/tasks/main.yml b/roles/mgrote.polybar/tasks/main.yml deleted file mode 100644 index abeb740a..00000000 --- a/roles/mgrote.polybar/tasks/main.yml +++ /dev/null @@ -1,47 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - polybar - - lm-sensors - - brightnessctl - - inotify-tools - - yad # polybar popup-calendar - - xdotool # polybar popup-calendar - - wmctrl # für polybar windows-list # https://github.com/aroma1994/polybar-windows - state: present - - - name: checkout siji font - become: true - ansible.builtin.git: - repo: "{{ polybar_siji_repo }}" - dest: "{{ polybar_siji_local }}" - register: gitcheckout - - - name: create siji dir - become: true - ansible.builtin.file: - path: - - "{{ polybar_siji_fonts_dir }}" - state: directory - - - name: install siji-font - become: true - ansible.builtin.shell: "{{ polybar_siji_local }}/install.sh -d {{ polybar_siji_fonts_dir }}" - args: - chdir: "{{ polybar_siji_local }}" - creates: /home/mg/.fonts - when: gitcheckout.changed - - - name: remove bitmap-file - become: true - ansible.builtin.file: - path: /etc/fonts/conf.d/70-no-bitmaps.conf - state: absent - when: gitcheckout.changed - - - name: update fc-cache - become: true - ansible.builtin.shell: fc-cache - when: gitcheckout.changed diff --git a/roles/mgrote.postfix/defaults/main.yml b/roles/mgrote.postfix/defaults/main.yml deleted file mode 100644 index 01f79efd..00000000 --- a/roles/mgrote.postfix/defaults/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- - postfix_mail_nach_cronjob: false - postfix_erlaubte_netzwerke: "127.0.0.0/8 192.168.2.0/24" - postfix_smtp_server: smtp.strato.de - postfix_smtp_server_port: 587 - postfix_absender_mailadresse: info@mgrote.net - postfix_absender_passwort: "{{ lookup('keepass', 'postfix_absender_passwort', 'password') }}" - postfix_smtp_use_tls: "yes" - postfix_smtp_sasl_auth_enable: "yes" - postfix_smtp_tls_session_cache_timeout: 3600s - postfix_inet_protocols: ipv4 - postfix_append_dot_mydomain: "no" diff --git a/roles/mgrote.postfix/handlers/main.yml b/roles/mgrote.postfix/handlers/main.yml deleted file mode 100644 index 486e53a6..00000000 --- a/roles/mgrote.postfix/handlers/main.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: hash_sasl_passwd - become: yes - command: /usr/sbin/postmap hash:/etc/postfix/sasl_passwd - - - name: hash_sender_canonical - become: yes - command: /usr/sbin/postmap hash:/etc/postfix/sender_canonical - - - name: postfix_reload - become: yes - systemd: - name: postfix - enabled: yes - state: restarted - notify: postfix_testmail - - - name: postfix_testmail - shell: echo "postfix ist eingerichtet" | mail -s "{{ ansible_hostname }} - postfix" {{ empfaenger_mail }} diff --git a/roles/mgrote.postfix/tasks/main.yml b/roles/mgrote.postfix/tasks/main.yml deleted file mode 100644 index 2c88cabc..00000000 --- a/roles/mgrote.postfix/tasks/main.yml +++ /dev/null @@ -1,57 +0,0 @@ ---- - ### postfix fuer gmail; http://dokuwiki2.grote.lan/artikel/technik/postfix_mit_gmail_fuer_benachrichtigungen_einrichten - - name: postfix + Hilfsprogramme installieren - become: yes - ansible.builtin.package: - name: - - postfix - - mailutils - - libsasl2-modules - state: present - - - name: kopiere sasl_passwd - become: yes - ansible.builtin.template: - src: sasl_passwd - dest: /etc/postfix/sasl_passwd - force: yes - notify: - - hash_sasl_passwd - - postfix_testmail - - - name: kopiere sender_canonical - become: yes - ansible.builtin.template: - src: sender_canonical - dest: /etc/postfix/sender_canonical - notify: - - hash_sender_canonical - - postfix_reload - - postfix_testmail - - - name: kopiere postfix_main.cf - become: yes - ansible.builtin.template: - src: main.cf - dest: /etc/postfix/main.cf - notify: - - postfix_reload - - postfix_testmail - - - name: Mail Cronjob - Anlegen - become: yes - when: postfix_mail_nach_cronjob # ohne parameter wird auf true geprueft https://www.buildahomelab.com/2018/11/12/using-ansible-when-statements/ - ansible.builtin.cron: - name: MAILTO - env: yes - job: "{{ empfaenger_mail }}" - notify: - - postfix_testmail - - - name: Mail Cronjob - Entfernen - become: yes - when: not postfix_mail_nach_cronjob - ansible.builtin.cron: - name: MAILTO - env: yes - job: "" diff --git a/roles/mgrote.proxmox_bind_mounts/defaults/main.yml b/roles/mgrote.proxmox_bind_mounts/defaults/main.yml deleted file mode 100644 index 8550860a..00000000 --- a/roles/mgrote.proxmox_bind_mounts/defaults/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - lists_merged: # Liste muss leer existieren damit sie "germerged" werden kann, für Liste welche VMs zu rebooten sind - - '' diff --git a/roles/mgrote.proxmox_bind_mounts/handlers/main.yml b/roles/mgrote.proxmox_bind_mounts/handlers/main.yml deleted file mode 100644 index f2cac94a..00000000 --- a/roles/mgrote.proxmox_bind_mounts/handlers/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - - name: restart lxc - become: true - command: "pct reboot {{ item }}" - failed_when: false - loop: "{{ lists_merged | unique }}" - # reboote den lxc wenn: - # - er in der Liste "Lists merged" vorhanden ist - # unique Filter sorgt dafür das es keine doppelten Elemente gibt - # https://docs.ansible.com/ansible/latest/user_guide/playbooks_filters.html#set-theory-filters - # https://www.reddit.com/r/ansible/comments/8cp86c/how_do_i_remove_duplicate_items_from_a_variable/ diff --git a/roles/mgrote.proxmox_bind_mounts/tasks/bm.yml b/roles/mgrote.proxmox_bind_mounts/tasks/bm.yml deleted file mode 100644 index 8fb403bb..00000000 --- a/roles/mgrote.proxmox_bind_mounts/tasks/bm.yml +++ /dev/null @@ -1,46 +0,0 @@ ---- - - name: read config - become: true - shell: "pct config {{ item.vmid }} | grep \"mp{{ item.mp_nr }}: {{ item.mp_path_host }},mp={{ item.mp_path_guest }}\"" - register: config - changed_when: false - failed_when: false - # prüfe ob bind mount schon vorhanden ist - # exit-code wird unten geprüft - -# - name: debug config -# ansible.builtin.debug: -# msg: "{{ config }}" - - - name: add bind mounts to container - become: true - command: "pct set {{ item.vmid }} -mp{{ item.mp_nr }} {{ item.mp_path_host }},mp={{ item.mp_path_guest }}" - register: restart - notify: restart lxc - # füge bind-mount hinzu falls er fehlt, also rc ungleich 0 - # pro bind-mount - when: - - not ansible_check_mode - - not config.rc == 0 - # überspringe wenn in check-mode - - # schreibe vm id in die Liste "reboot" - - name: set reboot list - set_fact: - reboot: - - "{{ item.vmid }}" - when: restart.changed - - # Füge die leere Liste "lists_merged" aus den defaults, mit der Liste "reboot" zusammen. Nur wenn auch etwas geändert wurde, daher "when:..." - - name: merge reboot lists - set_fact: - lists_merged: "{{ lists_merged + reboot }}" - when: restart.changed - # https://blog.crisp.se/2016/10/20/maxwenzin/how-to-append-to-lists-in-ansible - -# - name: debug config -# ansible.builtin.debug: -# msg: "{{ lists_merged | unique }}" - # unique Filter sorgt dafür das es keine doppelten Elemente gibt - # https://docs.ansible.com/ansible/latest/user_guide/playbooks_filters.html#set-theory-filters - # https://www.reddit.com/r/ansible/comments/8cp86c/how_do_i_remove_duplicate_items_from_a_variable/ diff --git a/roles/mgrote.proxmox_bind_mounts/tasks/main.yml b/roles/mgrote.proxmox_bind_mounts/tasks/main.yml deleted file mode 100644 index f2fff3f9..00000000 --- a/roles/mgrote.proxmox_bind_mounts/tasks/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: loop tasks - include_tasks: bm.yml - loop: "{{ pve_bind_mounts }}" - when: - - pve_bind_mounts is defined - # Loope durch jeden bind-mount diff --git a/roles/mgrote.proxmox_lxc_profiles/defaults/main.yml b/roles/mgrote.proxmox_lxc_profiles/defaults/main.yml deleted file mode 100644 index 60238daa..00000000 --- a/roles/mgrote.proxmox_lxc_profiles/defaults/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - lists_merged: # Liste muss leer existieren damit sie "germerged" werden kann, für Liste welche VMs zu rebooten sind - - '' - -# lxc_apparmor_profiles: -# - vmid: 555 -# apparmor_profile: unconfined diff --git a/roles/mgrote.proxmox_lxc_profiles/handlers/main.yml b/roles/mgrote.proxmox_lxc_profiles/handlers/main.yml deleted file mode 100644 index f2cac94a..00000000 --- a/roles/mgrote.proxmox_lxc_profiles/handlers/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - - name: restart lxc - become: true - command: "pct reboot {{ item }}" - failed_when: false - loop: "{{ lists_merged | unique }}" - # reboote den lxc wenn: - # - er in der Liste "Lists merged" vorhanden ist - # unique Filter sorgt dafür das es keine doppelten Elemente gibt - # https://docs.ansible.com/ansible/latest/user_guide/playbooks_filters.html#set-theory-filters - # https://www.reddit.com/r/ansible/comments/8cp86c/how_do_i_remove_duplicate_items_from_a_variable/ diff --git a/roles/mgrote.proxmox_lxc_profiles/tasks/main.yml b/roles/mgrote.proxmox_lxc_profiles/tasks/main.yml deleted file mode 100644 index af009edb..00000000 --- a/roles/mgrote.proxmox_lxc_profiles/tasks/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: loop tasks - include_tasks: profile.yml - loop: "{{ lxc_apparmor_profiles }}" - when: - - lxc_apparmor_profiles is defined - # Loope durch jeden bind-mount diff --git a/roles/mgrote.proxmox_lxc_profiles/tasks/profile.yml b/roles/mgrote.proxmox_lxc_profiles/tasks/profile.yml deleted file mode 100644 index b2362a34..00000000 --- a/roles/mgrote.proxmox_lxc_profiles/tasks/profile.yml +++ /dev/null @@ -1,24 +0,0 @@ ---- - - name: set apparmor profile - become: true - ansible.builtin.lineinfile: - path: "/etc/pve/lxc/{{ item.vmid }}.conf" - line: "lxc.apparmor.profile: {{ item.apparmor_profile }}" - state: present - register: restart - - # schreibe vm id in die Liste "reboot" - - name: set reboot list - become: true - set_fact: - reboot: - - "{{ item.vmid }}" - when: restart.changed - - # Füge die leere Liste "lists_merged" aus den defaults, mit der Liste "reboot" zusammen. Nur wenn auch etwas geändert wurde, daher "when:..." - - name: merge reboot lists - become: true - set_fact: - lists_merged: "{{ lists_merged + reboot }}" - when: restart.changed - # https://blog.crisp.se/2016/10/20/maxwenzin/how-to-append-to-lists-in-ansible diff --git a/roles/mgrote.qemu_guest_agent/handlers/main.yml b/roles/mgrote.qemu_guest_agent/handlers/main.yml deleted file mode 100644 index 1ac62ba0..00000000 --- a/roles/mgrote.qemu_guest_agent/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: reboot - become: true - reboot: - reboot_timeout: 120 diff --git a/roles/mgrote.qemu_guest_agent/tasks/main.yml b/roles/mgrote.qemu_guest_agent/tasks/main.yml deleted file mode 100644 index d5d9f2c2..00000000 --- a/roles/mgrote.qemu_guest_agent/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- - - name: update apt cache - become: yes - ansible.builtin.apt: - update_cache: yes - - - name: install packages - become: yes - ansible.builtin.package: - name: qemu-guest-agent - state: present - when: ansible_virtualization_role == 'guest' - notify: reboot diff --git a/roles/mgrote.r8152_kernel_module/LICENSE b/roles/mgrote.r8152_kernel_module/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.r8152_kernel_module/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.r8152_kernel_module/defaults/main.yml b/roles/mgrote.r8152_kernel_module/defaults/main.yml deleted file mode 100644 index 611fcbfd..00000000 --- a/roles/mgrote.r8152_kernel_module/defaults/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- - r8152_module_needed: false # standardmäßig falsch - r8152_packages: - - pve-headers - - build-essential - - make - - dkms - r8152_safekeeping_reboot_delay: 12 # nach wieviel minuten wird der pc neugestartet, tasks wird am ende gelöscht wenn alles erfolgreich war - # damit ist sichergestellt das der pc wieder hochfährt falls etwas passiert - r8152_src_dir: /usr/src/r8125-9.004.01 # wo wird das entpackte archiv abgelegt - r8152_filename: r8125-dkms_9.004.01.tar.gz # wie ist der dateiname auf dem ansible controller - r8152_version: 9.004.01 # wie lautet die versuin diff --git a/roles/mgrote.r8152_kernel_module/meta/main.yml b/roles/mgrote.r8152_kernel_module/meta/main.yml deleted file mode 100644 index b4b6cedb..00000000 --- a/roles/mgrote.r8152_kernel_module/meta/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - collections: - - community.general diff --git a/roles/mgrote.r8152_kernel_module/tasks/assert.yml b/roles/mgrote.r8152_kernel_module/tasks/assert.yml deleted file mode 100644 index 894272c4..00000000 --- a/roles/mgrote.r8152_kernel_module/tasks/assert.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- - - name: check if module is installed - folder - become: yes - stat: - path: "/lib/modules/r8152" - register: folder_exists - - - name: check if module is installed - lsmod - become: yes - ansible.builtin.shell: lsmod - register: module_in_lsmod - changed_when: False # sorgt dafür das der Task nie als "changed" angezeigt wird - - - name: include install-tasks - include_tasks: doing.yml - when: (module_in_lsmod.stdout.find('r8152') == -1) and (folder_exists.stat.exists == false) - - - name: include dkms-tasks - include_tasks: dkms.yml - when: (module_in_lsmod.stdout.find('r8152') == -1) and (folder_exists.stat.exists == false) diff --git a/roles/mgrote.r8152_kernel_module/tasks/dkms.yml b/roles/mgrote.r8152_kernel_module/tasks/dkms.yml deleted file mode 100644 index 3ccd9110..00000000 --- a/roles/mgrote.r8152_kernel_module/tasks/dkms.yml +++ /dev/null @@ -1,34 +0,0 @@ ---- - - name: dkms add - become: yes - ansible.builtin.shell: dkms add -m r8125 -v "{{ r8152_version }}" - args: - chdir: "{{ r8152_src_dir }}" - - - name: dkms build - become: yes - ansible.builtin.shell: dkms build -m r8125 -v "{{ r8152_version }}" - args: - chdir: "{{ r8152_src_dir }}" - - - name: dkms install - become: yes - ansible.builtin.shell: dkms install -m r8125 -v "{{ r8152_version }}" - args: - chdir: "{{ r8152_src_dir }}" - - - name: depmod -a - become: yes - ansible.builtin.shell: depmod -a - args: - chdir: "{{ r8152_src_dir }}" - - - name: update initramfs - become: yes - ansible.builtin.shell: update-initramfs -u - args: - chdir: "{{ r8152_src_dir }}" - - - name: reboot - ansible.builtin.reboot: - reboot_timeout: 120 diff --git a/roles/mgrote.r8152_kernel_module/tasks/doing.yml b/roles/mgrote.r8152_kernel_module/tasks/doing.yml deleted file mode 100644 index 6bc7d012..00000000 --- a/roles/mgrote.r8152_kernel_module/tasks/doing.yml +++ /dev/null @@ -1,36 +0,0 @@ ---- - - name: install needed packages - become: yes - ansible.builtin.package: - name: "{{ r8152_packages }}" - state: present - - - name: add reboot(for safekeeping) - become: yes - ansible.builtin.shell: shutdown -r "{{ r8152_safekeeping_reboot_delay }}" - - - name: update apt cache - become: yes - ansible.builtin.apt: - update_cache: yes - - - name: updated installed packages - become: yes - ansible.builtin.package: - upgrade: dist - - - name: create dirs - ansible.builtin.file: - path: "{{ item }}" - state: directory - loop: - - "{{ r8152_src_dir }}" - - - name: copy and extract archive - become: yes - ansible.builtin.unarchive: - src: "{{ r8152_filename }}" - dest: "{{ r8152_src_dir }}" - mode: a+x - extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives - remote_src: no #datei liegt also auf dem ansible-controller diff --git a/roles/mgrote.r8152_kernel_module/tasks/main.yml b/roles/mgrote.r8152_kernel_module/tasks/main.yml deleted file mode 100644 index 70c62e60..00000000 --- a/roles/mgrote.r8152_kernel_module/tasks/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - - name: include assert-tasks - include_tasks: assert.yml - when: r8152_module_needed == true diff --git a/roles/mgrote.r8152_kernel_module_on_off/LICENSE b/roles/mgrote.r8152_kernel_module_on_off/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.r8152_kernel_module_on_off/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.r8152_kernel_module_on_off/defaults/main.yml b/roles/mgrote.r8152_kernel_module_on_off/defaults/main.yml deleted file mode 100644 index d4f0dee8..00000000 --- a/roles/mgrote.r8152_kernel_module_on_off/defaults/main.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - r8152_filename: r8152.53.56-2.15.0 - r8152_packages: - - pve-headers - - build-essential - - make - r8152_reboot_timeout: 90 - r8152_pre_reboot_delay: 120 - r8152_post_reboot_delay: 60 - r8152_module_needed: false - r8152_safekeeping_reboot_delay: 12 diff --git a/roles/mgrote.r8152_kernel_module_on_off/meta/main.yml b/roles/mgrote.r8152_kernel_module_on_off/meta/main.yml deleted file mode 100644 index b4b6cedb..00000000 --- a/roles/mgrote.r8152_kernel_module_on_off/meta/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - collections: - - community.general diff --git a/roles/mgrote.r8152_kernel_module_on_off/tasks/doing.yml b/roles/mgrote.r8152_kernel_module_on_off/tasks/doing.yml deleted file mode 100644 index 640f7baf..00000000 --- a/roles/mgrote.r8152_kernel_module_on_off/tasks/doing.yml +++ /dev/null @@ -1,83 +0,0 @@ ---- - - name: install needed packages - become: yes - ansible.builtin.package: - name: "{{ r8152_packages }}" - state: present - register: aptp - - - - name: add reboot(for safekeeping) - become: yes - ansible.builtin.shell: shutdown -r "{{ r8152_safekeeping_reboot_delay }}" - - - name: update apt cache - become: yes - ansible.builtin.apt: - update_cache: yes - register: aptc - - - name: updated installed packages - become: yes - ansible.builtin.package: - upgrade: dist - register: apti - - - name: reboot - 1 - ansible.builtin.reboot: - reboot_timeout: "{{ r8152_reboot_timeout }}" - pre_reboot_delay: "{{ r8152_reboot_timeout }}" - post_reboot_delay: "{{ r8152_post_reboot_delay }}" - when: - - aptp.changed - - apti.changed - - aptc.changed - - - name: create dirs - ansible.builtin.file: - path: "{{ item }}" - state: directory - loop: - - "/tmp/r8152/" - - "/lib/modules/r8152/{{ r8152_filename }}" - - - name: copy archive - become: yes - ansible.builtin.copy: - src: "files/{{ r8152_filename }}.tar.bz2" - dest: "/tmp/r8152/{{ r8152_filename }}.tar.bz2" - mode: '0775' - - - name: extract archive - become: yes - ansible.builtin.unarchive: - src: "/tmp/r8152/{{ r8152_filename }}.tar.bz2" - dest: "/lib/modules/r8152/{{ r8152_filename }}" - mode: a+x - extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives - remote_src: yes #datei liegt also auf dem zielsystem - - - name: make - community.general.make: - chdir: "/lib/modules/r8152/{{ r8152_filename }}" - become: yes - - - name: make install - community.general.make: - chdir: "/lib/modules/r8152/{{ r8152_filename }}" - target: install - become: yes - - - name: depmod -a - become: yes - ansible.builtin.shell: depmod -a - - - name: reboot - 2 - ansible.builtin.reboot: - reboot_timeout: "{{ r8152_reboot_timeout }}" - pre_reboot_delay: "{{ r8152_reboot_timeout }}" - post_reboot_delay: "{{ r8152_post_reboot_delay }}" - - - name: cancel reboot(for safekeeping) - become: yes - ansible.builtin.shell: shutdown -c diff --git a/roles/mgrote.r8152_kernel_module_on_off/tasks/main.yml b/roles/mgrote.r8152_kernel_module_on_off/tasks/main.yml deleted file mode 100644 index b2a23c31..00000000 --- a/roles/mgrote.r8152_kernel_module_on_off/tasks/main.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- - - name: check if module is installed - folder - become: yes - stat: - path: "/lib/modules/r8152/{{ r8152_filename }}" - register: folder_exists - - - name: check if module is installed - lsmod - become: yes - ansible.builtin.shell: lsmod - register: module_in_lsmod - changed_when: False # sorgt dafür das der Task nie als "changed" angezeigt wird - - - name: include tasks (task get skipped if the folder or the module exists or r8152_module_needed == false) - include_tasks: doing.yml - when: ((folder_exists.stat.exists == False) or (module_in_lsmod.stdout.find('r8152') == -1)) and (r8152_module_needed == true) diff --git a/roles/mgrote.rclone/LICENSE b/roles/mgrote.rclone/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.rclone/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.rclone/README.md b/roles/mgrote.rclone/README.md deleted file mode 100644 index 9e750969..00000000 --- a/roles/mgrote.rclone/README.md +++ /dev/null @@ -1,14 +0,0 @@ -## mgrote.rclone - -### Beschreibung -Installiert und konfiguriert rclone zur Datensicherung. - -### getestet auf -- [x] Ubuntu 20.04 (LXC) - -### Variablen + Defaults -- see [defaults](./defaults/main.yml) - -## Altes rclone Repository - -https://git.mgrote.net/mg/rclone diff --git a/roles/mgrote.rclone/defaults/main.yml b/roles/mgrote.rclone/defaults/main.yml deleted file mode 100644 index f5a7abdc..00000000 --- a/roles/mgrote.rclone/defaults/main.yml +++ /dev/null @@ -1,17 +0,0 @@ ---- - -# rclone_config: "{{ lookup('keepass', 'rclone.conf', 'notes') }}" # rclone Config, use as Block - -# ### mgote.rclone -# rclone_jobs: # Array of Jobs -# - name: smb_musik_glacier # Jobname -# quelle: "/shares_music" # Source -# ziel: "scaleway-encrypt-glacier:/musik" # Destination -# timer: "*-*-* 23:15" # Timer -# loglevel: DEBUG # Optional: Loglevel -# state: true # true = present // false = remove -# bwlimit: 2M # Optional: Bandwidthlimit -# mode: "--size-only" # Optional: mode (https://rclone.org/s3/) -# transfers # Optional: Transfers -# checkers # Optional: Checkers -# retries # Optional: Retries diff --git a/roles/mgrote.rclone/handlers/main.yml b/roles/mgrote.rclone/handlers/main.yml deleted file mode 100644 index c73886d6..00000000 --- a/roles/mgrote.rclone/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes diff --git a/roles/mgrote.rclone/tasks/main.yml b/roles/mgrote.rclone/tasks/main.yml deleted file mode 100644 index 94f69a38..00000000 --- a/roles/mgrote.rclone/tasks/main.yml +++ /dev/null @@ -1,105 +0,0 @@ ---- - - name: Check if rclone is installed - command: which rclone - changed_when: false - failed_when: rclone_installed.rc not in [0,1] - register: rclone_installed - - - name: Install rclone first! - fail: - msg: "rclone is not installed, install it first" - when: rclone_installed.rc not in [ 0 ] - - - name: Create rclone Directory - become: true - ansible.builtin.file: - path: "/etc/rclone" - state: directory - owner: root - group: root - recurse: true - - - name: template rclone Configuration - become: true - ansible.builtin.blockinfile: - path: "/etc/rclone/rclone.conf" - block: "{{ rclone_config }}" - create: yes - owner: root - group: root - when: rclone_config is defined - no_log: true - - - name: template rclone services - become: yes - ansible.builtin.template: - src: "rclone.service.j2" - dest: "/etc/systemd/system/rclone_{{ item.name }}.service" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - with_items: - - "{{ rclone_jobs }}" - when: rclone_jobs is defined and item.state is true - - - name: template rclone timer - become: yes - ansible.builtin.template: - src: "rclone.timer.j2" - dest: "/etc/systemd/system/rclone_{{ item.name }}.timer" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - with_items: - - "{{ rclone_jobs }}" - when: rclone_jobs is defined and item.state is true - - - name: remove old rclone services - become: yes - ansible.builtin.file: - path: "/etc/systemd/system/rclone_{{ item.name }}.service" - state: absent - notify: - - systemctl daemon-reload - with_items: - - "{{ rclone_jobs }}" - when: rclone_jobs is defined and item.state is false - - - name: remove old rclone timers - become: yes - ansible.builtin.file: - path: "/etc/systemd/system/rclone_{{ item.name }}.timer" - state: absent - notify: - - systemctl daemon-reload - with_items: - - "{{ rclone_jobs }}" - when: rclone_jobs is defined and item.state is false - - - name: template rclone_mail@.service.j2 - become: yes - ansible.builtin.template: - src: "rclone_mail@.service.j2" - dest: "/etc/systemd/system/rclone_mail@.service" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: systemctl enable timer units - become: yes - ansible.builtin.systemd: - name: "rclone_{{ item.name }}.timer" - enabled: yes - masked: no - state: started - with_items: - - "{{ rclone_jobs }}" - when: rclone_jobs is defined and item.state is true - notify: - - systemctl daemon-reload diff --git a/roles/mgrote.rclone/templates/rclone.service.j2 b/roles/mgrote.rclone/templates/rclone.service.j2 deleted file mode 100644 index 557438a9..00000000 --- a/roles/mgrote.rclone/templates/rclone.service.j2 +++ /dev/null @@ -1,10 +0,0 @@ -{{ file_header | default () }} - -[Unit] -Description=Sync data with rclone. -OnFailure=rclone_mail@{{ item.name }}.service - - -[Service] -Type=simple -ExecStart=/usr/bin/rclone --config "/etc/rclone/rclone.conf" sync --log-level {{ item.loglevel | default ("INFO") }} --stats=5m --transfers {{ item.transfers | default ("8") }} --checkers {{ item.checkers | default ("8") }} --retries {{ item.retries | default ("5") }} --bwlimit {{ item.bwlimit | default ("0") }} {% if item.mode is defined %}{{ item.mode }}{% endif %} --delete-after "{{ item.quelle }}" "{{item.ziel }}" diff --git a/roles/mgrote.rclone/templates/rclone.timer.j2 b/roles/mgrote.rclone/templates/rclone.timer.j2 deleted file mode 100644 index fa2ba12a..00000000 --- a/roles/mgrote.rclone/templates/rclone.timer.j2 +++ /dev/null @@ -1,10 +0,0 @@ -{{ file_header | default () }} -[Unit] -Description=Timer for rclone syncs. - -[Timer] -OnCalendar={{ item.timer }} -RandomizedDelaySec=30 min - -[Install] -WantedBy=timers.target multi-user.target diff --git a/roles/mgrote.rclone/templates/rclone_mail@.service.j2 b/roles/mgrote.rclone/templates/rclone_mail@.service.j2 deleted file mode 100644 index c68413cf..00000000 --- a/roles/mgrote.rclone/templates/rclone_mail@.service.j2 +++ /dev/null @@ -1,8 +0,0 @@ -{{ file_header | default () }} - -[Unit] -Description=Send a Mail in case of an error in sanoid.service. - -[Service] -Type=oneshot -ExecStart=/bin/bash -c '/bin/systemctl status rclone_%i.service | mail -s "[ERROR] rclone - %i" {{ empfaenger_mail }}' diff --git a/roles/mgrote.remove_snapd/LICENSE b/roles/mgrote.remove_snapd/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.remove_snapd/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.remove_snapd/tasks/main.yml b/roles/mgrote.remove_snapd/tasks/main.yml deleted file mode 100644 index 48b6f938..00000000 --- a/roles/mgrote.remove_snapd/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- - - name: remove snapd package - become: yes - ansible.builtin.package: - name: snapd - state: absent - purge: yes - - - name: remove /var/cache/snapd/ - become: true - ansible.builtin.file: - path: /var/cache/snapd/ - state: absent diff --git a/roles/mgrote.restic/LICENSE b/roles/mgrote.restic/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.restic/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.restic/defaults/main.yml b/roles/mgrote.restic/defaults/main.yml deleted file mode 100644 index f8032ac0..00000000 --- a/roles/mgrote.restic/defaults/main.yml +++ /dev/null @@ -1,33 +0,0 @@ ---- - # restic user - restic_user: root - # restic group - restic_group: restic - # restic config directory - restic_conf_dir: /etc/restic - # was soll ausgeschlossen werden, siehe: https://github.com/restic/restic/issues/1005; https://forum.restic.net/t/exclude-syntax-confusion/1531/12 - restic_exclude: | - ._* - desktop.ini - .Trash-* - **/**cache***/** - **/**Cache***/** - **/**AppData***/** - # timeout for cifs mount; systemd notation(systemd-analyze calendar "Sun *-0/2-* 23:00") - restic_mount_timeout: "10 min" - # delay for restartung task; systemd notation(systemd-analyze calendar "Sun *-0/2-* 23:00") - restic_failure_delay: "30 s" - # when should restic run; systemd notation(systemd-analyze calendar "Sun *-0/2-* 23:00") - restic_schedule: "*:0/2" - # welche ordner sollen gesichert werden - restic_folders_to_backup: "/usr/local /etc /root /var/www /home" - # smb-share mit dem repository: z.B. "//fileserver3.grote.lan/restic" - restic_repository: "//fileserver.domain/restic" - # password für das repo - restic_repository_password: "{{ lookup('keepass', 'restic_repository_password', 'password') }}" - # nutzer für den share - restic_mount_user: restic - # passwort für den mount - restic_mount_password: "unsafe_password" - # where to send in case of an error - restic_fail_mail: x@y.de diff --git a/roles/mgrote.restic/handlers/main.yml b/roles/mgrote.restic/handlers/main.yml deleted file mode 100644 index dc2263e5..00000000 --- a/roles/mgrote.restic/handlers/main.yml +++ /dev/null @@ -1,28 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes - - - name: systemctl enable units - become: yes - ansible.builtin.systemd: - name: "{{ item }}" - enabled: yes - masked: no - with_items: - - media-restic.automount - - media-restic.mount - - restic.service - - restic.timer - - restic_mail.service - - - name: systemctl start units - become: yes - ansible.builtin.systemd: - name: "{{ item }}" - state: restarted - enabled: yes - with_items: - - restic.timer - notify: systemctl daemon-reload diff --git a/roles/mgrote.restic/tasks/main.yml b/roles/mgrote.restic/tasks/main.yml deleted file mode 100644 index b1ba785a..00000000 --- a/roles/mgrote.restic/tasks/main.yml +++ /dev/null @@ -1,117 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ restic_group }}" - state: present - - - name: install restic-packages - become: yes - ansible.builtin.package: - name: - - restic - state: present - - - name: create "{{ restic_conf_dir }}" - become: yes - ansible.builtin.file: - path: "{{ restic_conf_dir }}" - state: directory - owner: "{{ restic_user }}" - group: "{{ restic_group }}" - mode: 0755 - - - name: template smb.cred - become: yes - ansible.builtin.template: - src: "smb.cred.j2" - dest: "{{ restic_conf_dir }}/smb.cred" - owner: "{{ restic_user }}" - group: "{{ restic_group }}" - mode: 0600 - no_log: true - - - name: templates excludes - become: yes - ansible.builtin.blockinfile: - path: "{{ restic_conf_dir }}/excludes" - create: yes - block: "{{ restic_exclude }}" - mode: 0644 - owner: "{{ restic_user }}" - group: "{{ restic_group }}" - - - name: template restic.env - become: yes - ansible.builtin.template: - src: "restic.env.j2" - dest: "{{ restic_conf_dir }}/restic.env" - owner: root - group: root - mode: 0600 - no_log: true - - - name: template restic.mount - become: yes - ansible.builtin.template: - src: media-restic.mount.j2 - dest: /etc/systemd/system/media-restic.mount # media-restic == /media/restic - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - systemctl enable units - - - name: template restic.automount - become: yes - ansible.builtin.template: - src: media-restic.automount.j2 - dest: /etc/systemd/system/media-restic.automount - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - systemctl enable units - - systemctl start units - - - name: template restic.service - become: yes - ansible.builtin.template: - src: restic.service.j2 - dest: /etc/systemd/system/restic.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: template restic.timer - become: yes - ansible.builtin.template: - src: restic.timer.j2 - dest: /etc/systemd/system/restic.timer - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: template restic_mail.service - become: yes - ansible.builtin.template: - src: "restic_mail.service.j2" - dest: /etc/systemd/system/restic_mail.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: systemctl start restic.timer - become: yes - ansible.builtin.systemd: - name: restic.timer - state: started - enabled: yes diff --git a/roles/mgrote.sealed-secrets/LICENSE b/roles/mgrote.sealed-secrets/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.sealed-secrets/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.sealed-secrets/defaults/main.yml b/roles/mgrote.sealed-secrets/defaults/main.yml deleted file mode 100644 index 744d7859..00000000 --- a/roles/mgrote.sealed-secrets/defaults/main.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- - sealed_secrets_homedir: /home/sealed_secrets - sealed_secrets_user_group: sealed_secrets - sealed_secrets_user: sealed_secrets - kubeseal_download_url: "https://github.com/bitnami-labs/sealed-secrets/releases/download/v0.19.1/kubeseal-0.19.1-linux-amd64.tar.gz" - kubeseal_path_bin: /usr/local/sbin - kubeconfig: /etc/rancher/k3s/k3s.yaml - sealed_secrets_keepass_entry_name: "{{ lookup('keepass', 'k3s-sealed-secrets-private-key', 'notes') }}" # mit kubectl get secret -n kube-system -l sealedsecrets.bitnami.com/sealed-secrets-key -o yaml >main.key holen diff --git a/roles/mgrote.sealed-secrets/tasks/import.yml b/roles/mgrote.sealed-secrets/tasks/import.yml deleted file mode 100644 index b4bffc93..00000000 --- a/roles/mgrote.sealed-secrets/tasks/import.yml +++ /dev/null @@ -1,29 +0,0 @@ ---- - - name: check if private key exists - ansible.builtin.command: kubectl get secrets sealed-secrets-keytsq4k -n kube-system - register: key - ignore_errors: yes - changed_when: false - - - name: Template private key file - ansible.builtin.template: - src: private.key.j2 - dest: /root/private.key - owner: root - group: root - mode: '0400' - when: key.rc not in [ 0 ] - #no_log: True - - - name: apply private key - ansible.builtin.command: kubectl apply -f /root/private.key - when: key.rc not in [ 0 ] - - - name: remove old pod - ansible.builtin.command: kubectl delete pod -n kube-system -l name=sealed-secrets-controller - when: key.rc not in [ 0 ] - - - name: remove private key file - ansible.builtin.file: - path: /root/private.key - state: absent diff --git a/roles/mgrote.sealed-secrets/tasks/main.yml b/roles/mgrote.sealed-secrets/tasks/main.yml deleted file mode 100644 index 247adfe9..00000000 --- a/roles/mgrote.sealed-secrets/tasks/main.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - name: check if kubeseal is installed - command: which kubeseal - changed_when: false - failed_when: kubeseal_installed.rc not in [0,1] - register: kubeseal_installed - - - name: download sealed_secrets binary - ansible.builtin.unarchive: - src: "{{ kubeseal_download_url }}" - dest: "{{ kubeseal_path_bin }}" - mode: 0755 - owner: "{{ sealed_secrets_user }}" - group: "{{ sealed_secrets_user_group }}" - remote_src: yes - creates: "{{ kubeseal_path_bin }}/kubeseal" - when: kubeseal_installed.rc not in [ 0 ] - - - name: include import tasks - include_tasks: import.yml - # der ganze block nur auf enem host - run_once: true - when: ansible_host == flux_install_host diff --git a/roles/mgrote.sealed-secrets/tasks/user.yml b/roles/mgrote.sealed-secrets/tasks/user.yml deleted file mode 100644 index 73a30083..00000000 --- a/roles/mgrote.sealed-secrets/tasks/user.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ sealed_secrets_user_group }}" - state: present - when: - - sealed_secrets_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ sealed_secrets_user }}" - group: "{{ sealed_secrets_user_group }}" - create_home: no - when: - - sealed_secrets_user_group is defined - - sealed_secrets_user is defined diff --git a/roles/mgrote.set_permissions/LICENSE b/roles/mgrote.set_permissions/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.set_permissions/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.smart/LICENSE b/roles/mgrote.smart/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.smart/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.smart/defaults/main.yml b/roles/mgrote.smart/defaults/main.yml deleted file mode 100644 index e9b13e4f..00000000 --- a/roles/mgrote.smart/defaults/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - # path to smartctl - smart_smartctl_path: "/usr/sbin/smartctl" - # under which user the script is run - smart_user_group: "root" - smart_user: "smart" diff --git a/roles/mgrote.smart/handlers/main.yml b/roles/mgrote.smart/handlers/main.yml deleted file mode 100644 index f868b805..00000000 --- a/roles/mgrote.smart/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart smartmontools - become: yes - systemd: - name: smartmontools - state: restarted - enabled: yes diff --git a/roles/mgrote.smart/meta/main.yml b/roles/mgrote.smart/meta/main.yml deleted file mode 100644 index f2c70d58..00000000 --- a/roles/mgrote.smart/meta/main.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- - dependencies: - - role: mgrote.postfix - galaxy_info: - author: mgrote - description: installs smartctl and configures it - min_ansible_version: 2.0 - license: GPLv3 - platforms: - - name: Ubuntu - versions: - - all - galaxy_tags: - - system diff --git a/roles/mgrote.smart/tasks/main.yml b/roles/mgrote.smart/tasks/main.yml deleted file mode 100644 index 485744d7..00000000 --- a/roles/mgrote.smart/tasks/main.yml +++ /dev/null @@ -1,27 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - name: ensure smartmontools are installed - become: yes - ansible.builtin.package: - name: smartmontools - state: present - - - name: template smartmontools config - become: yes - ansible.builtin.template: - src: "smartmontools" - dest: "/etc/default/smartmontools" - owner: "{{ smart_user }}" - group: "{{ smart_user_group }}" - notify: restart smartmontools - - - name: template smartd.conf - become: yes - ansible.builtin.template: - src: "smartd.conf" - dest: "/etc/smartd.conf" - owner: "{{ smart_user }}" - group: "{{ smart_user_group }}" - notify: restart smartmontools diff --git a/roles/mgrote.smart/tasks/user.yml b/roles/mgrote.smart/tasks/user.yml deleted file mode 100644 index 87a6f5a9..00000000 --- a/roles/mgrote.smart/tasks/user.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ smart_user_group }}" - state: present - when: - - smart_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ smart_user }}" - group: "{{ smart_user_group }}" - shell: /usr/sbin/nologin - create_home: no - when: - - smart_user_group is defined - - smart_user is defined diff --git a/roles/mgrote.ssh/LICENSE b/roles/mgrote.ssh/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.ssh/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.ssh/handlers/main.yml b/roles/mgrote.ssh/handlers/main.yml deleted file mode 100644 index aa01ea6d..00000000 --- a/roles/mgrote.ssh/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart sshd - become: yes - systemd: - name: sshd - enabled: yes - state: restarted diff --git a/roles/mgrote.ssh/tasks/main.yml b/roles/mgrote.ssh/tasks/main.yml deleted file mode 100644 index e21ad406..00000000 --- a/roles/mgrote.ssh/tasks/main.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- - - name: include ubuntu tasks (determined by "ansible_distribution") - include_tasks: ubuntu.yml - when: - - ansible_distribution == 'Ubuntu' - - - name: include proxmox tasks (determined by group) - include_tasks: pve.yml - when: - - "'proxmox' in group_names" diff --git a/roles/mgrote.ssh/tasks/pve.yml b/roles/mgrote.ssh/tasks/pve.yml deleted file mode 100644 index a049fd18..00000000 --- a/roles/mgrote.ssh/tasks/pve.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- - - name: source proxmox vars - include_vars: pve.yml - - - name: template sshd_config - become: true - ansible.builtin.template: - src: pve.j2 - dest: /etc/ssh/sshd_config - owner: root - group: root - mode: '0644' - validate: "/usr/sbin/sshd -T -f %s" - backup: true - notify: restart sshd diff --git a/roles/mgrote.ssh/tasks/ubuntu.yml b/roles/mgrote.ssh/tasks/ubuntu.yml deleted file mode 100644 index e3f19f97..00000000 --- a/roles/mgrote.ssh/tasks/ubuntu.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- - - name: source ubuntu vars - include_vars: ubuntu.yml - - - name: template sshd_config - become: true - ansible.builtin.template: - src: ubuntu.j2 - dest: /etc/ssh/sshd_config - owner: root - group: root - mode: '0644' - validate: "/usr/sbin/sshd -T -f %s" - backup: true - notify: restart sshd diff --git a/roles/mgrote.ssh/vars/pve.yml b/roles/mgrote.ssh/vars/pve.yml deleted file mode 100644 index 5a209de1..00000000 --- a/roles/mgrote.ssh/vars/pve.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - ssh_permit_root_login: "yes" - ssh_password_authentication: "yes" - ssh_print_motd: "no" - ssh_print_lastlog: "no" - ssh_listen_port: "22" diff --git a/roles/mgrote.ssh/vars/ubuntu.yml b/roles/mgrote.ssh/vars/ubuntu.yml deleted file mode 100644 index 3903358c..00000000 --- a/roles/mgrote.ssh/vars/ubuntu.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - ssh_permit_root_login: "no" - ssh_password_authentication: "no" - ssh_print_motd: "no" - ssh_print_lastlog: "no" - ssh_listen_port: "22" diff --git a/roles/mgrote.supermicro_fan_control/LICENSE b/roles/mgrote.supermicro_fan_control/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.supermicro_fan_control/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.supermicro_fan_control/handlers/main.yml b/roles/mgrote.supermicro_fan_control/handlers/main.yml deleted file mode 100644 index d3962c5e..00000000 --- a/roles/mgrote.supermicro_fan_control/handlers/main.yml +++ /dev/null @@ -1,25 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes - - - name: systemctl enable units - become: yes - ansible.builtin.systemd: - name: "{{ item }}" - enabled: yes - masked: no - with_items: - - sm_fan_control.service - - sm_fan_control.timer - - - name: systemctl start units - become: yes - ansible.builtin.systemd: - name: "{{ item }}" - state: restarted - enabled: yes - with_items: - - sm_fan_control.timer - notify: systemctl daemon-reload diff --git a/roles/mgrote.supermicro_fan_control/tasks/main.yml b/roles/mgrote.supermicro_fan_control/tasks/main.yml deleted file mode 100644 index 6bd1ff10..00000000 --- a/roles/mgrote.supermicro_fan_control/tasks/main.yml +++ /dev/null @@ -1,36 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - ipmitool - state: present - - - name: template sm_fan_control.service - become: yes - ansible.builtin.template: - src: sm_fan_control.service.j2 - dest: /etc/systemd/system/sm_fan_control.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: template sm_fan_control.timer - become: yes - ansible.builtin.template: - src: sm_fan_control.timer.j2 - dest: /etc/systemd/system/sm_fan_control.timer - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: systemctl start sm_fan_control.timer - become: yes - ansible.builtin.systemd: - name: sm_fan_control.timer - state: started - enabled: yes diff --git a/roles/mgrote.systemd-resolved/handlers/main.yml b/roles/mgrote.systemd-resolved/handlers/main.yml deleted file mode 100644 index f5ddad62..00000000 --- a/roles/mgrote.systemd-resolved/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: restart systemd-resolved - ansible.builtin.systemd: - state: restarted - name: systemd-resolved diff --git a/roles/mgrote.systemd-resolved/tasks/main.yml b/roles/mgrote.systemd-resolved/tasks/main.yml deleted file mode 100644 index 13d438fc..00000000 --- a/roles/mgrote.systemd-resolved/tasks/main.yml +++ /dev/null @@ -1,24 +0,0 @@ ---- - - name: Make sure systemd-resolved is running - ansible.builtin.systemd: - state: started - masked: false - name: systemd-resolved - - - name: template /etc/systemd/resolved.conf - ansible.builtin.template: - src: resolved.conf.j2 - dest: /etc/systemd/resolved.conf - owner: root - group: root - mode: '0644' - notify: restart systemd-resolved - - - name: template /etc/resolv.conf - ansible.builtin.template: - src: resolv.conf.j2 - dest: /etc/resolv.conf - owner: root - group: root - mode: '0644' - notify: restart systemd-resolved diff --git a/roles/mgrote.systemd-timesyncd/LICENSE b/roles/mgrote.systemd-timesyncd/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.systemd-timesyncd/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.systemd-timesyncd/defaults/main.yml b/roles/mgrote.systemd-timesyncd/defaults/main.yml deleted file mode 100644 index fd42b51a..00000000 --- a/roles/mgrote.systemd-timesyncd/defaults/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - ntp_timesyncd_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet - ntp_timesyncd_servers: # welche Server sollen befragt werden - - ptbtime1.ptb.de diff --git a/roles/mgrote.systemd-timesyncd/handlers/main.yml b/roles/mgrote.systemd-timesyncd/handlers/main.yml deleted file mode 100644 index dd50d2a4..00000000 --- a/roles/mgrote.systemd-timesyncd/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart systemd-timesyncd.service - become: yes - systemd: - name: systemd-timesyncd - state: restarted - when: not ansible_facts['virtualization_type'] == "lxc" diff --git a/roles/mgrote.systemd-timesyncd/tasks/main.yml b/roles/mgrote.systemd-timesyncd/tasks/main.yml deleted file mode 100644 index effc42ef..00000000 --- a/roles/mgrote.systemd-timesyncd/tasks/main.yml +++ /dev/null @@ -1,57 +0,0 @@ ---- - - - name: gather package facts - become: yes - ansible.builtin.package_facts: - manager: auto - - # deaktiviere andere ntp-implementationen - - name: stop and mask ntp service - become: yes - systemd: - name: ntp - masked: yes - state: stopped - enabled: no - when: "'ntp' in ansible_facts.packages" - - - name: stop and mask chrony service - become: yes - systemd: - name: chrony - masked: yes - state: stopped - enabled: no - when: "'chrony' in ansible_facts.packages" - - - name: install systemd-timesyncd - become: yes - ansible.builtin.package: - name: - - systemd-timesyncd - state: present - - - name: template systemd-timesyncd config - become: yes - ansible.builtin.template: - src: "timesyncd.conf.j2" - dest: "/etc/systemd/timesyncd.conf" - mode: 0644 - owner: root - group: root - notify: restart systemd-timesyncd.service - - - name: activate systemd-timesyncd service (not within containers like lxc) - become: yes - systemd: - name: systemd-timesyncd - masked: no - state: started - enabled: yes - when: not ansible_facts['virtualization_type'] == "lxc" - tags: test - - - name: set timezone to {{ ntp_timesyncd_timezone }} - become: yes - community.general.timezone: - name: "{{ ntp_timesyncd_timezone }}" diff --git a/roles/mgrote.timeshift/LICENSE b/roles/mgrote.timeshift/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.timeshift/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.timeshift/handlers/main.yml b/roles/mgrote.timeshift/handlers/main.yml deleted file mode 100644 index 6ed760d9..00000000 --- a/roles/mgrote.timeshift/handlers/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - - name: create snapshot - become: yes - ansible.builtin.shell: "/usr/bin/timeshift --scripted --create" diff --git a/roles/mgrote.timeshift/tasks/main.yml b/roles/mgrote.timeshift/tasks/main.yml deleted file mode 100644 index 52bd46c6..00000000 --- a/roles/mgrote.timeshift/tasks/main.yml +++ /dev/null @@ -1,23 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - timeshift - state: present - notify: create snapshot - - - name: copy timeshift config - become: yes - ansible.builtin.template: - src: "timeshift.json" - dest: "/etc/timeshift/timeshift.json" - - - name: create timeshift cronjob - become: yes - ansible.builtin.cron: - name: restic - state: present - job: "/usr/bin/timeshift --scripted --create" - minute: "7" - hour: "*/4" diff --git a/roles/mgrote.tor-node/LICENSE b/roles/mgrote.tor-node/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.tor-node/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.tor-node/defaults/main.yml b/roles/mgrote.tor-node/defaults/main.yml deleted file mode 100644 index ebb299b3..00000000 --- a/roles/mgrote.tor-node/defaults/main.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- - # required - # [a-zA-Z0-9] - tor_relay_name: tor1name - tor_or_port: 443 - tor_socks_port: 0 - tor_control_socket: 0 - tor_contact_info: webmaster@domain.local - tor_control_port: 9051 - # optional - # tor_my_family: name - # tor_bandwidth_rate: - # tor_bandwidth_burst: - tor_mode: relay # OR bridge - tor_bridge_port: 5555 - - # use IPv6 - tor_ipv6: false diff --git a/roles/mgrote.tor-node/handlers/main.yml b/roles/mgrote.tor-node/handlers/main.yml deleted file mode 100644 index b22db5b7..00000000 --- a/roles/mgrote.tor-node/handlers/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: restart tor - become: yes - systemd: - name: tor - enabled: yes - state: restarted diff --git a/roles/mgrote.tor-node/tasks/bridge.yml b/roles/mgrote.tor-node/tasks/bridge.yml deleted file mode 100644 index 2fe5fc2c..00000000 --- a/roles/mgrote.tor-node/tasks/bridge.yml +++ /dev/null @@ -1,15 +0,0 @@ ---- - - name: install obsf packages - become: yes - ansible.builtin.package: - name: - - obfs4proxy - state: present - notify: restart tor - - - name: templating torrc - become: yes - ansible.builtin.template: - src: "bridge_torrc" - dest: "/etc/tor/torrc" - notify: restart tor diff --git a/roles/mgrote.tor-node/tasks/main.yml b/roles/mgrote.tor-node/tasks/main.yml deleted file mode 100644 index 3e80c6f0..00000000 --- a/roles/mgrote.tor-node/tasks/main.yml +++ /dev/null @@ -1,39 +0,0 @@ ---- - - name: install dependencies - become: yes - ansible.builtin.package: - name: apt-transport-https - state: present - - - name: add tor repo key - ansible.builtin.apt_key: - url: https://deb.torproject.org/torproject.org/A3C4F0F979CAA22CDBA8F512EE8CBC9E886DDD89.asc - state: present - - - name: add tor repo - ansible.builtin.apt_repository: - repo: deb https://deb.torproject.org/torproject.org {{ ansible_distribution_release }} main - state: present - filename: tor - - - name: install tor packages - become: yes - ansible.builtin.package: - name: - - tor - - deb.torproject.org-keyring - state: present - notify: restart tor - - - name: include bridge tasks - include_tasks: bridge.yml - when: - - tor_mode == 'bridge' - - - name: include relay tasks - include_tasks: relay.yml - when: - - tor_mode == 'relay' - - - name: include nyx tasks - include_tasks: nyx.yml diff --git a/roles/mgrote.tor-node/tasks/nyx.yml b/roles/mgrote.tor-node/tasks/nyx.yml deleted file mode 100644 index 67948f31..00000000 --- a/roles/mgrote.tor-node/tasks/nyx.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- - - name: install nyx packages - become: yes - ansible.builtin.package: - name: - - nyx - state: present - notify: restart tor diff --git a/roles/mgrote.tor-node/tasks/relay.yml b/roles/mgrote.tor-node/tasks/relay.yml deleted file mode 100644 index 33532d3c..00000000 --- a/roles/mgrote.tor-node/tasks/relay.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - - name: templating torrc - become: yes - ansible.builtin.template: - src: "relay_torrc" - dest: "/etc/tor/torrc" - notify: restart tor diff --git a/roles/mgrote.users/LICENSE b/roles/mgrote.users/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.users/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.users/tasks/main.yml b/roles/mgrote.users/tasks/main.yml deleted file mode 100644 index a86c3121..00000000 --- a/roles/mgrote.users/tasks/main.yml +++ /dev/null @@ -1,43 +0,0 @@ ---- - - name: set groups as list - ansible.builtin.set_fact: - groups_as_list: "{{ (groups_as_list|default([]) + item.groups.split(','))|map('trim')|list|sort|unique }}" - loop: '{{ users }}' - when: item.groups is defined - - - name: create groups - ansible.builtin.group: - name: "{{ item }}" - state: present - loop: "{{ groups_as_list }}" - when: groups_as_list is defined - - - name: create users - ansible.builtin.user: - name: "{{ item.username }}" - uid: "{{ item.uid | default(omit) }}" - shell: "{{ item.shell | default('/bin/bash') }}" - password: "{{ item.password }}" - update_password: "{{ item.update_password | default(omit) }}" - groups: "{{ item.groups | default(omit) }}" - createhome: "{{ item.createhome | default('yes') }}" - state: "{{ item.state | default('present') }}" - loop: '{{ users }}' - - - name: add ssh key - ansible.posix.authorized_key: - user: "{{ item.username }}" - key: "{{ item.public_ssh_key }}" - state: present - when: item.public_ssh_key is defined - loop: '{{ users }}' - - - name: add to sudoers - ansible.builtin.lineinfile: - dest: /etc/sudoers - state: present - regexp: '^{{ item.username }} ' - line: "{{ item.username }} ALL=(ALL) {{ 'NOPASSWD:' if ( item.allow_passwordless_sudo|d(false) ) else '' }}ALL" - validate: 'visudo -cf %s' - when: item.allow_sudo|default(false) == true and item.allow_sudo is defined - loop: '{{ users }}' diff --git a/roles/mgrote.vim/LICENSE b/roles/mgrote.vim/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.vim/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.vim/defaults/main.yml b/roles/mgrote.vim/defaults/main.yml deleted file mode 100644 index 88e992c7..00000000 --- a/roles/mgrote.vim/defaults/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- - vim_vundle_path: /home/mg/.vim/bundle/Vundle.vim - vim_vundle_repo_url: https://github.com/VundleVim/Vundle.vim.git - vim_homedir: /home/mg/.vim diff --git a/roles/mgrote.vim/tasks/main.yml b/roles/mgrote.vim/tasks/main.yml deleted file mode 100644 index a3571812..00000000 --- a/roles/mgrote.vim/tasks/main.yml +++ /dev/null @@ -1,45 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - vim - - ripgrep - state: present - - - name: check if vundle is installed - folder - become: yes - stat: - path: "{{ vim_vundle_path }}" - register: folder_exists - - - - name: set safe directory - become: true - ansible.builtin.shell: - cmd: git config --global --add safe.directory "{{ vim_vundle_path }}" - changed_when: false - - - name: Ensure repository is cloned locally. - git: - repo: "{{ vim_vundle_repo_url }}" - dest: "{{ vim_vundle_path }}" - depth: 1 - register: repo_cloned - - - name: set owner recursive for repo - file: - path: "{{ vim_homedir }}" - owner: mg - group: mg - recurse: yes - when: repo_cloned.changed == true - -# - name: Vundle - PluginInstall -# ansible.builtin.shell: yes | vim -c PluginInstall -c qall -# args: -# chdir: /home/mg -# when: -# - (folder_exists.stat.exists == False) and ("ansible_facts['distribution'] == 'Ubuntu'") -# become: yes -# become_user: mg diff --git a/roles/mgrote.xnview/LICENSE b/roles/mgrote.xnview/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.xnview/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.xnview/defaults/main.yml b/roles/mgrote.xnview/defaults/main.yml deleted file mode 100644 index 136aa1a7..00000000 --- a/roles/mgrote.xnview/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - xnview_deb_url: https://download.xnview.com/XnViewMP-linux-x64.deb diff --git a/roles/mgrote.xnview/tasks/main.yml b/roles/mgrote.xnview/tasks/main.yml deleted file mode 100644 index 61d6ec2c..00000000 --- a/roles/mgrote.xnview/tasks/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: download and install xnview - become: true - apt: - deb: "{{ xnview_deb_url }}" diff --git a/roles/mgrote.xrdp/LICENSE b/roles/mgrote.xrdp/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.xrdp/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.xrdp/tasks/main.yml b/roles/mgrote.xrdp/tasks/main.yml deleted file mode 100644 index bd28f48c..00000000 --- a/roles/mgrote.xrdp/tasks/main.yml +++ /dev/null @@ -1,24 +0,0 @@ ---- - - name: install packages - become: yes - ansible.builtin.package: - name: - - xrdp - - xorgxrdp - state: present - - - name: create xsession config file - become: true - ansible.builtin.file: - path: "/home/{{ xrdp_user | default('mg') }}/.xsession" - state: touch - owner: "{{ xrdp_user | default('mg') }}" - modification_time: preserve - access_time: preserve - - - name: set xsession config - become: true - ansible.builtin.blockinfile: - path: "/home/{{ xrdp_user | default('mg') }}/.xsession" - block: | - env -u SESSION_MANAGER -u DBUS_SESSION_BUS_ADDRESS cinnamon-session diff --git a/roles/mgrote.youtubedl/LICENSE b/roles/mgrote.youtubedl/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.youtubedl/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.youtubedl/handlers/main.yml b/roles/mgrote.youtubedl/handlers/main.yml deleted file mode 100644 index c73886d6..00000000 --- a/roles/mgrote.youtubedl/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes diff --git a/roles/mgrote.youtubedl/tasks/main.yml b/roles/mgrote.youtubedl/tasks/main.yml deleted file mode 100644 index b159f3cd..00000000 --- a/roles/mgrote.youtubedl/tasks/main.yml +++ /dev/null @@ -1,83 +0,0 @@ ---- - - name: download binary - become: yes - ansible.builtin.get_url: - url: "{{ ytdl_dl_url }}" - dest: /usr/local/bin/yt-dlp - mode: '0750' - - - name: install packages - become: yes - ansible.builtin.package: - name: - - ffmpeg - - brotli - - python3-mutagen - state: present - - - name: ensure dir exists - become: yes - ansible.builtin.file: - path: "{{ ytdl_conf_dir }}" - state: directory - - - name: template youtubedl config - become: yes - ansible.builtin.template: - src: "{{ item }}" - dest: "{{ ytdl_conf_dir }}/{{ item }}" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - loop: - - podcast.txt - - youtube.txt - - - name: template systemd services - become: yes - ansible.builtin.template: - src: "youtubedl.service.j2" - dest: "/etc/systemd/system/youtubedl.service" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - when: ytdl_active - - - name: template youtubedl timer - become: yes - ansible.builtin.template: - src: "youtubedl.timer.j2" - dest: "/etc/systemd/system/youtubedl.timer" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - when: ytdl_active - - - name: template youtube_mail.service.j2 - become: yes - ansible.builtin.template: - src: "youtubedl_mail.service.j2" - dest: "/etc/systemd/system/youtubedl_mail.service" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - when: ytdl_active - - - name: systemctl enable timer units - become: yes - ansible.builtin.systemd: - name: "youtubedl.timer" - enabled: yes - masked: no - state: started - notify: - - systemctl daemon-reload - when: ytdl_active diff --git a/roles/mgrote.zfs_arc_mem/LICENSE b/roles/mgrote.zfs_arc_mem/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_arc_mem/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_arc_mem/defaults/main.yml b/roles/mgrote.zfs_arc_mem/defaults/main.yml deleted file mode 100644 index 0fcfef08..00000000 --- a/roles/mgrote.zfs_arc_mem/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - zfs_extra_arc_max_size: "8589934592" #in Bytes diff --git a/roles/mgrote.zfs_arc_mem/tasks/main.yml b/roles/mgrote.zfs_arc_mem/tasks/main.yml deleted file mode 100644 index 2e3e4255..00000000 --- a/roles/mgrote.zfs_arc_mem/tasks/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - - name: Limit ZFS Memory Usage - become: yes - ansible.builtin.copy: - dest: /etc/modprobe.d/zfs.conf - content: options zfs zfs_arc_max={{ zfs_extra_arc_max_size }} diff --git a/roles/mgrote.zfs_health/LICENSE b/roles/mgrote.zfs_health/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_health/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_health/defaults/main.yml b/roles/mgrote.zfs_health/defaults/main.yml deleted file mode 100644 index 49447bae..00000000 --- a/roles/mgrote.zfs_health/defaults/main.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- - ### when should the script be run - zfs_extra_cron_minutes_zfs_health: "0,15,30,45" - zfs_extra_cron_hours_zfs_health: "*" - ### under which user the script is run - zfs_health_user_group: "root" - zfs_health_user: "zfs-health" diff --git a/roles/mgrote.zfs_health/tasks/main.yml b/roles/mgrote.zfs_health/tasks/main.yml deleted file mode 100644 index 383da670..00000000 --- a/roles/mgrote.zfs_health/tasks/main.yml +++ /dev/null @@ -1,22 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - name: template script - become: yes - ansible.builtin.template: - src: zfs-health.sh - dest: /usr/local/bin/zfs-health.sh - mode: 0744 - owner: "{{ zfs_health_user }}" - group: "{{ zfs_health_user_group }}" - - - name: ensure cronjob exists - become: yes - ansible.builtin.cron: - name: zfs_health - state: present - job: "/usr/local/bin/zfs-health.sh" - minute: "{{ zfs_extra_cron_minutes_zfs_health }}" - hour: "{{ zfs_extra_cron_hours_zfs_health }}" - user: "{{ zfs_health_user }}" diff --git a/roles/mgrote.zfs_health/tasks/user.yml b/roles/mgrote.zfs_health/tasks/user.yml deleted file mode 100644 index 7ab13eed..00000000 --- a/roles/mgrote.zfs_health/tasks/user.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ zfs_health_user_group }}" - state: present - when: - - zfs_health_user_group is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ zfs_health_user }}" - group: "{{ zfs_health_user_group }}" - shell: /usr/sbin/nologin - create_home: no - when: - - zfs_health_user_group is defined - - zfs_health_user is defined diff --git a/roles/mgrote.zfs_manage_datasets/LICENSE b/roles/mgrote.zfs_manage_datasets/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_manage_datasets/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_manage_datasets/meta/main.yml b/roles/mgrote.zfs_manage_datasets/meta/main.yml deleted file mode 100644 index b4b6cedb..00000000 --- a/roles/mgrote.zfs_manage_datasets/meta/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - collections: - - community.general diff --git a/roles/mgrote.zfs_manage_datasets/tasks/main.yml b/roles/mgrote.zfs_manage_datasets/tasks/main.yml deleted file mode 100644 index d56d179c..00000000 --- a/roles/mgrote.zfs_manage_datasets/tasks/main.yml +++ /dev/null @@ -1,59 +0,0 @@ ---- - - name: create datasets or set options - become: true - community.general.zfs: - name: "{{ item.dataset }}" - state: "{{ item.state | default('present') }}" - extra_zfs_properties: - quota: "{{ item.quota | default(omit) }}" - reservation: "{{ item.reservation | default(omit) }}" - recordsize: "{{ item.recordsize | default(omit) }}" - mountpoint: "{{ item.mountpoint | default(omit) }}" - sharenfs: "{{ item.sharenfs | default(omit) }}" - checksum: "{{ item.checksum | default(omit) }}" - compression: "{{ item.compression | default(omit) }}" - atime: "{{ item.atime | default(omit) }}" - devices: "{{ item.devices | default(omit) }}" - exec: "{{ item.exec | default(omit) }}" - setuid: "{{ item.setuid | default(omit) }}" - readonly: "{{ item.readonly | default(omit) }}" - zoned: "{{ item.zoned | default(omit) }}" - snapdir: "{{ item.snapdir | default(omit) }}" - aclmode: "{{ item.aclmode | default(omit) }}" - aclinherit: "{{ item.aclinherit | default(omit) }}" - canmount: "{{ item.canmount | default(omit) }}" - xattr: "{{ item.xattr | default(omit) }}" - copies: "{{ item.copies | default(omit) }}" - vscan: "{{ item.vscan | default(omit) }}" - nbmand: "{{ item.nbmand | default(omit) }}" - sharesmb: "{{ item.sharesmb | default(omit) }}" - refquota: "{{ item.refquota | default(omit) }}" - refreservation: "{{ item.refreservation | default(omit) }}" - primarycache: "{{ item.primarycache | default(omit) }}" - secondarycache: "{{ item.secondarycache | default(omit) }}" - logbias: "{{ item.logbias | default(omit) }}" - dedup: "{{ item.dedup | default(omit) }}" - mlslabel: "{{ item.mlslabel | default(omit) }}" - sync: "{{ item.sync | default(omit) }}" - dnodesize: "{{ item.dnodesize | default(omit) }}" - volmode: "{{ item.volmode | default(omit) }}" - filesystem_limit: "{{ item.filesystem_limit | default(omit) }}" - snapshot_limit: "{{ item.snapshot_limit | default(omit) }}" - filesystem_count: "{{ item.filesystem_count | default(omit) }}" - snapshot_count: "{{ item.snapshot_count | default(omit) }}" - snapdev: "{{ item.snapdev | default(omit) }}" - acltype: "{{ item.acltype | default(omit) }}" - context: "{{ item.context | default(omit) }}" - fscontext: "{{ item.fscontext | default(omit) }}" - defcontext: "{{ item.defcontext | default(omit) }}" - rootcontext: "{{ item.rootcontext | default(omit) }}" - relatime: "{{ item.relatime | default(omit) }}" - redundant_metadata: "{{ item.redundant_metadata | default(omit) }}" - overlay: "{{ item.overlay | default(omit) }}" - encryption: "{{ item.encryption | default(omit) }}" - keylocation: "{{ item.keylocation | default(omit) }}" - keyformat: "{{ item.keyformat | default(omit) }}" - pbkdf2iters: "{{ item.pbkdf2iters | default(omit) }}" - special_small_blocks: "{{ item.special_small_blocks | default(omit) }}" - loop: "{{ zfs_datasets }}" - when: zfs_datasets is defined # führe nur aus wenn die Variable gesetzt ist diff --git a/roles/mgrote.zfs_packages/LICENSE b/roles/mgrote.zfs_packages/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_packages/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_packages/tasks/main.yml b/roles/mgrote.zfs_packages/tasks/main.yml deleted file mode 100644 index cd1f585b..00000000 --- a/roles/mgrote.zfs_packages/tasks/main.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- - - name: install zfs-tools-packages - become: yes - ansible.builtin.package: - name: - - zfsutils - - zfs-initramfs - - zfs-zed - state: present diff --git a/roles/mgrote.zfs_sanoid/LICENSE b/roles/mgrote.zfs_sanoid/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_sanoid/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_sanoid/handlers/main.yml b/roles/mgrote.zfs_sanoid/handlers/main.yml deleted file mode 100644 index c73886d6..00000000 --- a/roles/mgrote.zfs_sanoid/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes diff --git a/roles/mgrote.zfs_sanoid/tasks/destination.yml b/roles/mgrote.zfs_sanoid/tasks/destination.yml deleted file mode 100644 index e0870e0d..00000000 --- a/roles/mgrote.zfs_sanoid/tasks/destination.yml +++ /dev/null @@ -1,77 +0,0 @@ ---- - - name: template ssh private key - become: true - ansible.builtin.copy: - content: "{{ sanoid_syncoid_ssh_privkey }}" - dest: "/etc/sanoid/.ssh/id_sanoid" - owner: "{{ sanoid_user }}" - group: "{{ sanoid_user_group }}" - mode: 0400 - no_log: true - when: - - sanoid_syncoid_destination_host - - - name: add user to sudoers - become: true - ansible.builtin.blockinfile: - path: /etc/sudoers - state: present - block: | - {{ sanoid_user }} ALL=(ALL) NOPASSWD:ALL - validate: '/usr/sbin/visudo -cf %s' - backup: yes - marker_begin: sanoid-sudoers BEGIN - marker_end: sanoid-sudoers END - when: - - sanoid_syncoid_destination_host - - - name: template syncoid.service - become: yes - ansible.builtin.template: - src: "syncoid.service.j2" - dest: /etc/systemd/system/syncoid.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - when: - - sanoid_syncoid_destination_host - - - name: template syncoid_mail.service - become: yes - ansible.builtin.template: - src: "syncoid_mail.service.j2" - dest: /etc/systemd/system/syncoid_mail.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - when: - - sanoid_syncoid_destination_host - - - name: template syncoid.timer - become: yes - ansible.builtin.template: - src: "syncoid.timer.j2" - dest: "/etc/systemd/system/syncoid.timer" - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - when: - - sanoid_syncoid_destination_host - - - name: enable syncoid.timer - become: yes - ansible.builtin.systemd: - name: "syncoid.timer" - enabled: yes - masked: no - state: started - notify: - - systemctl daemon-reload - when: - - sanoid_syncoid_destination_host diff --git a/roles/mgrote.zfs_sanoid/tasks/main.yml b/roles/mgrote.zfs_sanoid/tasks/main.yml deleted file mode 100644 index 9390048e..00000000 --- a/roles/mgrote.zfs_sanoid/tasks/main.yml +++ /dev/null @@ -1,64 +0,0 @@ ---- - - name: include user tasks - include_tasks: user.yml - - - name: install packages from repo - become: true - ansible.builtin.apt: - name: - - mbuffer - - lzop - - libcapture-tiny-perl - - pv - state: present - - - name: install packages from self-build - become: true - ansible.builtin.apt: - deb: "{{ sanoid_deb_url }}" - state: present - - - name: create sanoid directories - become: true - ansible.builtin.file: - path: "{{ item }}" - state: directory - owner: "{{ sanoid_user }}" - group: "{{ sanoid_user_group }}" - mode: 0700 - with_items: - - "/etc/sanoid" - - "/etc/sanoid/.ssh" - - - name: include snaps tasks - include_tasks: snaps.yml - when: - - sanoid_datasets is defined - - sanoid_templates is defined - - sanoid_snaps_enable is defined - - sanoid_snaps_enable - - - name: ensure service are started - become: true - ansible.builtin.systemd: - state: started - name: "{{ item }}" - daemon_reload: true - masked: false - enabled: yes - loop: - - sanoid.service - - sanoid-prune.service - - sanoid.timer - - - name: include source-host tasks - include_tasks: source.yml - when: - - sanoid_syncoid_source_host is defined and sanoid_syncoid_source_host is true - - sanoid_syncoid_ssh_pubkey is defined - - - name: include destination-host tasks - include_tasks: destination.yml - when: - - sanoid_syncoid_destination_host is defined and sanoid_syncoid_destination_host is true - - sanoid_syncoid_ssh_privkey is defined diff --git a/roles/mgrote.zfs_sanoid/tasks/snaps.yml b/roles/mgrote.zfs_sanoid/tasks/snaps.yml deleted file mode 100644 index 435a4b1c..00000000 --- a/roles/mgrote.zfs_sanoid/tasks/snaps.yml +++ /dev/null @@ -1,49 +0,0 @@ ---- - - name: Generate Sanoid Configuration - become: true - ansible.builtin.template: - src: sanoid.conf.j2 - dest: "/etc/sanoid/sanoid.conf" - owner: "{{ sanoid_user }}" - group: "{{ sanoid_user_group }}" - mode: 0400 - - - name: template sanoid_mail.service - become: yes - ansible.builtin.template: - src: "sanoid_mail.service.j2" - dest: /etc/systemd/system/sanoid_mail.service - owner: root - group: root - mode: 0644 - notify: - - systemctl daemon-reload - - - name: add sanoid_mail.service to sanoid.service - become: true - ansible.builtin.blockinfile: - create: yes - mode: 0644 - owner: root - group: root - path: /lib/systemd/system/sanoid.service.d/override.conf - block: | - [Unit] - OnFailure = sanoid_mail.service - notify: - - systemctl daemon-reload - - - name: set timer - become: true - ansible.builtin.blockinfile: - create: yes - mode: 0644 - owner: root - group: root - path: /lib/systemd/system/sanoid.timer.d/override.conf - block: | - [Timer] - OnCalendar = {{ sanoid_timer }} - when: sanoid_timer is defined - notify: - - systemctl daemon-reload diff --git a/roles/mgrote.zfs_sanoid/tasks/source.yml b/roles/mgrote.zfs_sanoid/tasks/source.yml deleted file mode 100644 index 6bb01030..00000000 --- a/roles/mgrote.zfs_sanoid/tasks/source.yml +++ /dev/null @@ -1,23 +0,0 @@ ---- - - name: template ssh public key - become: true - ansible.posix.authorized_key: - user: "{{ sanoid_user }}" - key: "{{ sanoid_syncoid_ssh_pubkey }}" - state: present - when: - - sanoid_syncoid_source_host - - - name: add user to sudoers - become: true - ansible.builtin.blockinfile: - path: /etc/sudoers - state: present - block: | - {{ sanoid_user }} ALL=(ALL) NOPASSWD:ALL - validate: '/usr/sbin/visudo -cf %s' - backup: yes - marker_begin: sanoid-sudoers BEGIN - marker_end: sanoid-sudoers END - when: - - sanoid_syncoid_source_host diff --git a/roles/mgrote.zfs_sanoid/tasks/user.yml b/roles/mgrote.zfs_sanoid/tasks/user.yml deleted file mode 100644 index 80c02b23..00000000 --- a/roles/mgrote.zfs_sanoid/tasks/user.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- - - name: ensure group exists - become: true - ansible.builtin.group: - name: "{{ sanoid_user_group }}" - state: present - when: - - sanoid_user_group is defined - - sanoid_user is defined - - - name: ensure user exists - become: true - ansible.builtin.user: - name: "{{ sanoid_user }}" - group: "{{ sanoid_user_group }}" - create_home: yes - when: - - sanoid_user_group is defined - - sanoid_user is defined diff --git a/roles/mgrote.zfs_scrub/LICENSE b/roles/mgrote.zfs_scrub/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_scrub/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_scrub/defaults/main.yml b/roles/mgrote.zfs_scrub/defaults/main.yml deleted file mode 100644 index e453a8c3..00000000 --- a/roles/mgrote.zfs_scrub/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - zfs_extra_path_zpool: "/usr/sbin/zpool" diff --git a/roles/mgrote.zfs_scrub/tasks/main.yml b/roles/mgrote.zfs_scrub/tasks/main.yml deleted file mode 100644 index 8ab69285..00000000 --- a/roles/mgrote.zfs_scrub/tasks/main.yml +++ /dev/null @@ -1,84 +0,0 @@ ---- - - name: template unit-template - become: true - ansible.builtin.template: - src: zpool-scrub@.service.j2 - dest: /etc/systemd/system/zpool-scrub@.service - owner: root - group: root - mode: 0644 - register: template_unit - - - name: template timer - become: true - ansible.builtin.template: - src: zpool-scrub@.timer.j2 - dest: "/etc/systemd/system/zpool-scrub@{{ item.name }}.timer" - owner: root - group: root - mode: 0644 - loop: "{{ zfs_extra_zfs_pools }}" - register: template_timer - - - name: template mail.service - become: true - ansible.builtin.template: - src: zpool-scrub-mail.service.j2 - dest: "/etc/systemd/system/zpool-scrub-mail.service" - owner: root - group: root - mode: 0644 - register: template_mail - - - name: systemctl daemon-reload - become: yes - ansible.builtin.systemd: - daemon_reload: yes - when: - - template_unit.changed - - template_timer.changed - - - name: systemctl enable units - timer - become: yes - ansible.builtin.systemd: - name: "zpool-scrub@{{ item.name }}.timer" - enabled: yes - masked: no - loop: "{{ zfs_extra_zfs_pools }}" - when: - - template_unit.changed - - template_timer.changed - - - name: systemctl enable units - mail - become: yes - ansible.builtin.systemd: - name: "zpool-scrub-mail.service" - enabled: yes - masked: no - when: - - template_mail - - - name: systemctl start units - become: yes - ansible.builtin.systemd: - name: "zpool-scrub@{{ item.name }}.timer" - state: restarted - enabled: yes - loop: "{{ zfs_extra_zfs_pools }}" - when: - - template_unit.changed - - template_timer.changed - - - name: remove old cronjobs - become: yes - ansible.builtin.cron: - name: zfs-scrub - "{{ item.name }}" - state: absent - with_items: "{{ zfs_extra_zfs_pools }}" - - - name: remove proxmox system scrub job #https://forum.proxmox.com/threads/script-sequential-zfs-scrub-for-cron.25124/ - become: true - ansible.builtin.lineinfile: - path: /etc/cron.d/zfsutils-linux - state: absent - line: '24 0 8-14 * * root if [ $(date +\%w) -eq 0 ] && [ -x /usr/lib/zfs-linux/scrub ]; then /usr/lib/zfs-linux/scrub; fi' diff --git a/roles/mgrote.zfs_zed/LICENSE b/roles/mgrote.zfs_zed/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zfs_zed/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zfs_zed/handlers/main.yml b/roles/mgrote.zfs_zed/handlers/main.yml deleted file mode 100644 index b9dd0034..00000000 --- a/roles/mgrote.zfs_zed/handlers/main.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- - - name: testmail - shell: echo "zed ist eingerichtet" | mail -s "{{ ansible_hostname }} - zed" {{ empfaenger_mail }} diff --git a/roles/mgrote.zfs_zed/tasks/main.yml b/roles/mgrote.zfs_zed/tasks/main.yml deleted file mode 100644 index bb8039f9..00000000 --- a/roles/mgrote.zfs_zed/tasks/main.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- - - name: kopiere zed.rc - become: yes - ansible.builtin.template: - owner: root - mode: 0600 - src: zed.rc - dest: /etc/zfs/zed.d/zed.rc - notify: testmail diff --git a/roles/mgrote.zswap/LICENSE b/roles/mgrote.zswap/LICENSE deleted file mode 100644 index e72bfdda..00000000 --- a/roles/mgrote.zswap/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. \ No newline at end of file diff --git a/roles/mgrote.zswap/defaults/main.yml b/roles/mgrote.zswap/defaults/main.yml deleted file mode 100644 index d1879609..00000000 --- a/roles/mgrote.zswap/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- - zswap_path: "/sys/module/zswap/parameters/enabled" diff --git a/roles/mgrote.zswap/tasks/main.yml b/roles/mgrote.zswap/tasks/main.yml deleted file mode 100644 index ffe6ee93..00000000 --- a/roles/mgrote.zswap/tasks/main.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - - name: add zswap to crontab - ansible.builtin.cron: - name: "activate zswap" - special_time: reboot - job: "echo 1 > {{ zswap_path }}" diff --git a/roles/mgrote.apt_manage_packages/README.md b/roles/mgrote_apt_manage_packages/README.md similarity index 100% rename from roles/mgrote.apt_manage_packages/README.md rename to roles/mgrote_apt_manage_packages/README.md diff --git a/roles/mgrote_apt_manage_packages/defaults/main.yml b/roles/mgrote_apt_manage_packages/defaults/main.yml new file mode 100644 index 00000000..6afe8b53 --- /dev/null +++ b/roles/mgrote_apt_manage_packages/defaults/main.yml @@ -0,0 +1,35 @@ +--- +apt_packages_common: + - locales + - build-essential + - ntp + - htop + - git + - dnsutils + - nano + - mc + - cifs-utils + - netdiscover + - tree + - curl + - logrotate + - ncdu + - net-tools + - sysstat + - apt-transport-https + - neofetch + - ntpdate + - acl + - python3 + - vim +apt_packages_physical: + - hddtemp + - ipmitool + - powertop + - s-tui +apt_packages_vm: + - qemu-guest-agent + - open-vm-tools +apt_packages_extra: +apt_packages_absent: +apt_packages_internet: diff --git a/roles/mgrote_apt_manage_packages/tasks/main.yml b/roles/mgrote_apt_manage_packages/tasks/main.yml new file mode 100644 index 00000000..1dd66f7a --- /dev/null +++ b/roles/mgrote_apt_manage_packages/tasks/main.yml @@ -0,0 +1,41 @@ +--- +- name: install common-packages + become: true + ansible.builtin.package: + name: "{{ apt_packages_common }}" + state: present + +- name: install extra-packages + become: true + ansible.builtin.package: + name: "{{ apt_packages_extra }}" + state: present + when: apt_packages_extra is defined + +- name: install vm-packages + become: true + ansible.builtin.package: + name: "{{ apt_packages_vm }}" + state: present + when: ansible_virtualization_role == 'guest' + +- name: install physical-packages + become: true + ansible.builtin.package: + name: "{{ apt_packages_physical }}" + state: present + when: ansible_virtualization_role != 'guest' + +- name: install packages from the internet + become: true + ansible.builtin.apt: + deb: "{{ item }}" + state: present + when: apt_packages_internet is defined + loop: "{{ apt_packages_internet }}" + +- name: remove packages + become: true + ansible.builtin.package: + name: "{{ apt_packages_absent }}" + state: absent diff --git a/roles/mgrote.apt_manage_sources/README.md b/roles/mgrote_apt_manage_sources/README.md similarity index 100% rename from roles/mgrote.apt_manage_sources/README.md rename to roles/mgrote_apt_manage_sources/README.md diff --git a/roles/mgrote.apt_manage_sources/defaults/main.yml b/roles/mgrote_apt_manage_sources/defaults/main.yml similarity index 100% rename from roles/mgrote.apt_manage_sources/defaults/main.yml rename to roles/mgrote_apt_manage_sources/defaults/main.yml diff --git a/roles/mgrote_apt_manage_sources/handlers/main.yml b/roles/mgrote_apt_manage_sources/handlers/main.yml new file mode 100644 index 00000000..a720cc79 --- /dev/null +++ b/roles/mgrote_apt_manage_sources/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: update package lists # noqa no-handler + become: true + ansible.builtin.apt: + update_cache: true diff --git a/roles/mgrote.apt_manage_sources/tasks/main.yml b/roles/mgrote_apt_manage_sources/tasks/main.yml similarity index 96% rename from roles/mgrote.apt_manage_sources/tasks/main.yml rename to roles/mgrote_apt_manage_sources/tasks/main.yml index 1dca1032..7c7c6c7c 100644 --- a/roles/mgrote.apt_manage_sources/tasks/main.yml +++ b/roles/mgrote_apt_manage_sources/tasks/main.yml @@ -44,6 +44,9 @@ ansible.builtin.template: src: sources.j2 dest: "{{ repo_sources_file }}" + mode: "0644" + owner: root + group: root notify: update package lists when: - repos is defined diff --git a/roles/mgrote.apt_manage_sources/tasks/pbs.yml b/roles/mgrote_apt_manage_sources/tasks/pbs.yml similarity index 82% rename from roles/mgrote.apt_manage_sources/tasks/pbs.yml rename to roles/mgrote_apt_manage_sources/tasks/pbs.yml index 4de4f3ce..56d422b0 100644 --- a/roles/mgrote.apt_manage_sources/tasks/pbs.yml +++ b/roles/mgrote_apt_manage_sources/tasks/pbs.yml @@ -1,7 +1,7 @@ --- - name: check if pbs-no-subscription repo keys exists become: true - stat: + ansible.builtin.stat: path: "{{ manage_sources_pbs_apt_repo_key_path }}" register: pbs_no_subscription_repo_keys @@ -11,4 +11,4 @@ url: "{{ manage_sources_pbs_apt_repo_key_url }}" state: present notify: update package lists - when: pbs_no_subscription_repo_keys.stat.exists == false + when: not pbs_no_subscription_repo_keys.stat.exists diff --git a/roles/mgrote.apt_manage_sources/tasks/pve.yml b/roles/mgrote_apt_manage_sources/tasks/pve.yml similarity index 79% rename from roles/mgrote.apt_manage_sources/tasks/pve.yml rename to roles/mgrote_apt_manage_sources/tasks/pve.yml index f1da012a..e99c7b58 100644 --- a/roles/mgrote.apt_manage_sources/tasks/pve.yml +++ b/roles/mgrote_apt_manage_sources/tasks/pve.yml @@ -1,14 +1,14 @@ --- - name: check if pve-no-subscription repo keys exists become: true - stat: + ansible.builtin.stat: path: "{{ manage_sources_proxmox_apt_repo_key_path }}" register: pve_no_subscription_repo_keys - name: add pve-no-subscription repo keys - become: yes + become: true ansible.builtin.apt_key: url: "{{ manage_sources_proxmox_apt_repo_key_url }}" state: present notify: update package lists - when: pve_no_subscription_repo_keys.stat.exists == false + when: not pve_no_subscription_repo_keys.stat.exists diff --git a/roles/mgrote.apt_manage_sources/templates/sources.j2 b/roles/mgrote_apt_manage_sources/templates/sources.j2 similarity index 100% rename from roles/mgrote.apt_manage_sources/templates/sources.j2 rename to roles/mgrote_apt_manage_sources/templates/sources.j2 diff --git a/roles/mgrote.apt_manage_sources/vars/mint.yml b/roles/mgrote_apt_manage_sources/vars/mint.yml similarity index 100% rename from roles/mgrote.apt_manage_sources/vars/mint.yml rename to roles/mgrote_apt_manage_sources/vars/mint.yml diff --git a/roles/mgrote.apt_manage_sources/vars/pbs.yaml b/roles/mgrote_apt_manage_sources/vars/pbs.yaml similarity index 100% rename from roles/mgrote.apt_manage_sources/vars/pbs.yaml rename to roles/mgrote_apt_manage_sources/vars/pbs.yaml diff --git a/roles/mgrote.apt_manage_sources/vars/pve.yaml b/roles/mgrote_apt_manage_sources/vars/pve.yaml similarity index 100% rename from roles/mgrote.apt_manage_sources/vars/pve.yaml rename to roles/mgrote_apt_manage_sources/vars/pve.yaml diff --git a/roles/mgrote.apt_manage_sources/vars/ubuntu.yaml b/roles/mgrote_apt_manage_sources/vars/ubuntu.yaml similarity index 100% rename from roles/mgrote.apt_manage_sources/vars/ubuntu.yaml rename to roles/mgrote_apt_manage_sources/vars/ubuntu.yaml diff --git a/roles/mgrote.apt_update_packages/README.md b/roles/mgrote_apt_update_packages/README.md similarity index 100% rename from roles/mgrote.apt_update_packages/README.md rename to roles/mgrote_apt_update_packages/README.md diff --git a/roles/mgrote_apt_update_packages/tasks/main.yml b/roles/mgrote_apt_update_packages/tasks/main.yml new file mode 100644 index 00000000..6de8a546 --- /dev/null +++ b/roles/mgrote_apt_update_packages/tasks/main.yml @@ -0,0 +1,10 @@ +--- +- name: update apt cache + become: true + ansible.builtin.apt: + update_cache: true + +- name: update installed packages + become: true + ansible.builtin.package: + upgrade: dist diff --git a/roles/mgrote.cv4pve-autosnap/README.md b/roles/mgrote_cv4pve_autosnap/README.md similarity index 100% rename from roles/mgrote.cv4pve-autosnap/README.md rename to roles/mgrote_cv4pve_autosnap/README.md diff --git a/roles/mgrote_cv4pve_autosnap/defaults/main.yml b/roles/mgrote_cv4pve_autosnap/defaults/main.yml new file mode 100644 index 00000000..7445698c --- /dev/null +++ b/roles/mgrote_cv4pve_autosnap/defaults/main.yml @@ -0,0 +1,14 @@ +--- +# when should cv4pve be run +cv4pve_cron_minute: "39" +cv4pve_cron_hour: "5" +# proxmox api-token and user +cv4pve_api_token: "XXXXXXXXXXXXXXXXXXXXXX" +cv4pve_api_user: "root@pam!test2" +# which vm to snapshot +cv4pve_vmid: all +# how many snapshots to keep +cv4pve_keep_snapshots: 3 +# under which user the script is run +cv4pve_user_group: cv4pve +cv4pve_user: cv4pve diff --git a/roles/mgrote_cv4pve_autosnap/handlers/main.yml b/roles/mgrote_cv4pve_autosnap/handlers/main.yml new file mode 100644 index 00000000..1e4f40c0 --- /dev/null +++ b/roles/mgrote_cv4pve_autosnap/handlers/main.yml @@ -0,0 +1,26 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true + +- name: systemctl enable units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + enabled: true + masked: false + with_items: + - cv4pve.service + - cv4pve_mail.service + - cv4pve.timer + +- name: systemctl start units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + state: restarted + enabled: true + with_items: + - cv4pve.timer + notify: systemctl daemon-reload diff --git a/roles/mgrote_cv4pve_autosnap/tasks/main.yml b/roles/mgrote_cv4pve_autosnap/tasks/main.yml new file mode 100644 index 00000000..9c9c6f6f --- /dev/null +++ b/roles/mgrote_cv4pve_autosnap/tasks/main.yml @@ -0,0 +1,75 @@ +--- +- name: include user tasks + ansible.builtin.include_tasks: user.yml + + +- name: create directories + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: "{{ cv4pve_user }}" + group: "{{ cv4pve_user_group }}" + mode: "0644" + loop: + - '/tmp/cv4pve' + - '/usr/local/bin/cv4pve' + +- name: download archives + become: true + ansible.builtin.get_url: + url: "{{ cv4pve_dl_link }}" + dest: /tmp/cv4pve/cv4pve-autosnap-linux-x64.zip + mode: '0775' + owner: "{{ cv4pve_user }}" + group: "{{ cv4pve_user_group }}" + +- name: extract archives + become: true + ansible.builtin.unarchive: + src: /tmp/cv4pve/cv4pve-autosnap-linux-x64.zip + dest: /usr/local/bin/cv4pve + remote_src: true + mode: a+x + owner: "{{ cv4pve_user }}" + group: "{{ cv4pve_user_group }}" + +- name: template cv4pve.service + become: true + ansible.builtin.template: + src: cv4pve.service.j2 + dest: /etc/systemd/system/cv4pve.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: template cv4pve_mail.service + become: true + ansible.builtin.template: + src: cv4pve_mail.service.j2 + dest: /etc/systemd/system/cv4pve_mail.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: template cv4pve.timer + become: true + ansible.builtin.template: + src: cv4pve.timer.j2 + dest: /etc/systemd/system/cv4pve.timer + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: systemctl start cv4pve.timer + become: true + ansible.builtin.systemd: + name: cv4pve.timer + state: started + enabled: true diff --git a/roles/mgrote_cv4pve_autosnap/tasks/user.yml b/roles/mgrote_cv4pve_autosnap/tasks/user.yml new file mode 100644 index 00000000..f304dc92 --- /dev/null +++ b/roles/mgrote_cv4pve_autosnap/tasks/user.yml @@ -0,0 +1,19 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ cv4pve_user_group }}" + state: present + when: + - cv4pve_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ cv4pve_user }}" + group: "{{ cv4pve_user_group }}" + shell: /usr/sbin/nologin + create_home: false + when: + - cv4pve_user_group is defined + - cv4pve_user is defined diff --git a/roles/mgrote.cv4pve-autosnap/templates/cv4pve.service.j2 b/roles/mgrote_cv4pve_autosnap/templates/cv4pve.service.j2 similarity index 100% rename from roles/mgrote.cv4pve-autosnap/templates/cv4pve.service.j2 rename to roles/mgrote_cv4pve_autosnap/templates/cv4pve.service.j2 diff --git a/roles/mgrote.cv4pve-autosnap/templates/cv4pve.timer.j2 b/roles/mgrote_cv4pve_autosnap/templates/cv4pve.timer.j2 similarity index 100% rename from roles/mgrote.cv4pve-autosnap/templates/cv4pve.timer.j2 rename to roles/mgrote_cv4pve_autosnap/templates/cv4pve.timer.j2 diff --git a/roles/mgrote.cv4pve-autosnap/templates/cv4pve_mail.service.j2 b/roles/mgrote_cv4pve_autosnap/templates/cv4pve_mail.service.j2 similarity index 100% rename from roles/mgrote.cv4pve-autosnap/templates/cv4pve_mail.service.j2 rename to roles/mgrote_cv4pve_autosnap/templates/cv4pve_mail.service.j2 diff --git a/roles/mgrote_deactivate_caps/handlers/main.yml b/roles/mgrote_deactivate_caps/handlers/main.yml new file mode 100644 index 00000000..88170a60 --- /dev/null +++ b/roles/mgrote_deactivate_caps/handlers/main.yml @@ -0,0 +1,4 @@ +--- +- name: deactivate caps + become: true + ansible.builtin.command: setxkbmap -option caps:none # noqa no-changed-when diff --git a/roles/mgrote.deactivate_caps/readme.md b/roles/mgrote_deactivate_caps/readme.md similarity index 100% rename from roles/mgrote.deactivate_caps/readme.md rename to roles/mgrote_deactivate_caps/readme.md diff --git a/roles/mgrote_deactivate_caps/tasks/main.yml b/roles/mgrote_deactivate_caps/tasks/main.yml new file mode 100644 index 00000000..d94f611b --- /dev/null +++ b/roles/mgrote_deactivate_caps/tasks/main.yml @@ -0,0 +1,8 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - x11-xkb-utils + state: present + notify: deactivate caps diff --git a/roles/mgrote.disable_oom_killer/README.md b/roles/mgrote_disable_oom_killer/README.md similarity index 100% rename from roles/mgrote.disable_oom_killer/README.md rename to roles/mgrote_disable_oom_killer/README.md diff --git a/roles/mgrote_disable_oom_killer/handlers/main.yml b/roles/mgrote_disable_oom_killer/handlers/main.yml new file mode 100644 index 00000000..c734b024 --- /dev/null +++ b/roles/mgrote_disable_oom_killer/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: disable oom-killer + become: true + ansible.builtin.command: echo 2 > /proc/sys/vm/overcommit_memory # noqa no-changed-when +... diff --git a/roles/mgrote_disable_oom_killer/tasks/main.yml b/roles/mgrote_disable_oom_killer/tasks/main.yml new file mode 100644 index 00000000..3f545dae --- /dev/null +++ b/roles/mgrote_disable_oom_killer/tasks/main.yml @@ -0,0 +1,8 @@ +--- +- name: disable oom-killer in sysctl.conf (works after a reboot) + become: true + ansible.builtin.blockinfile: + path: /etc/sysctl.conf + block: | + vm.oom-kill = 0 + notify: disable oom-killer diff --git a/roles/mgrote.docker-compose-inline/README.md b/roles/mgrote_docker_compose_inline/README.md similarity index 100% rename from roles/mgrote.docker-compose-inline/README.md rename to roles/mgrote_docker_compose_inline/README.md diff --git a/roles/mgrote_docker_compose_inline/defaults/main.yml b/roles/mgrote_docker_compose_inline/defaults/main.yml new file mode 100644 index 00000000..d541a689 --- /dev/null +++ b/roles/mgrote_docker_compose_inline/defaults/main.yml @@ -0,0 +1,18 @@ +--- +# owner and group of all files and directories +compose_owner: "docker-user" +compose_group: "docker-user" +# default permissions for all files and directories +compose_file_permissions: "644" +compose_dir_permissions: "755" +# where to store the compose-files on the destination system +compose_dest_basedir: "/docker" # without trailing "/" +# where are the docker-compose-files located on the ansible controller +compose_src_basedir: "{{ inventory_dir }}/docker-compose" # without trailing "/" +# dict of compose-files to deploy +#compose_files: +# - name: hastebin # used for directory name; starting & stopping +# state: present +# #network: test_nw # external network (optional) +# - name: ara +# state: present diff --git a/roles/mgrote_docker_compose_inline/tasks/main.yml b/roles/mgrote_docker_compose_inline/tasks/main.yml new file mode 100644 index 00000000..8169c2d3 --- /dev/null +++ b/roles/mgrote_docker_compose_inline/tasks/main.yml @@ -0,0 +1,97 @@ +--- +- name: ensure basedir exists + become: true + ansible.builtin.file: + path: "{{ compose_dest_basedir }}" + state: directory + mode: "{{ compose_dir_permissions }}" + owner: "{{ compose_owner }}" + group: "{{ compose_group }}" + +# https://codeutility.org/ansible-can-the-templates-module-handle-multiple-templates-directories-stack-overflow/ +- name: copy all directories recursively + ansible.builtin.file: + dest: "{{ compose_dest_basedir }}/{{ item | replace(compose_src_basedir + '/', '') }}" + state: directory + mode: "{{ compose_dir_permissions }}" + owner: "{{ compose_owner }}" + group: "{{ compose_group }}" + with_items: "{{ lookup('pipe', 'find '+ compose_src_basedir +'/ -type d').split('\n') }}" + +- name: copy all files recursively (can take a long time) + ansible.builtin.copy: + mode: "{{ compose_file_permissions }}" + owner: "{{ compose_owner }}" + group: "{{ compose_group }}" + src: "{{ item }}" + dest: "{{ compose_dest_basedir }}/{{ item | replace(compose_src_basedir + '/', '') }}" + with_items: "{{ lookup('pipe', 'find '+ compose_src_basedir +'/ -type f -not -name *.j2 ').split('\n') }}" + no_log: true + +- name: copy templates files recursively + ansible.builtin.template: + mode: "{{ compose_file_permissions }}" + owner: "{{ compose_owner }}" + group: "{{ compose_group }}" + src: "{{ item }}" + dest: "{{ compose_dest_basedir }}/{{ item | replace(compose_src_basedir + '/', '') | replace('.j2', '') }}" + with_items: "{{ lookup('pipe', 'find '+ compose_src_basedir +'/ -type f -name *.j2').split('\n') }}" + register: copy_template + no_log: true + +# - name: print $copy_template +# ansible.builtin.debug: +# var: copy_template + +- name: create networks + become: true + ansible.builtin.command: "docker network create {{ item.network }}" # erstelle network + register: network_result # speichere ergebnis in var + changed_when: "network_result.rc == 0" # markiere tasks als changed when exit-code == 0 + ignore_errors: true # ignoriere fehler + loop: "{{ compose_files }}" + when: + - item.state == "present" + - item.network is defined + +- name: (re)start container + become: true + ansible.builtin.command: docker-compose up -d + args: + chdir: "{{ compose_dest_basedir }}/{{ item.name }}" + register: start_result # speichere ergebnis in var + changed_when: "start_result.rc == 0" # markiere tasks als changed when exit-code == 0 + loop: "{{ compose_files }}" + when: + - item.state == "present" + - copy_template is changed + +- name: stop old container + become: true + ansible.builtin.command: docker-compose down # noqa no-changed-when + args: + chdir: "{{ compose_dest_basedir }}/{{ item.name }}" + loop: "{{ compose_files }}" + when: + - item.state == "absent" + ignore_errors: true # noqa ignore-errors + +- name: remove old networks + become: true + ansible.builtin.command: "docker network remove {{ item.network }}" # erstelle network + register: network_result # speichere ergebnis in var + changed_when: "network_result.rc == 0" # markiere tasks als changed when exit-code == 0 + ignore_errors: true # noqa ignore-errors + loop: "{{ compose_files }}" + when: + - item.state == "absent" + - item.network is defined + +- name: remove old docker-compose files & directories + become: true + ansible.builtin.file: + path: "{{ compose_dest_basedir }}/{{ item.name }}/" + state: absent + loop: "{{ compose_files }}" + when: + - item.state == "absent" diff --git a/roles/mgrote.dokuwiki/README.md b/roles/mgrote_dokuwiki/README.md similarity index 100% rename from roles/mgrote.dokuwiki/README.md rename to roles/mgrote_dokuwiki/README.md diff --git a/roles/mgrote_dokuwiki/defaults/main.yml b/roles/mgrote_dokuwiki/defaults/main.yml new file mode 100644 index 00000000..7d2904f5 --- /dev/null +++ b/roles/mgrote_dokuwiki/defaults/main.yml @@ -0,0 +1,6 @@ +--- +dokuwiki_install_path: /var/www/dokuwiki # wohin soll dokuwiki installiert werden +dokuwiki_download_url: https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz # wo soll dokuwiki heruntergeladen werden +dokuwiki_version_name: 2020-07-29 "Hogfather" # aus /var/www/dokuwiki/VERSION # welche Version, damit wird abgeglichen ob das Archiv heruntergeladen werden muss +dokuwiki_user: www-data # dokuwiki nutzer +dokuwiki_group: www-data # dokuwiki gruppe diff --git a/roles/mgrote_dokuwiki/handlers/main.yml b/roles/mgrote_dokuwiki/handlers/main.yml new file mode 100644 index 00000000..f7086e0e --- /dev/null +++ b/roles/mgrote_dokuwiki/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart_apache2 + become: true + ansible.builtin.systemd: + name: apache2 + state: restarted + enabled: true diff --git a/roles/mgrote_dokuwiki/tasks/apache2.yml b/roles/mgrote_dokuwiki/tasks/apache2.yml new file mode 100644 index 00000000..cbe57965 --- /dev/null +++ b/roles/mgrote_dokuwiki/tasks/apache2.yml @@ -0,0 +1,27 @@ +--- +# aktiviert das module rewrite = a2enmod rewrite +- name: activate a2enmod rewrite + become: true + ansible.builtin.apache2_module: + state: present + name: rewrite + +- name: copy default apache2.conf + become: true + ansible.builtin.template: + src: "apache2.conf" + dest: "/etc/apache2/apache2.conf" + mode: "0644" + owner: root + group: root + notify: restart_apache2 + +- name: copy 000-default.conf + become: true + ansible.builtin.template: + src: "000-default.conf" + dest: "/etc/apache2/sites-enabled/000-default.conf" + mode: "0644" + owner: root + group: root + notify: restart_apache2 diff --git a/roles/mgrote_dokuwiki/tasks/dokuwiki.yml b/roles/mgrote_dokuwiki/tasks/dokuwiki.yml new file mode 100644 index 00000000..dd9d6306 --- /dev/null +++ b/roles/mgrote_dokuwiki/tasks/dokuwiki.yml @@ -0,0 +1,73 @@ +--- +- name: create dokuwiki install path + become: true + ansible.builtin.file: + path: "{{ dokuwiki_install_path }}" + state: directory + owner: "{{ dokuwiki_user }}" + group: "{{ dokuwiki_group }}" + mode: "0744" + +- name: check if dokuwiki is installed + become: true + ansible.builtin.stat: + path: /var/www/dokuwiki/VERSION + register: dokuwiki_install_status + +- name: check if desired version is installed + become: true + ignore_errors: true + ansible.builtin.lineinfile: + path: /var/www/dokuwiki/VERSION + line: "{{ dokuwiki_version_name }}" + state: present + check_mode: true + register: dokuwiki_desired_version + when: + - dokuwiki_install_status.stat.exists + # falls Dokuwiki schon installiert ist existiert var/www/dokuwiki/VERSION mit + # dem Inhalt der Version: z.B. 2020-07-29 "Hogfather" + # when die Version die selbe wie in der Variable ist + # ist der status ok, ist die Version unterschiedlich ist der status changed, die Datei + # selber wird aber nicht geändert weil check_mode gleich yes ist + # das Ergebnis wird in der Variable dokuwiki_desired_version gespeichert + # https://raymii.org/s/tutorials/Ansible_-_Only-do-something-if-another-action-changed.html + +- name: download latest dokuwiki archive & unarchive to {{ dokuwiki_install_path }} + become: true + ansible.builtin.unarchive: + src: "{{ dokuwiki_download_url }}" + dest: "{{ dokuwiki_install_path }}" + remote_src: true + extra_opts: [--strip-components=1] # entfernt die erste Ebene des Archives + owner: "{{ dokuwiki_user }}" + mode: "0744" + when: + - (dokuwiki_desired_version.changed) or + (not dokuwiki_install_status.stat.exists) + # Dise Variable wird hier abgefragt, so wird das Paket nur heruntergeladen wenn die + # Version Unterschiedlich ist + +- name: Remove default plugins + become: true + ansible.builtin.file: + path: '{{ dokuwiki_install_path }}/lib/plugins/{{ item }}' + state: absent + with_items: + - authpdo + - authmysql + - authpgsql + - authad + +- name: Change file ownership, group and permissions + become: true + ansible.builtin.file: + path: "{{ dokuwiki_install_path }}" + owner: "{{ dokuwiki_user }}" + group: "{{ dokuwiki_group }}" + mode: "0744" + +- name: remove installer + ansible.builtin.file: + path: "{{ dokuwiki_install_path }}/install.php" + state: absent diff --git a/roles/mgrote_dokuwiki/tasks/install.yml b/roles/mgrote_dokuwiki/tasks/install.yml new file mode 100644 index 00000000..0aa794bd --- /dev/null +++ b/roles/mgrote_dokuwiki/tasks/install.yml @@ -0,0 +1,13 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - php + - php-mbstring + - php-xml + - apache2 + - libapache2-mod-php + - php-xml + - php-gd + state: present diff --git a/roles/mgrote_dokuwiki/tasks/main.yml b/roles/mgrote_dokuwiki/tasks/main.yml new file mode 100644 index 00000000..247fb7bd --- /dev/null +++ b/roles/mgrote_dokuwiki/tasks/main.yml @@ -0,0 +1,7 @@ +--- +- name: include install tasks + ansible.builtin.include_tasks: install.yml +- name: include apache2 tasks + ansible.builtin.include_tasks: apache2.yml +- name: include dokuwiki tasks + ansible.builtin.include_tasks: dokuwiki.yml diff --git a/roles/mgrote.dokuwiki/templates/000-default.conf b/roles/mgrote_dokuwiki/templates/000-default.conf similarity index 100% rename from roles/mgrote.dokuwiki/templates/000-default.conf rename to roles/mgrote_dokuwiki/templates/000-default.conf diff --git a/roles/mgrote.dokuwiki/templates/apache2.conf b/roles/mgrote_dokuwiki/templates/apache2.conf similarity index 100% rename from roles/mgrote.dokuwiki/templates/apache2.conf rename to roles/mgrote_dokuwiki/templates/apache2.conf diff --git a/roles/mgrote.dotfiles/README.md b/roles/mgrote_dotfiles/README.md similarity index 100% rename from roles/mgrote.dotfiles/README.md rename to roles/mgrote_dotfiles/README.md diff --git a/roles/mgrote_dotfiles/defaults/main.yml b/roles/mgrote_dotfiles/defaults/main.yml new file mode 100644 index 00000000..aa3594b7 --- /dev/null +++ b/roles/mgrote_dotfiles/defaults/main.yml @@ -0,0 +1,11 @@ +--- +dotfiles_repo_url: https://git.mgrote.net/mg/dotfiles # url zum repo +dotfiles_repo_path: /home/mg/dotfiles # wo soll das repo lokal gespeichert werden +dotfiles_repo_branch: master #default branch for checking out +dotfiles_files: # welche dateien sollen wohin verlinkt werden (ln -s) + - repo_path: "{{ dotfiles_repo_path }}/.vimrc" + local_path: "/home/mg/.vimrc" +dotfiles_dirs: # welche ordner sollen erstellt werden + - path: /home/mg/.config/i3 + - path: /home/mg/.config/polybar +dotfiles_owner: mg # chown diff --git a/roles/mgrote_dotfiles/handlers/main.yml b/roles/mgrote_dotfiles/handlers/main.yml new file mode 100644 index 00000000..ff6002c0 --- /dev/null +++ b/roles/mgrote_dotfiles/handlers/main.yml @@ -0,0 +1,8 @@ +--- +- name: set owner recursive for repo + ansible.builtin.file: + path: "{{ dotfiles_repo_path }}" + owner: "{{ dotfiles_owner }}" + group: "{{ dotfiles_owner }}" + recurse: true +... diff --git a/roles/mgrote_dotfiles/tasks/main.yml b/roles/mgrote_dotfiles/tasks/main.yml new file mode 100644 index 00000000..df3e99fc --- /dev/null +++ b/roles/mgrote_dotfiles/tasks/main.yml @@ -0,0 +1,57 @@ +--- +- name: install acl package + become: true + ansible.builtin.package: + name: acl + state: present + +- name: check if repo exists + ansible.builtin.stat: + path: "{{ dotfiles_repo_path }}" + register: repo_exists + +- name: set safe directory + become: true + ansible.builtin.command: # noqa command-instead-of-module + cmd: git config --global --add safe.directory "{{ dotfiles_repo_path }}" + changed_when: false + +- name: stash changes + ansible.builtin.command: git stash # noqa command-instead-of-module no-handler + args: + chdir: "{{ dotfiles_repo_path }}" + changed_when: false + when: repo_exists.stat.exists + +- name: Ensure dotfiles repository is cloned locally. + ansible.builtin.git: + repo: "{{ dotfiles_repo_url }}" + dest: "{{ dotfiles_repo_path }}" + depth: 1 + version: "{{ dotfiles_repo_branch }}" + notify: set owner recursive for repo + +- name: Ensure needed dirs exist. + ansible.builtin.file: + path: "{{ item.path }}" + state: directory + owner: "{{ dotfiles_owner }}" + group: "{{ dotfiles_owner }}" + mode: "0644" + with_items: "{{ dotfiles_dirs }}" + +- name: Link dotfiles into home folder + ansible.builtin.file: + src: "{{ item.repo_path }}" + dest: "{{ item.local_path }}" + state: link + force: true + owner: "{{ dotfiles_owner }}" + group: "{{ dotfiles_owner }}" + with_items: "{{ dotfiles_files }}" + +- name: add .bash_extra to .bashrc + ansible.builtin.lineinfile: + path: /home/{{ dotfiles_owner }}/.bashrc + line: "source {{ dotfiles_repo_path }}/.bash_extra" + state: present diff --git a/roles/mgrote.exa/README.md b/roles/mgrote_exa/README.md similarity index 100% rename from roles/mgrote.exa/README.md rename to roles/mgrote_exa/README.md diff --git a/roles/mgrote_exa/defaults/main.yml b/roles/mgrote_exa/defaults/main.yml new file mode 100644 index 00000000..75810243 --- /dev/null +++ b/roles/mgrote_exa/defaults/main.yml @@ -0,0 +1,2 @@ +--- +exa_url: https://github.com/ogham/exa/releases/download/v0.10.1/exa-linux-x86_64-v0.10.1.zip diff --git a/roles/mgrote_exa/tasks/main.yml b/roles/mgrote_exa/tasks/main.yml new file mode 100644 index 00000000..9c1833e5 --- /dev/null +++ b/roles/mgrote_exa/tasks/main.yml @@ -0,0 +1,10 @@ +--- +- name: download & extract exa + become: true + ansible.builtin.unarchive: + src: "{{ exa_url }}" + dest: /usr/local/ + remote_src: true + owner: root + group: root + mode: "0755" diff --git a/roles/mgrote.fail2ban/README.md b/roles/mgrote_fail2ban/README.md similarity index 100% rename from roles/mgrote.fail2ban/README.md rename to roles/mgrote_fail2ban/README.md diff --git a/roles/mgrote_fail2ban/defaults/main.yml b/roles/mgrote_fail2ban/defaults/main.yml new file mode 100644 index 00000000..bd8fed0e --- /dev/null +++ b/roles/mgrote_fail2ban/defaults/main.yml @@ -0,0 +1,8 @@ +--- +# Werte in Sekunden +f2b_bantime: 60 +f2b_findtime: 600 +f2b_maxretry: 5 +f2b_destemail: michael.grote@posteo.de +f2b_sender: info@mgrote.net +f2b_send_email_report: true diff --git a/roles/mgrote_fail2ban/handlers/main.yml b/roles/mgrote_fail2ban/handlers/main.yml new file mode 100644 index 00000000..54d4f134 --- /dev/null +++ b/roles/mgrote_fail2ban/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart_f2b + become: true + ansible.builtin.systemd: + name: fail2ban + enabled: true + state: restarted diff --git a/roles/mgrote_fail2ban/tasks/main.yml b/roles/mgrote_fail2ban/tasks/main.yml new file mode 100644 index 00000000..6c119612 --- /dev/null +++ b/roles/mgrote_fail2ban/tasks/main.yml @@ -0,0 +1,22 @@ +--- +- name: install fail2ban-packages + become: true + ansible.builtin.package: + name: fail2ban + state: present + +- name: copy jail.local + become: true + ansible.builtin.template: + src: jail.local + dest: /etc/fail2ban/jail.local + mode: "0750" + notify: restart_f2b + +- name: copy sendmail-common.local + become: true + ansible.builtin.template: + src: sendmail-common.local + dest: /etc/fail2ban/action.d/sendmail-common.local + mode: "0750" + notify: restart_f2b diff --git a/roles/mgrote.fail2ban/templates/jail.local b/roles/mgrote_fail2ban/templates/jail.local similarity index 100% rename from roles/mgrote.fail2ban/templates/jail.local rename to roles/mgrote_fail2ban/templates/jail.local diff --git a/roles/mgrote.fail2ban/templates/sendmail-common.local b/roles/mgrote_fail2ban/templates/sendmail-common.local similarity index 100% rename from roles/mgrote.fail2ban/templates/sendmail-common.local rename to roles/mgrote_fail2ban/templates/sendmail-common.local diff --git a/roles/mgrote.fileserver_smb/README.md b/roles/mgrote_fileserver_smb/README.md similarity index 100% rename from roles/mgrote.fileserver_smb/README.md rename to roles/mgrote_fileserver_smb/README.md diff --git a/roles/mgrote_fileserver_smb/defaults/main.yml b/roles/mgrote_fileserver_smb/defaults/main.yml new file mode 100644 index 00000000..166b4d02 --- /dev/null +++ b/roles/mgrote_fileserver_smb/defaults/main.yml @@ -0,0 +1,107 @@ +--- +# Global SMB options +## "smb_global_options" = dict +## -option: "smbd option name" <-- value +## value: "smbd value" <-- value +## neue Optionen konnen einfach angehangen werden bzw. alte entfernt werden +smb_global_options: + - option: min protocol + value: "SMB2_02" + - option: client min protocol + value: "SMB2_02" + - option: client max protocol + value: "SMB3_00" + - option: log level + value: "1" + - option: log file + value: "/var/log/samba/log" + - option: max log size + value: "1000" + - option: logging + value: "syslog" + - option: panic action + value: "/usr/share/samba/panic-action_%d" + - option: passdb backend + value: "tdbsam" + - option: obey pam restrictions + value: "no" + - option: unix password sync + value: "no" + - option: passwd program + value: "/usr/bin/passwd_%u" + - option: passwd chat + value: '*Enter\snew\s*\spassword:*_%n\n_*Retype\snew\s*\spassword:*_%n\n_*password\supdated\ssuccessfully*_.' + - option: pam password change + value: "yes" + - option: guest account + value: "nobody" + - option: load printers + value: "no" + - option: unix extensions + value: "yes" + - option: wide links + value: "no" + - option: create mask + value: "0777" + - option: directory mask + value: "0777" + - option: map to guest + value: "Bad User" + - option: use sendfile + value: "yes" + - option: aio read size + value: "16384" + - option: aio write size + value: "16384" + - option: local master + value: "yes" + - option: time server + value: "no" + - option: wins support + value: "no" + - option: acl allow execute always + value: "yes" + - option: force user + value: "root" + - option: force group + value: "users" + - option: workgroup + value: WORKGROUP + - option: server string + value: "%h_server" + +# packages +smb_packages: + - samba + - cifs-utils + - samba-common + - samba-common-bin + - samba-vfs-modules + +# zfs-snapshots einbinden +## als \.zfs\snapshot einbinden +## sorgt dafur das statt "A0KDC9~F" die Ordnernamen als "autosnap_2021-11-04_23÷59÷02_daily" angezeigt werden +## https://www.samba.org/samba/docs/current/man-html/vfs_catia.8.html +# aktiv? +smb_enable_snapshots_dir: true +# welche Character/zeichen-Ersetzungen soll catia ausführen +smb_catia_mappings: "0x3a:0xf7" # ersetzt ":" durch "÷" + +# als Windows-Shattenkopien einbinden +## https://www.samba.org/samba/docs/current/man-html/vfs_shadow_copy2.8.html +## BUG: Windows sieht die Schattenkopien, kann die Ausgewählte Datei aber nicht öffnen wenn sie seit dem Snapshot gelöscht wurde, vmtl da Windows nicht den kompletten Snapshot-Pfad verwendet +## Format ist passend fur sanoid-Snapshots +# aktiv? +smb_enable_snapshots_shadow: false +# wo liegen die Snapshots +smb_shadow_snapdir: ".zfs/snapshot" +# Sortierung +smb_shadow_sort: "desc" +# Datumsformat der Snapshots +smb_shadow_format: "_%Y-%m-%d_%H:%M:%S" +# Snapshot-Präfix +smb_shadow_snapprefix: "^autosnap" +# Snapshot-"Trenner" +smb_shadow_delimiter: "_" +# zeitformat Snapshots +smb_shadow_localtime: "no" diff --git a/roles/mgrote_fileserver_smb/handlers/main.yml b/roles/mgrote_fileserver_smb/handlers/main.yml new file mode 100644 index 00000000..d73e894c --- /dev/null +++ b/roles/mgrote_fileserver_smb/handlers/main.yml @@ -0,0 +1,15 @@ +--- +- name: restart smbd + become: true + ansible.builtin.systemd: + name: smbd + enabled: true + state: restarted + +- name: set samba passwords + become: true + ansible.builtin.shell: "printf '{{ item.password }}\n{{ item.password }}\n' | smbpasswd -a {{ item.name }}" # noqa no-changed-when risky-shell-pipe + #pipefail: https://blog.christophersmart.com/2019/09/28/using-pipefail-with-shell-module-in-ansible/ + with_items: + - "{{ smb_users }}" + no_log: true diff --git a/roles/mgrote_fileserver_smb/tasks/main.yml b/roles/mgrote_fileserver_smb/tasks/main.yml new file mode 100644 index 00000000..6efeb2da --- /dev/null +++ b/roles/mgrote_fileserver_smb/tasks/main.yml @@ -0,0 +1,11 @@ +--- +- name: include install tasks + ansible.builtin.include_tasks: packages.yml + +- name: include user tasks + ansible.builtin.include_tasks: users.yml + when: smb_users is defined + +- name: include share tasks + ansible.builtin.include_tasks: shares.yml + when: smb_shares is defined diff --git a/roles/mgrote_fileserver_smb/tasks/packages.yml b/roles/mgrote_fileserver_smb/tasks/packages.yml new file mode 100644 index 00000000..b518abba --- /dev/null +++ b/roles/mgrote_fileserver_smb/tasks/packages.yml @@ -0,0 +1,6 @@ +--- +- name: ensure packages are installed + become: true + ansible.builtin.package: + name: "{{ smb_packages }}" + state: present diff --git a/roles/mgrote_fileserver_smb/tasks/shares.yml b/roles/mgrote_fileserver_smb/tasks/shares.yml new file mode 100644 index 00000000..13e777e0 --- /dev/null +++ b/roles/mgrote_fileserver_smb/tasks/shares.yml @@ -0,0 +1,24 @@ +--- +- name: ensure smb share directories exist + become: true + ansible.builtin.file: + path: "{{ item.path }}" + state: directory + mode: "0777" + loop: "{{ smb_shares }}" + notify: set samba passwords + +- name: template share configuration + become: true + ansible.builtin.template: + src: smb.conf.j2 + dest: /etc/samba/smb.conf + validate: 'testparm -s %s' + mode: "0644" + owner: root + group: root + with_items: + - "{{ smb_shares }}" + notify: + - restart smbd + - set samba passwords diff --git a/roles/mgrote_fileserver_smb/tasks/users.yml b/roles/mgrote_fileserver_smb/tasks/users.yml new file mode 100644 index 00000000..2dafe2be --- /dev/null +++ b/roles/mgrote_fileserver_smb/tasks/users.yml @@ -0,0 +1,18 @@ +--- +- name: ensure group exist + become: true + ansible.builtin.group: + name: smb_users + state: present + +- name: configure linux-users + become: true + ansible.builtin.user: + name: "{{ item.name }}" + group: smb_users + state: "{{ item.state | default('present') }}" + remove: "{{ item.remove_dir | default('false') }}" + create_home: false + loop: "{{ smb_users }}" + no_log: true + notify: set samba passwords diff --git a/roles/mgrote.fileserver_smb/templates/smb.conf.j2 b/roles/mgrote_fileserver_smb/templates/smb.conf.j2 similarity index 100% rename from roles/mgrote.fileserver_smb/templates/smb.conf.j2 rename to roles/mgrote_fileserver_smb/templates/smb.conf.j2 diff --git a/roles/mgrote.fluxcd/README.md b/roles/mgrote_fluxcd/README.md similarity index 100% rename from roles/mgrote.fluxcd/README.md rename to roles/mgrote_fluxcd/README.md diff --git a/roles/mgrote_fluxcd/defaults/main.yml b/roles/mgrote_fluxcd/defaults/main.yml new file mode 100644 index 00000000..3625d9fc --- /dev/null +++ b/roles/mgrote_fluxcd/defaults/main.yml @@ -0,0 +1,16 @@ +--- +flux_repo_host: gitea.grote.lan +flux_repo_host_port: 2222 +flux_repo_branch: master +flux_repo_url_complete: "ssh://gitea@{{ flux_repo_host }}:{{ flux_repo_host_port }}/mg/manifests.git" +flux_install_host: k3s1.grote.lan +flux_homedir: /home/flux +flux_path_ssh_dir: /home/flux/.ssh +flux_user_group: flux +flux_user: flux +flux_download_url: https://github.com/fluxcd/flux2/releases/download/v0.35.0/flux_0.35.0_linux_amd64.tar.gz +flux_path_bin: /usr/local/sbin +flux_path_ssh_id_file: id_rsa +flux_ssh_key_format: ed25519 +kubeconfig: /etc/rancher/k3s/k3s.yaml +flux_sync_interval: 1m diff --git a/roles/mgrote_fluxcd/handlers/main.yml b/roles/mgrote_fluxcd/handlers/main.yml new file mode 100644 index 00000000..5c940470 --- /dev/null +++ b/roles/mgrote_fluxcd/handlers/main.yml @@ -0,0 +1,6 @@ +--- +- name: flux install + ansible.builtin.command: "{{ flux_homedir }}/bootstrap.sh" # noqa no-changed-when + become_user: "{{ flux_user }}" + become: true +... diff --git a/roles/mgrote_fluxcd/tasks/main.yml b/roles/mgrote_fluxcd/tasks/main.yml new file mode 100644 index 00000000..d8379aef --- /dev/null +++ b/roles/mgrote_fluxcd/tasks/main.yml @@ -0,0 +1,93 @@ +--- +- name: include user tasks + ansible.builtin.include_tasks: user.yml + +- name: check if flux is installed + ansible.builtin.command: which flux + changed_when: false + failed_when: flux_installed.rc not in [0,1] + register: flux_installed + +- name: download flux binary + ansible.builtin.unarchive: + src: "{{ flux_download_url }}" + dest: "{{ flux_path_bin }}" + mode: "0755" + owner: "{{ flux_user }}" + group: "{{ flux_user_group }}" + remote_src: true + creates: "{{ flux_path_bin }}/flux" + when: flux_installed.rc not in [ 0 ] + +- name: install bash-completion packages + become: true + ansible.builtin.package: + name: bash-completion + state: present + +- name: activate autocompletion for flux + become: true + ansible.builtin.shell: + cmd: "set -o pipefail && flux completion bash | sudo tee /etc/bash_completion.d/flux" + executable: /bin/bash + args: + creates: /etc/bash_completion.d/flux + +- name: install flux + # der ganze block nur auf einem host + run_once: true + when: ansible_host == flux_install_host + block: + - name: ensure .ssh directory exists + ansible.builtin.file: + path: "{{ flux_path_ssh_dir }}" + owner: "{{ flux_user }}" + group: "{{ flux_user_group }}" + mode: "0400" + state: directory + + - name: check if OpenSSH keypair exists + ansible.builtin.stat: + path: "{{ flux_path_ssh_dir }}/{{ flux_path_ssh_id_file }}" + register: ssh_exist + + - name: generate SSH keypair + community.crypto.openssh_keypair: + path: "{{ flux_path_ssh_dir }}/{{ flux_path_ssh_id_file }}" + owner: "{{ flux_user }}" + group: "{{ flux_user_group }}" + mode: "0400" + type: "{{ flux_ssh_key_format }}" + when: not ssh_exist.stat.exists + register: create_ssh_key + + - name: get publickey + ansible.builtin.command: cat "{{ flux_path_ssh_dir }}/{{ flux_path_ssh_id_file }}.pub" # noqa no-handler no-changed-when + when: create_ssh_key.changed + register: ssh_public_key + + - name: show publickey # noqa no-handler + ansible.builtin.debug: + msg: "{{ ssh_public_key.stdout }}" + when: create_ssh_key.changed + + - name: copy publickey to gitea as deploy-key WITH write-permissions! # noqa no-handler no-changed-when + ansible.builtin.pause: + prompt: "Make sure the key is saved!" + when: create_ssh_key.changed + + - name: set permissions for $kubeconfig + ansible.builtin.file: + path: "{{ kubeconfig }}" + owner: root + group: root + mode: "0640" + + - name: template bootstrap script + ansible.builtin.template: + src: bootstrap.sh + dest: "{{ flux_homedir }}/bootstrap.sh" + mode: "0544" + owner: "{{ flux_user }}" + group: "{{ flux_user_group }}" + notify: flux install diff --git a/roles/mgrote_fluxcd/tasks/user.yml b/roles/mgrote_fluxcd/tasks/user.yml new file mode 100644 index 00000000..656fd69f --- /dev/null +++ b/roles/mgrote_fluxcd/tasks/user.yml @@ -0,0 +1,18 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ flux_user_group }}" + state: present + when: + - flux_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ flux_user }}" + group: "{{ flux_user_group }}" + create_home: false + when: + - flux_user_group is defined + - flux_user is defined diff --git a/roles/mgrote.fluxcd/templates/bootstrap.sh b/roles/mgrote_fluxcd/templates/bootstrap.sh similarity index 100% rename from roles/mgrote.fluxcd/templates/bootstrap.sh rename to roles/mgrote_fluxcd/templates/bootstrap.sh diff --git a/roles/mgrote.fwupd_settings/README.md b/roles/mgrote_fwupd_settings/README.md similarity index 100% rename from roles/mgrote.fwupd_settings/README.md rename to roles/mgrote_fwupd_settings/README.md diff --git a/roles/mgrote_fwupd_settings/defaults/main.yml b/roles/mgrote_fwupd_settings/defaults/main.yml new file mode 100644 index 00000000..57b98e89 --- /dev/null +++ b/roles/mgrote_fwupd_settings/defaults/main.yml @@ -0,0 +1,2 @@ +--- +fwupd_dynamic_user: false diff --git a/roles/mgrote_fwupd_settings/handlers/main.yml b/roles/mgrote_fwupd_settings/handlers/main.yml new file mode 100644 index 00000000..efd7dfbc --- /dev/null +++ b/roles/mgrote_fwupd_settings/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + state: restarted + daemon_reload: true + name: fwupd-refresh.service diff --git a/roles/mgrote_fwupd_settings/tasks/main.yml b/roles/mgrote_fwupd_settings/tasks/main.yml new file mode 100644 index 00000000..04a428e5 --- /dev/null +++ b/roles/mgrote_fwupd_settings/tasks/main.yml @@ -0,0 +1,17 @@ +--- +- name: gather service facts + ansible.builtin.service_facts: + +- name: set DynamicUser=no + ansible.builtin.blockinfile: + path: /etc/systemd/system/fwupd-refresh.service.d/override.conf + block: | + [Service] + DynamicUser=no + create: true + mode: "0644" + owner: root + group: root + when: + - "not fwupd_dynamic_user and 'fwupd-refresh.service' in services" + notify: systemctl daemon-reload diff --git a/roles/mgrote.k8s_autocompletion/README.md b/roles/mgrote_k8s_autocompletion/README.md similarity index 100% rename from roles/mgrote.k8s_autocompletion/README.md rename to roles/mgrote_k8s_autocompletion/README.md diff --git a/roles/mgrote_k8s_autocompletion/tasks/main.yml b/roles/mgrote_k8s_autocompletion/tasks/main.yml new file mode 100644 index 00000000..f170ab0d --- /dev/null +++ b/roles/mgrote_k8s_autocompletion/tasks/main.yml @@ -0,0 +1,14 @@ +--- +- name: install bash-completion packages + become: true + ansible.builtin.package: + name: bash-completion + state: present + +- name: activate autocompletion for kubectl + become: true + ansible.builtin.shell: + cmd: "set -o pipefail && kubectl completion bash | sudo tee /etc/bash_completion.d/kubectl" + executable: /bin/bash + args: + creates: /etc/bash_completion.d/kubectl diff --git a/roles/mgrote.k8s_misc/README.md b/roles/mgrote_k8s_misc/README.md similarity index 100% rename from roles/mgrote.k8s_misc/README.md rename to roles/mgrote_k8s_misc/README.md diff --git a/roles/mgrote_k8s_misc/tasks/main.yml b/roles/mgrote_k8s_misc/tasks/main.yml new file mode 100644 index 00000000..5a8d2cc4 --- /dev/null +++ b/roles/mgrote_k8s_misc/tasks/main.yml @@ -0,0 +1,7 @@ +--- +- name: set $KUBECONFIG for root + ansible.builtin.blockinfile: + path: /root/.bashrc + block: | + export KUBECONFIG=/etc/rancher/k3s/k3s.yaml + marker: "# {mark} ANSIBLE MANAGED BLOCK - K3S" diff --git a/roles/mgrote.mount_cifs/README.md b/roles/mgrote_mount_cifs/README.md similarity index 100% rename from roles/mgrote.mount_cifs/README.md rename to roles/mgrote_mount_cifs/README.md diff --git a/roles/mgrote_mount_cifs/defaults/main.yml b/roles/mgrote_mount_cifs/defaults/main.yml new file mode 100644 index 00000000..b43d1b55 --- /dev/null +++ b/roles/mgrote_mount_cifs/defaults/main.yml @@ -0,0 +1,12 @@ +--- +cifs_mounts: + - name: pve_backup_mount_fileserver3 + type: cifs + state: absent + dest: /pve_backup_mount + src: //fileserver3.grote.lan/proxmox + user: pve + password: XXXXXXXXXXXXXXX + domain: grote.lan + uid: 1000 + gid: 1000 diff --git a/roles/mgrote_mount_cifs/handlers/main.yml b/roles/mgrote_mount_cifs/handlers/main.yml new file mode 100644 index 00000000..c22b27fb --- /dev/null +++ b/roles/mgrote_mount_cifs/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: reboot + become: true + ansible.builtin.reboot: + reboot_timeout: 120 diff --git a/roles/mgrote_mount_cifs/meta/main.yml b/roles/mgrote_mount_cifs/meta/main.yml new file mode 100644 index 00000000..ad6b4c77 --- /dev/null +++ b/roles/mgrote_mount_cifs/meta/main.yml @@ -0,0 +1,3 @@ +--- +collections: + - ansible.posix diff --git a/roles/mgrote_mount_cifs/tasks/main.yml b/roles/mgrote_mount_cifs/tasks/main.yml new file mode 100644 index 00000000..3b8fa820 --- /dev/null +++ b/roles/mgrote_mount_cifs/tasks/main.yml @@ -0,0 +1,41 @@ +--- +- name: install cifs-utils + become: true + ansible.builtin.package: + name: cifs-utils + state: present + +- name: create mount directory + become: true + ansible.builtin.file: + path: "{{ item.dest }}" + state: directory + mode: "0777" + loop: "{{ cifs_mounts }}" + no_log: true + +- name: create credential-file + become: true + ansible.builtin.template: + src: smb_passwords + dest: /root/.smb_passwords_{{ item.name }} + owner: root + group: root + mode: '0400' + loop: "{{ cifs_mounts }}" + no_log: true + +- name: mount cifs volumes + become: true + ansible.posix.mount: + src: "{{ item.src }}" + path: "{{ item.dest }}" + opts: credentials=/root/.smb_passwords_{{ item.name }},domain={{ item.domain }},uid={{ item.uid | default('1000') }},gid={{ item.gid | default('1000') }}" + state: "{{ item.state }}" + fstype: "{{ item.type }}" + backup: true + dump: "0" + passno: "0" + loop: "{{ cifs_mounts }}" + no_log: true + notify: reboot diff --git a/roles/mgrote.mount_cifs/templates/smb_passwords b/roles/mgrote_mount_cifs/templates/smb_passwords similarity index 100% rename from roles/mgrote.mount_cifs/templates/smb_passwords rename to roles/mgrote_mount_cifs/templates/smb_passwords diff --git a/roles/mgrote.ntp_chrony_client/README.md b/roles/mgrote_ntp_chrony_client/README.md similarity index 100% rename from roles/mgrote.ntp_chrony_client/README.md rename to roles/mgrote_ntp_chrony_client/README.md diff --git a/roles/mgrote_ntp_chrony_client/defaults/main.yml b/roles/mgrote_ntp_chrony_client/defaults/main.yml new file mode 100644 index 00000000..6024d99a --- /dev/null +++ b/roles/mgrote_ntp_chrony_client/defaults/main.yml @@ -0,0 +1,9 @@ +--- +ntp_chrony_timezone: "Europe/Berlin" # Zeitzone in der sich der Computer befindet +ntp_chrony_driftfile_directory: "/var/lib/chrony" # Ordner für das driftfile +ntp_chrony_servers: # welche Server sollen befragt werden + - address: ptbtime1.ptb.de + options: iburst #optionaler parameter +ntp_chrony_user: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_group: _chrony # Nutzer + Gruppe für den Dienst +ntp_chrony_logging: false diff --git a/roles/mgrote_ntp_chrony_client/handlers/main.yml b/roles/mgrote_ntp_chrony_client/handlers/main.yml new file mode 100644 index 00000000..e8e46322 --- /dev/null +++ b/roles/mgrote_ntp_chrony_client/handlers/main.yml @@ -0,0 +1,8 @@ +--- +- name: restart_chrony + become: true + ansible.builtin.systemd: + name: chrony + enabled: true + masked: false + state: restarted diff --git a/roles/mgrote_ntp_chrony_client/tasks/main.yml b/roles/mgrote_ntp_chrony_client/tasks/main.yml new file mode 100644 index 00000000..f3e405dc --- /dev/null +++ b/roles/mgrote_ntp_chrony_client/tasks/main.yml @@ -0,0 +1,69 @@ +--- +- name: Check systemd-timesyncd status # noqa command-instead-of-module + become: true + ansible.builtin.shell: + cmd: "set -o pipefail && systemctl is-active --quiet systemd-timesyncd && echo Active || echo Inactive" + executable: /bin/bash + register: timesyncd_status + changed_when: false + +- name: Disable systemd-timesyncd + become: true + ansible.builtin.systemd: + name: systemd-timesyncd + masked: true + state: stopped + when: timesyncd_status.stdout == "Active" + +- name: gather package facts + become: true + ansible.builtin.package_facts: + manager: auto + +- name: stop and mask ntp service + become: true + ansible.builtin.systemd: + name: ntp + masked: true + state: stopped + when: "'ntp' in ansible_facts.packages" + +- name: install chrony packages + become: true + ansible.builtin.package: + name: + - chrony + state: present + notify: restart_chrony + +- name: copy chrony config + become: true + ansible.builtin.template: + src: chrony.conf.j2 + dest: /etc/chrony/chrony.conf + mode: "0755" + notify: restart_chrony + +- name: copy logrotate config + become: true + ansible.builtin.template: + src: logrotate_chrony + dest: /etc/logrotate.d/chrony + owner: root + group: root + mode: "0644" + +- name: Create chrony driftfile folder + become: true + ansible.builtin.file: + state: directory + path: "{{ ntp_chrony_driftfile_directory }}" + mode: "0750" + owner: "{{ ntp_chrony_user }}" + group: "{{ ntp_chrony_group }}" + notify: restart_chrony + +- name: set timezone to {{ ntp_chrony_timezone }} + become: true + community.general.timezone: + name: "{{ ntp_chrony_timezone }}" diff --git a/roles/mgrote.ntp_chrony_client/templates/chrony.conf.j2 b/roles/mgrote_ntp_chrony_client/templates/chrony.conf.j2 similarity index 100% rename from roles/mgrote.ntp_chrony_client/templates/chrony.conf.j2 rename to roles/mgrote_ntp_chrony_client/templates/chrony.conf.j2 diff --git a/roles/mgrote_ntp_chrony_client/templates/logrotate_chrony b/roles/mgrote_ntp_chrony_client/templates/logrotate_chrony new file mode 100644 index 00000000..86e0c1f6 --- /dev/null +++ b/roles/mgrote_ntp_chrony_client/templates/logrotate_chrony @@ -0,0 +1,16 @@ +{{ file_header | default () }} +/var/log/chrony/*.log { + missingok + nocreate + rotate 4 + weekly + compress + missingok + notifempty + dateext + dateyesterday + sharedscripts + postrotate + /usr/bin/chronyc cyclelogs > /dev/null 2>&1 || true + endscript +} diff --git a/roles/mgrote.pbs_datastores/defaults/main.yml b/roles/mgrote_pbs_datastores/defaults/main.yml similarity index 100% rename from roles/mgrote.pbs_datastores/defaults/main.yml rename to roles/mgrote_pbs_datastores/defaults/main.yml diff --git a/roles/mgrote_pbs_datastores/tasks/main.yml b/roles/mgrote_pbs_datastores/tasks/main.yml new file mode 100644 index 00000000..0c787c4b --- /dev/null +++ b/roles/mgrote_pbs_datastores/tasks/main.yml @@ -0,0 +1,42 @@ +--- +- name: check if datastores exist # noqa no-changed-when + become: true + ansible.builtin.command: "proxmox-backup-manager datastore list --output-format json" + register: datastores + changed_when: false + +- name: ensure datastores exist # noqa no-changed-when + become: true + ansible.builtin.command: "proxmox-backup-manager datastore create {{ item.name }} {{ item.path }}" + loop: "{{ pbs_datastores }}" + when: "item.name not in datastores.stdout" + +- name: ensure datastores are configured + become: true + ansible.builtin.template: + src: datastores.j2 + dest: /etc/proxmox-backup/datastore.cfg + owner: root + group: backup + mode: "0640" + backup: true + +- name: ensure prune-jobs are configured + become: true + ansible.builtin.template: + src: prune-jobs.j2 + dest: /etc/proxmox-backup/prune.cfg + owner: root + group: backup + mode: "0640" + backup: true + +- name: ensure permissions are configured + become: true + ansible.builtin.template: + src: permissions.j2 + dest: /etc/proxmox-backup/acl.cfg + owner: root + group: backup + mode: "0640" + backup: true diff --git a/roles/mgrote.pbs_datastores/templates/datastores.j2 b/roles/mgrote_pbs_datastores/templates/datastores.j2 similarity index 100% rename from roles/mgrote.pbs_datastores/templates/datastores.j2 rename to roles/mgrote_pbs_datastores/templates/datastores.j2 diff --git a/roles/mgrote.pbs_datastores/templates/permissions.j2 b/roles/mgrote_pbs_datastores/templates/permissions.j2 similarity index 100% rename from roles/mgrote.pbs_datastores/templates/permissions.j2 rename to roles/mgrote_pbs_datastores/templates/permissions.j2 diff --git a/roles/mgrote.pbs_datastores/templates/prune-jobs.j2 b/roles/mgrote_pbs_datastores/templates/prune-jobs.j2 similarity index 100% rename from roles/mgrote.pbs_datastores/templates/prune-jobs.j2 rename to roles/mgrote_pbs_datastores/templates/prune-jobs.j2 diff --git a/roles/mgrote.pbs_pve_integration/defaults/main.yml b/roles/mgrote_pbs_pve_integration/defaults/main.yml similarity index 100% rename from roles/mgrote.pbs_pve_integration/defaults/main.yml rename to roles/mgrote_pbs_pve_integration/defaults/main.yml diff --git a/roles/mgrote_pbs_pve_integration/tasks/main.yml b/roles/mgrote_pbs_pve_integration/tasks/main.yml new file mode 100644 index 00000000..92c7b719 --- /dev/null +++ b/roles/mgrote_pbs_pve_integration/tasks/main.yml @@ -0,0 +1,21 @@ +--- +- name: check which storages exists + become: true + ansible.builtin.shell: + cmd: "set -o pipefail && pvesm status | awk '{ print $1}'" + executable: /bin/bash + register: storages + changed_when: false + +- name: ensure datastore exist # noqa no-changed-when + become: true + ansible.builtin.command: "pvesm add pbs {{ item.name }} --server {{ item.server }} --datastore {{ item.datastore }} --username {{ item.username }} --password {{ item.password }} --fingerprint {{ item.fingerprint }}" + loop: "{{ pve_pbs_datastore }}" + when: "item.name not in storages.stdout" + +- name: ensure datastore is configured + become: true + ansible.builtin.command: "pvesm set {{ item.name }} --username {{ item.username }} --password {{ item.password }}" + loop: "{{ pve_pbs_datastore }}" + when: "item.name in storages.stdout" + changed_when: false diff --git a/roles/mgrote.pbs_users/defaults/main.yml b/roles/mgrote_pbs_users/defaults/main.yml similarity index 100% rename from roles/mgrote.pbs_users/defaults/main.yml rename to roles/mgrote_pbs_users/defaults/main.yml diff --git a/roles/mgrote_pbs_users/tasks/main.yml b/roles/mgrote_pbs_users/tasks/main.yml new file mode 100644 index 00000000..b92b30a6 --- /dev/null +++ b/roles/mgrote_pbs_users/tasks/main.yml @@ -0,0 +1,26 @@ +--- +- name: check which users exist + become: true + ansible.builtin.command: "proxmox-backup-manager user list --output-format json" + register: users + changed_when: false + +- name: ensure users exist # noqa no-changed-when + become: true + ansible.builtin.command: "proxmox-backup-manager user create {{ item.name }}@{{ item.realm }}" + loop: "{{ pbs_users }}" + when: "item.name not in users.stdout" + +- name: check again which users exist + become: true + ansible.builtin.command: "proxmox-backup-manager user list --output-format json" + register: users + changed_when: false + +- name: ensure user password + become: true + ansible.builtin.command: "proxmox-backup-manager user update {{ item.name }}@{{ item.realm }} --password {{ item.password }} --expire 0" + loop: "{{ pbs_users }}" + when: "item.name in users.stdout" + changed_when: false + no_log: true diff --git a/roles/mgrote.postfix/README.md b/roles/mgrote_postfix/README.md similarity index 100% rename from roles/mgrote.postfix/README.md rename to roles/mgrote_postfix/README.md diff --git a/roles/mgrote_postfix/defaults/main.yml b/roles/mgrote_postfix/defaults/main.yml new file mode 100644 index 00000000..44404ee6 --- /dev/null +++ b/roles/mgrote_postfix/defaults/main.yml @@ -0,0 +1,12 @@ +--- +postfix_mail_nach_cronjob: false +postfix_erlaubte_netzwerke: "127.0.0.0/8 192.168.2.0/24" +postfix_smtp_server: smtp.strato.de +postfix_smtp_server_port: 587 +postfix_absender_mailadresse: info@mgrote.net +postfix_absender_passwort: "{{ lookup('keepass', 'postfix_absender_passwort', 'password') }}" +postfix_smtp_use_tls: "yes" +postfix_smtp_sasl_auth_enable: "yes" +postfix_smtp_tls_session_cache_timeout: 3600s +postfix_inet_protocols: ipv4 +postfix_append_dot_mydomain: "no" diff --git a/roles/mgrote_postfix/handlers/main.yml b/roles/mgrote_postfix/handlers/main.yml new file mode 100644 index 00000000..08235cdb --- /dev/null +++ b/roles/mgrote_postfix/handlers/main.yml @@ -0,0 +1,21 @@ +--- +- name: hash_sasl_passwd # noqa no-changed-when + become: true + ansible.builtin.command: /usr/sbin/postmap hash:/etc/postfix/sasl_passwd + +- name: hash_sender_canonical # noqa no-changed-when + become: true + ansible.builtin.command: /usr/sbin/postmap hash:/etc/postfix/sender_canonical + +- name: postfix_reload + become: true + ansible.builtin.systemd: + name: postfix + enabled: true + state: restarted + notify: postfix_testmail + +- name: postfix_testmail # noqa no-changed-when + ansible.builtin.shell: + cmd: "set -o pipefail && echo 'postfix ist eingerichtet' | mail -s '{{ ansible_hostname }} - postfix' {{ empfaenger_mail }}" + executable: /bin/bash diff --git a/roles/mgrote_postfix/tasks/main.yml b/roles/mgrote_postfix/tasks/main.yml new file mode 100644 index 00000000..16b81dd6 --- /dev/null +++ b/roles/mgrote_postfix/tasks/main.yml @@ -0,0 +1,66 @@ +--- +### postfix fuer gmail; http://dokuwiki2.grote.lan/artikel/technik/postfix_mit_gmail_fuer_benachrichtigungen_einrichten +- name: postfix + Hilfsprogramme installieren + become: true + ansible.builtin.package: + name: + - postfix + - mailutils + - libsasl2-modules + state: present + +- name: kopiere sasl_passwd + become: true + ansible.builtin.template: + src: sasl_passwd + dest: /etc/postfix/sasl_passwd + force: true + owner: root + group: root + mode: "0644" + notify: + - hash_sasl_passwd + - postfix_testmail + +- name: kopiere sender_canonical + become: true + ansible.builtin.template: + src: sender_canonical + dest: /etc/postfix/sender_canonical + owner: root + group: root + mode: "0644" + notify: + - hash_sender_canonical + - postfix_reload + - postfix_testmail + +- name: kopiere postfix_main.cf + become: true + ansible.builtin.template: + src: main.cf + dest: /etc/postfix/main.cf + owner: root + group: root + mode: "0644" + notify: + - postfix_reload + - postfix_testmail + +- name: Mail Cronjob - Anlegen + become: true + when: postfix_mail_nach_cronjob # ohne parameter wird auf true geprueft https://www.buildahomelab.com/2018/11/12/using-ansible-when-statements/ + ansible.builtin.cron: + name: MAILTO + env: true + job: "{{ empfaenger_mail }}" + notify: + - postfix_testmail + +- name: Mail Cronjob - Entfernen + become: true + when: not postfix_mail_nach_cronjob + ansible.builtin.cron: + name: MAILTO + env: true + job: "" diff --git a/roles/mgrote.postfix/templates/main.cf b/roles/mgrote_postfix/templates/main.cf similarity index 100% rename from roles/mgrote.postfix/templates/main.cf rename to roles/mgrote_postfix/templates/main.cf diff --git a/roles/mgrote.postfix/templates/sasl_passwd b/roles/mgrote_postfix/templates/sasl_passwd similarity index 100% rename from roles/mgrote.postfix/templates/sasl_passwd rename to roles/mgrote_postfix/templates/sasl_passwd diff --git a/roles/mgrote.postfix/templates/sender_canonical b/roles/mgrote_postfix/templates/sender_canonical similarity index 100% rename from roles/mgrote.postfix/templates/sender_canonical rename to roles/mgrote_postfix/templates/sender_canonical diff --git a/roles/mgrote.proxmox_bind_mounts/README.md b/roles/mgrote_proxmox_bind_mounts/README.md similarity index 93% rename from roles/mgrote.proxmox_bind_mounts/README.md rename to roles/mgrote_proxmox_bind_mounts/README.md index 854efe9c..97c3f7df 100644 --- a/roles/mgrote.proxmox_bind_mounts/README.md +++ b/roles/mgrote_proxmox_bind_mounts/README.md @@ -8,7 +8,7 @@ Adds [bind-mounts](https://pve.proxmox.com/wiki/Linux_Container#pct_container_st ### Variablen + Defaults ``` -pve_bind_mounts: # Dictionary +pve_bind_mounts: # Dictionary - vmid: 105 # VMID for which the bind-mount should get created mp_nr: 1 # Number of the mountpoint mp_path_host: /rpool/test # Path on the Host diff --git a/roles/mgrote_proxmox_bind_mounts/defaults/main.yml b/roles/mgrote_proxmox_bind_mounts/defaults/main.yml new file mode 100644 index 00000000..232920a2 --- /dev/null +++ b/roles/mgrote_proxmox_bind_mounts/defaults/main.yml @@ -0,0 +1,3 @@ +--- +lists_merged: # Liste muss leer existieren damit sie "germerged" werden kann, für Liste welche VMs zu rebooten sind + - '' diff --git a/roles/mgrote_proxmox_bind_mounts/handlers/main.yml b/roles/mgrote_proxmox_bind_mounts/handlers/main.yml new file mode 100644 index 00000000..d41e4aef --- /dev/null +++ b/roles/mgrote_proxmox_bind_mounts/handlers/main.yml @@ -0,0 +1,11 @@ +--- +- name: restart lxc # noqa no-changed-when + become: true + ansible.builtin.command: "pct reboot {{ item }}" + failed_when: false + loop: "{{ lists_merged | unique }}" + # reboote den lxc wenn: + # - er in der Liste "Lists merged" vorhanden ist + # unique Filter sorgt dafür das es keine doppelten Elemente gibt + # https://docs.ansible.com/ansible/latest/user_guide/playbooks_filters.html#set-theory-filters + # https://www.reddit.com/r/ansible/comments/8cp86c/how_do_i_remove_duplicate_items_from_a_variable/ diff --git a/roles/mgrote_proxmox_bind_mounts/tasks/bm.yml b/roles/mgrote_proxmox_bind_mounts/tasks/bm.yml new file mode 100644 index 00000000..777c14de --- /dev/null +++ b/roles/mgrote_proxmox_bind_mounts/tasks/bm.yml @@ -0,0 +1,48 @@ +--- +- name: read config + become: true + ansible.builtin.shell: + cmd: "set -o pipefail && pct config {{ item.vmid }} | grep \"mp{{ item.mp_nr }}: {{ item.mp_path_host }},mp={{ item.mp_path_guest }}\"" + executable: /bin/bash + register: config + changed_when: false + failed_when: false + # prüfe ob bind mount schon vorhanden ist + # exit-code wird unten geprüft + +# - name: debug config +# ansible.builtin.debug: +# msg: "{{ config }}" + +- name: add bind mounts to container # noqa no-changed-when + become: true + ansible.builtin.command: "pct set {{ item.vmid }} -mp{{ item.mp_nr }} {{ item.mp_path_host }},mp={{ item.mp_path_guest }}" + register: restart + notify: restart lxc + # füge bind-mount hinzu falls er fehlt, also rc ungleich 0 + # pro bind-mount + when: + - not ansible_check_mode + - not config.rc == 0 + # überspringe wenn in check-mode + + # schreibe vm id in die Liste "reboot" +- name: set reboot list # noqa no-handler var-naming[pattern] + ansible.builtin.set_fact: + ansible.builtin.reboot: + - "{{ item.vmid }}" + when: restart.changed + + # Füge die leere Liste "lists_merged" aus den defaults, mit der Liste "reboot" zusammen. Nur wenn auch etwas geändert wurde, daher "when:..." +- name: merge reboot lists # noqa no-handler + ansible.builtin.set_fact: + lists_merged: "{{ lists_merged + reboot }}" + when: restart.changed + # https://blog.crisp.se/2016/10/20/maxwenzin/how-to-append-to-lists-in-ansible + +# - name: debug config +# ansible.builtin.debug: +# msg: "{{ lists_merged | unique }}" + # unique Filter sorgt dafür das es keine doppelten Elemente gibt + # https://docs.ansible.com/ansible/latest/user_guide/playbooks_filters.html#set-theory-filters + # https://www.reddit.com/r/ansible/comments/8cp86c/how_do_i_remove_duplicate_items_from_a_variable/ diff --git a/roles/mgrote_proxmox_bind_mounts/tasks/main.yml b/roles/mgrote_proxmox_bind_mounts/tasks/main.yml new file mode 100644 index 00000000..30d14877 --- /dev/null +++ b/roles/mgrote_proxmox_bind_mounts/tasks/main.yml @@ -0,0 +1,7 @@ +--- +- name: loop tasks + ansible.builtin.include_tasks: bm.yml + loop: "{{ pve_bind_mounts }}" + when: + - pve_bind_mounts is defined + # Loope durch jeden bind-mount diff --git a/roles/mgrote.proxmox_lxc_profiles/README.md b/roles/mgrote_proxmox_lxc_profiles/README.md similarity index 93% rename from roles/mgrote.proxmox_lxc_profiles/README.md rename to roles/mgrote_proxmox_lxc_profiles/README.md index 854efe9c..97c3f7df 100644 --- a/roles/mgrote.proxmox_lxc_profiles/README.md +++ b/roles/mgrote_proxmox_lxc_profiles/README.md @@ -8,7 +8,7 @@ Adds [bind-mounts](https://pve.proxmox.com/wiki/Linux_Container#pct_container_st ### Variablen + Defaults ``` -pve_bind_mounts: # Dictionary +pve_bind_mounts: # Dictionary - vmid: 105 # VMID for which the bind-mount should get created mp_nr: 1 # Number of the mountpoint mp_path_host: /rpool/test # Path on the Host diff --git a/roles/mgrote_proxmox_lxc_profiles/defaults/main.yml b/roles/mgrote_proxmox_lxc_profiles/defaults/main.yml new file mode 100644 index 00000000..ac12ceed --- /dev/null +++ b/roles/mgrote_proxmox_lxc_profiles/defaults/main.yml @@ -0,0 +1,7 @@ +--- +lists_merged: # Liste muss leer existieren damit sie "germerged" werden kann, für Liste welche VMs zu rebooten sind + - '' + +# lxc_apparmor_profiles: +# - vmid: 555 +# apparmor_profile: unconfined diff --git a/roles/mgrote_proxmox_lxc_profiles/handlers/main.yml b/roles/mgrote_proxmox_lxc_profiles/handlers/main.yml new file mode 100644 index 00000000..d41e4aef --- /dev/null +++ b/roles/mgrote_proxmox_lxc_profiles/handlers/main.yml @@ -0,0 +1,11 @@ +--- +- name: restart lxc # noqa no-changed-when + become: true + ansible.builtin.command: "pct reboot {{ item }}" + failed_when: false + loop: "{{ lists_merged | unique }}" + # reboote den lxc wenn: + # - er in der Liste "Lists merged" vorhanden ist + # unique Filter sorgt dafür das es keine doppelten Elemente gibt + # https://docs.ansible.com/ansible/latest/user_guide/playbooks_filters.html#set-theory-filters + # https://www.reddit.com/r/ansible/comments/8cp86c/how_do_i_remove_duplicate_items_from_a_variable/ diff --git a/roles/mgrote_proxmox_lxc_profiles/tasks/main.yml b/roles/mgrote_proxmox_lxc_profiles/tasks/main.yml new file mode 100644 index 00000000..58464587 --- /dev/null +++ b/roles/mgrote_proxmox_lxc_profiles/tasks/main.yml @@ -0,0 +1,7 @@ +--- +- name: loop tasks + ansible.builtin.include_tasks: profile.yml + loop: "{{ lxc_apparmor_profiles }}" + when: + - lxc_apparmor_profiles is defined + # Loope durch jeden bind-mount diff --git a/roles/mgrote_proxmox_lxc_profiles/tasks/profile.yml b/roles/mgrote_proxmox_lxc_profiles/tasks/profile.yml new file mode 100644 index 00000000..d1054d7b --- /dev/null +++ b/roles/mgrote_proxmox_lxc_profiles/tasks/profile.yml @@ -0,0 +1,24 @@ +--- +- name: set apparmor profile + become: true + ansible.builtin.lineinfile: + path: "/etc/pve/lxc/{{ item.vmid }}.conf" + line: "lxc.apparmor.profile: {{ item.apparmor_profile }}" + state: present + register: restart + + # schreibe vm id in die Liste "reboot" +- name: set reboot list # noqa no-handler var-naming[pattern] + become: true + ansible.builtin.set_fact: + ansible.builtin.reboot: + - "{{ item.vmid }}" + when: restart.changed + + # Füge die leere Liste "lists_merged" aus den defaults, mit der Liste "reboot" zusammen. Nur wenn auch etwas geändert wurde, daher "when:..." +- name: merge reboot lists # noqa no-handler + become: true + ansible.builtin.set_fact: + lists_merged: "{{ lists_merged + reboot }}" + when: restart.changed + # https://blog.crisp.se/2016/10/20/maxwenzin/how-to-append-to-lists-in-ansible diff --git a/roles/mgrote.qemu_guest_agent/README.md b/roles/mgrote_qemu_guest_agent/README.md similarity index 100% rename from roles/mgrote.qemu_guest_agent/README.md rename to roles/mgrote_qemu_guest_agent/README.md diff --git a/roles/mgrote_qemu_guest_agent/handlers/main.yml b/roles/mgrote_qemu_guest_agent/handlers/main.yml new file mode 100644 index 00000000..c22b27fb --- /dev/null +++ b/roles/mgrote_qemu_guest_agent/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: reboot + become: true + ansible.builtin.reboot: + reboot_timeout: 120 diff --git a/roles/mgrote_qemu_guest_agent/tasks/main.yml b/roles/mgrote_qemu_guest_agent/tasks/main.yml new file mode 100644 index 00000000..0c5f3587 --- /dev/null +++ b/roles/mgrote_qemu_guest_agent/tasks/main.yml @@ -0,0 +1,13 @@ +--- +- name: update apt cache + become: true + ansible.builtin.apt: + update_cache: true + +- name: install packages + become: true + ansible.builtin.package: + name: qemu-guest-agent + state: present + when: ansible_virtualization_role == 'guest' + notify: reboot diff --git a/roles/mgrote.remove_snapd/README.md b/roles/mgrote_remove_snapd/README.md similarity index 100% rename from roles/mgrote.remove_snapd/README.md rename to roles/mgrote_remove_snapd/README.md diff --git a/roles/mgrote_remove_snapd/tasks/main.yml b/roles/mgrote_remove_snapd/tasks/main.yml new file mode 100644 index 00000000..e7272e0f --- /dev/null +++ b/roles/mgrote_remove_snapd/tasks/main.yml @@ -0,0 +1,13 @@ +--- +- name: remove snapd package + become: true + ansible.builtin.package: + name: snapd + state: absent + purge: true + +- name: remove /var/cache/snapd/ + become: true + ansible.builtin.file: + path: /var/cache/snapd/ + state: absent diff --git a/roles/mgrote.restic/README.md b/roles/mgrote_restic/README.md similarity index 100% rename from roles/mgrote.restic/README.md rename to roles/mgrote_restic/README.md diff --git a/roles/mgrote_restic/defaults/main.yml b/roles/mgrote_restic/defaults/main.yml new file mode 100644 index 00000000..000a455c --- /dev/null +++ b/roles/mgrote_restic/defaults/main.yml @@ -0,0 +1,33 @@ +--- +# restic user +restic_user: root +# restic group +restic_group: restic +# restic config directory +restic_conf_dir: /etc/restic +# was soll ausgeschlossen werden, siehe: https://github.com/restic/restic/issues/1005; https://forum.restic.net/t/exclude-syntax-confusion/1531/12 +restic_exclude: | + ._* + desktop.ini + .Trash-* + **/**cache***/** + **/**Cache***/** + **/**AppData***/** +# timeout for cifs mount; systemd notation(systemd-analyze calendar "Sun *-0/2-* 23:00") +restic_mount_timeout: "10 min" +# delay for restartung task; systemd notation(systemd-analyze calendar "Sun *-0/2-* 23:00") +restic_failure_delay: "30 s" +# when should restic run; systemd notation(systemd-analyze calendar "Sun *-0/2-* 23:00") +restic_schedule: "*:0/2" +# welche ordner sollen gesichert werden +restic_folders_to_backup: "/usr/local /etc /root /var/www /home" +# smb-share mit dem repository: z.B. "//fileserver3.grote.lan/restic" +restic_repository: "//fileserver.domain/restic" +# password für das repo +restic_repository_password: "{{ lookup('keepass', 'restic_repository_password', 'password') }}" +# nutzer für den share +restic_mount_user: restic +# passwort für den mount +restic_mount_password: "unsafe_password" +# where to send in case of an error +restic_fail_mail: x@y.de diff --git a/roles/mgrote_restic/handlers/main.yml b/roles/mgrote_restic/handlers/main.yml new file mode 100644 index 00000000..829c059b --- /dev/null +++ b/roles/mgrote_restic/handlers/main.yml @@ -0,0 +1,28 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true + +- name: systemctl enable units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + enabled: true + masked: false + with_items: + - media-restic.automount + - media-restic.mount + - restic.service + - restic.timer + - restic_mail.service + +- name: systemctl start units + become: true + ansible.builtin.systemd: + name: "{{ item }}" + state: restarted + enabled: true + with_items: + - restic.timer + notify: systemctl daemon-reload diff --git a/roles/mgrote_restic/tasks/main.yml b/roles/mgrote_restic/tasks/main.yml new file mode 100644 index 00000000..3e7b0450 --- /dev/null +++ b/roles/mgrote_restic/tasks/main.yml @@ -0,0 +1,117 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ restic_group }}" + state: present + +- name: install restic-packages + become: true + ansible.builtin.package: + name: + - restic + state: present + +- name: create "{{ restic_conf_dir }}" + become: true + ansible.builtin.file: + path: "{{ restic_conf_dir }}" + state: directory + owner: "{{ restic_user }}" + group: "{{ restic_group }}" + mode: "0755" + +- name: template smb.cred + become: true + ansible.builtin.template: + src: "smb.cred.j2" + dest: "{{ restic_conf_dir }}/smb.cred" + owner: "{{ restic_user }}" + group: "{{ restic_group }}" + mode: "0600" + no_log: true + +- name: templates excludes + become: true + ansible.builtin.blockinfile: + path: "{{ restic_conf_dir }}/excludes" + create: true + block: "{{ restic_exclude }}" + mode: "0644" + owner: "{{ restic_user }}" + group: "{{ restic_group }}" + +- name: template restic.env + become: true + ansible.builtin.template: + src: "restic.env.j2" + dest: "{{ restic_conf_dir }}/restic.env" + owner: root + group: root + mode: "0600" + no_log: true + +- name: template restic.mount + become: true + ansible.builtin.template: + src: media-restic.mount.j2 + dest: /etc/systemd/system/media-restic.mount # media-restic == /media/restic + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + - systemctl enable units + +- name: template restic.automount + become: true + ansible.builtin.template: + src: media-restic.automount.j2 + dest: /etc/systemd/system/media-restic.automount + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + - systemctl enable units + - systemctl start units + +- name: template restic.service + become: true + ansible.builtin.template: + src: restic.service.j2 + dest: /etc/systemd/system/restic.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: template restic.timer + become: true + ansible.builtin.template: + src: restic.timer.j2 + dest: /etc/systemd/system/restic.timer + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: template restic_mail.service + become: true + ansible.builtin.template: + src: "restic_mail.service.j2" + dest: /etc/systemd/system/restic_mail.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: systemctl start restic.timer + become: true + ansible.builtin.systemd: + name: restic.timer + state: started + enabled: true diff --git a/roles/mgrote.restic/templates/media-restic.automount.j2 b/roles/mgrote_restic/templates/media-restic.automount.j2 similarity index 100% rename from roles/mgrote.restic/templates/media-restic.automount.j2 rename to roles/mgrote_restic/templates/media-restic.automount.j2 diff --git a/roles/mgrote.restic/templates/media-restic.mount.j2 b/roles/mgrote_restic/templates/media-restic.mount.j2 similarity index 100% rename from roles/mgrote.restic/templates/media-restic.mount.j2 rename to roles/mgrote_restic/templates/media-restic.mount.j2 diff --git a/roles/mgrote.restic/templates/restic.env.j2 b/roles/mgrote_restic/templates/restic.env.j2 similarity index 100% rename from roles/mgrote.restic/templates/restic.env.j2 rename to roles/mgrote_restic/templates/restic.env.j2 diff --git a/roles/mgrote.restic/templates/restic.service.j2 b/roles/mgrote_restic/templates/restic.service.j2 similarity index 100% rename from roles/mgrote.restic/templates/restic.service.j2 rename to roles/mgrote_restic/templates/restic.service.j2 diff --git a/roles/mgrote.restic/templates/restic.timer.j2 b/roles/mgrote_restic/templates/restic.timer.j2 similarity index 100% rename from roles/mgrote.restic/templates/restic.timer.j2 rename to roles/mgrote_restic/templates/restic.timer.j2 diff --git a/roles/mgrote.restic/templates/restic_mail.service.j2 b/roles/mgrote_restic/templates/restic_mail.service.j2 similarity index 100% rename from roles/mgrote.restic/templates/restic_mail.service.j2 rename to roles/mgrote_restic/templates/restic_mail.service.j2 diff --git a/roles/mgrote.restic/templates/smb.cred.j2 b/roles/mgrote_restic/templates/smb.cred.j2 similarity index 100% rename from roles/mgrote.restic/templates/smb.cred.j2 rename to roles/mgrote_restic/templates/smb.cred.j2 diff --git a/roles/mgrote.sealed-secrets/README.md b/roles/mgrote_sealed_secrets/README.md similarity index 100% rename from roles/mgrote.sealed-secrets/README.md rename to roles/mgrote_sealed_secrets/README.md diff --git a/roles/mgrote_sealed_secrets/defaults/main.yml b/roles/mgrote_sealed_secrets/defaults/main.yml new file mode 100644 index 00000000..3219373b --- /dev/null +++ b/roles/mgrote_sealed_secrets/defaults/main.yml @@ -0,0 +1,8 @@ +--- +sealed_secrets_homedir: /home/sealed_secrets +sealed_secrets_user_group: sealed_secrets +sealed_secrets_user: sealed_secrets +kubeseal_download_url: "https://github.com/bitnami-labs/sealed-secrets/releases/download/v0.19.1/kubeseal-0.19.1-linux-amd64.tar.gz" +kubeseal_path_bin: /usr/local/sbin +kubeconfig: /etc/rancher/k3s/k3s.yaml +sealed_secrets_keepass_entry_name: "{{ lookup('keepass', 'k3s-sealed-secrets-private-key', 'notes') }}" # mit kubectl get secret -n kube-system -l sealedsecrets.bitnami.com/sealed-secrets-key -o yaml >main.key holen diff --git a/roles/mgrote_sealed_secrets/tasks/import.yml b/roles/mgrote_sealed_secrets/tasks/import.yml new file mode 100644 index 00000000..155cacda --- /dev/null +++ b/roles/mgrote_sealed_secrets/tasks/import.yml @@ -0,0 +1,29 @@ +--- +- name: check if private key exists + ansible.builtin.command: kubectl get secrets sealed-secrets-keytsq4k -n kube-system + register: key + ignore_errors: true + changed_when: false + +- name: Template private key file + ansible.builtin.template: + src: private.key.j2 + dest: /root/private.key + owner: root + group: root + mode: '0400' + when: key.rc not in [ 0 ] + no_log: true + +- name: apply private key # noqa no-changed-when + ansible.builtin.command: kubectl apply -f /root/private.key + when: key.rc not in [ 0 ] + +- name: remove old pod # noqa no-changed-when + ansible.builtin.command: kubectl delete pod -n kube-system -l name=sealed-secrets-controller + when: key.rc not in [ 0 ] + +- name: remove private key file + ansible.builtin.file: + path: /root/private.key + state: absent diff --git a/roles/mgrote_sealed_secrets/tasks/main.yml b/roles/mgrote_sealed_secrets/tasks/main.yml new file mode 100644 index 00000000..ef463a18 --- /dev/null +++ b/roles/mgrote_sealed_secrets/tasks/main.yml @@ -0,0 +1,26 @@ +--- +- name: include user tasks + ansible.builtin.include_tasks: user.yml + +- name: check if kubeseal is installed + ansible.builtin.command: which kubeseal + changed_when: false + failed_when: kubeseal_installed.rc not in [0,1] + register: kubeseal_installed + +- name: download sealed_secrets binary + ansible.builtin.unarchive: + src: "{{ kubeseal_download_url }}" + dest: "{{ kubeseal_path_bin }}" + mode: "0755" + owner: "{{ sealed_secrets_user }}" + group: "{{ sealed_secrets_user_group }}" + remote_src: true + creates: "{{ kubeseal_path_bin }}/kubeseal" + when: kubeseal_installed.rc not in [ 0 ] + +- name: include import tasks + ansible.builtin.include_tasks: import.yml + # der ganze block nur auf enem host + run_once: true + when: ansible_host == flux_install_host diff --git a/roles/mgrote_sealed_secrets/tasks/user.yml b/roles/mgrote_sealed_secrets/tasks/user.yml new file mode 100644 index 00000000..6262fee4 --- /dev/null +++ b/roles/mgrote_sealed_secrets/tasks/user.yml @@ -0,0 +1,18 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ sealed_secrets_user_group }}" + state: present + when: + - sealed_secrets_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ sealed_secrets_user }}" + group: "{{ sealed_secrets_user_group }}" + create_home: false + when: + - sealed_secrets_user_group is defined + - sealed_secrets_user is defined diff --git a/roles/mgrote.sealed-secrets/templates/private.key.j2 b/roles/mgrote_sealed_secrets/templates/private.key.j2 similarity index 100% rename from roles/mgrote.sealed-secrets/templates/private.key.j2 rename to roles/mgrote_sealed_secrets/templates/private.key.j2 diff --git a/roles/mgrote.set_permissions/README.md b/roles/mgrote_set_permissions/README.md similarity index 100% rename from roles/mgrote.set_permissions/README.md rename to roles/mgrote_set_permissions/README.md diff --git a/roles/mgrote.set_permissions/tasks/main.yml b/roles/mgrote_set_permissions/tasks/main.yml similarity index 100% rename from roles/mgrote.set_permissions/tasks/main.yml rename to roles/mgrote_set_permissions/tasks/main.yml diff --git a/roles/mgrote.smart/README.md b/roles/mgrote_smart/README.md similarity index 100% rename from roles/mgrote.smart/README.md rename to roles/mgrote_smart/README.md diff --git a/roles/mgrote_smart/defaults/main.yml b/roles/mgrote_smart/defaults/main.yml new file mode 100644 index 00000000..2dd7a23a --- /dev/null +++ b/roles/mgrote_smart/defaults/main.yml @@ -0,0 +1,6 @@ +--- +# path to smartctl +smart_smartctl_path: "/usr/sbin/smartctl" +# under which user the script is run +smart_user_group: "root" +smart_user: "smart" diff --git a/roles/mgrote_smart/handlers/main.yml b/roles/mgrote_smart/handlers/main.yml new file mode 100644 index 00000000..cd285f29 --- /dev/null +++ b/roles/mgrote_smart/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart smartmontools + become: true + ansible.builtin.systemd: + name: smartmontools + state: restarted + enabled: true diff --git a/roles/mgrote_smart/tasks/main.yml b/roles/mgrote_smart/tasks/main.yml new file mode 100644 index 00000000..7d71293e --- /dev/null +++ b/roles/mgrote_smart/tasks/main.yml @@ -0,0 +1,29 @@ +--- +- name: include user tasks + ansible.builtin.include_tasks: user.yml + +- name: ensure smartmontools are installed + become: true + ansible.builtin.package: + name: smartmontools + state: present + +- name: template smartmontools config + become: true + ansible.builtin.template: + src: "smartmontools" + dest: "/etc/default/smartmontools" + owner: "{{ smart_user }}" + group: "{{ smart_user_group }}" + mode: "0644" + notify: restart smartmontools + +- name: template smartd.conf + become: true + ansible.builtin.template: + src: "smartd.conf" + dest: "/etc/smartd.conf" + owner: "{{ smart_user }}" + group: "{{ smart_user_group }}" + mode: "0644" + notify: restart smartmontools diff --git a/roles/mgrote_smart/tasks/user.yml b/roles/mgrote_smart/tasks/user.yml new file mode 100644 index 00000000..961c6f87 --- /dev/null +++ b/roles/mgrote_smart/tasks/user.yml @@ -0,0 +1,19 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ smart_user_group }}" + state: present + when: + - smart_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ smart_user }}" + group: "{{ smart_user_group }}" + shell: /usr/sbin/nologin + create_home: false + when: + - smart_user_group is defined + - smart_user is defined diff --git a/roles/mgrote.smart/templates/smartd.conf b/roles/mgrote_smart/templates/smartd.conf similarity index 100% rename from roles/mgrote.smart/templates/smartd.conf rename to roles/mgrote_smart/templates/smartd.conf diff --git a/roles/mgrote.smart/templates/smartmontools b/roles/mgrote_smart/templates/smartmontools similarity index 100% rename from roles/mgrote.smart/templates/smartmontools rename to roles/mgrote_smart/templates/smartmontools diff --git a/roles/mgrote.ssh/README.md b/roles/mgrote_ssh/README.md similarity index 100% rename from roles/mgrote.ssh/README.md rename to roles/mgrote_ssh/README.md diff --git a/roles/mgrote_ssh/handlers/main.yml b/roles/mgrote_ssh/handlers/main.yml new file mode 100644 index 00000000..6b341078 --- /dev/null +++ b/roles/mgrote_ssh/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: restart sshd + become: true + ansible.builtin.systemd: + name: sshd + enabled: true + state: restarted diff --git a/roles/mgrote_ssh/tasks/main.yml b/roles/mgrote_ssh/tasks/main.yml new file mode 100644 index 00000000..7a3f1510 --- /dev/null +++ b/roles/mgrote_ssh/tasks/main.yml @@ -0,0 +1,10 @@ +--- +- name: include ubuntu tasks (determined by "ansible_distribution") + ansible.builtin.include_tasks: ubuntu.yml + when: + - ansible_distribution == 'Ubuntu' + +- name: include proxmox tasks (determined by group) + ansible.builtin.include_tasks: pve.yml + when: + - "'proxmox' in group_names" diff --git a/roles/mgrote_ssh/tasks/pve.yml b/roles/mgrote_ssh/tasks/pve.yml new file mode 100644 index 00000000..bebfd968 --- /dev/null +++ b/roles/mgrote_ssh/tasks/pve.yml @@ -0,0 +1,15 @@ +--- +- name: source proxmox vars + ansible.builtin.include_vars: pve.yml + +- name: template sshd_config + become: true + ansible.builtin.template: + src: pve.j2 + dest: /etc/ssh/sshd_config + owner: root + group: root + mode: "0644" + validate: "/usr/sbin/sshd -T -f %s" + backup: true + notify: restart sshd diff --git a/roles/mgrote_ssh/tasks/ubuntu.yml b/roles/mgrote_ssh/tasks/ubuntu.yml new file mode 100644 index 00000000..1b58fa4d --- /dev/null +++ b/roles/mgrote_ssh/tasks/ubuntu.yml @@ -0,0 +1,15 @@ +--- +- name: source ubuntu vars + ansible.builtin.include_vars: ubuntu.yml + +- name: template sshd_config + become: true + ansible.builtin.template: + src: ubuntu.j2 + dest: /etc/ssh/sshd_config + owner: root + group: root + mode: "0644" + validate: "/usr/sbin/sshd -T -f %s" + backup: true + notify: restart sshd diff --git a/roles/mgrote.ssh/templates/pve.j2 b/roles/mgrote_ssh/templates/pve.j2 similarity index 100% rename from roles/mgrote.ssh/templates/pve.j2 rename to roles/mgrote_ssh/templates/pve.j2 diff --git a/roles/mgrote.ssh/templates/ubuntu.j2 b/roles/mgrote_ssh/templates/ubuntu.j2 similarity index 100% rename from roles/mgrote.ssh/templates/ubuntu.j2 rename to roles/mgrote_ssh/templates/ubuntu.j2 diff --git a/roles/mgrote_ssh/vars/pve.yml b/roles/mgrote_ssh/vars/pve.yml new file mode 100644 index 00000000..d30ddaa2 --- /dev/null +++ b/roles/mgrote_ssh/vars/pve.yml @@ -0,0 +1,6 @@ +--- +ssh_permit_root_login: "yes" +ssh_password_authentication: "yes" +ssh_print_motd: "no" +ssh_print_lastlog: "no" +ssh_listen_port: "22" diff --git a/roles/mgrote_ssh/vars/ubuntu.yml b/roles/mgrote_ssh/vars/ubuntu.yml new file mode 100644 index 00000000..35f33646 --- /dev/null +++ b/roles/mgrote_ssh/vars/ubuntu.yml @@ -0,0 +1,6 @@ +--- +ssh_permit_root_login: "no" +ssh_password_authentication: "no" +ssh_print_motd: "no" +ssh_print_lastlog: "no" +ssh_listen_port: "22" diff --git a/roles/mgrote.systemd-resolved/README.md b/roles/mgrote_systemd_resolved/README.md similarity index 100% rename from roles/mgrote.systemd-resolved/README.md rename to roles/mgrote_systemd_resolved/README.md diff --git a/roles/mgrote.systemd-resolved/defaults/main.yml b/roles/mgrote_systemd_resolved/defaults/main.yml similarity index 85% rename from roles/mgrote.systemd-resolved/defaults/main.yml rename to roles/mgrote_systemd_resolved/defaults/main.yml index b8b25d65..3b8e7d76 100644 --- a/roles/mgrote.systemd-resolved/defaults/main.yml +++ b/roles/mgrote_systemd_resolved/defaults/main.yml @@ -1 +1,2 @@ +--- nameserver: 192.168.2.1 diff --git a/roles/mgrote_systemd_resolved/handlers/main.yml b/roles/mgrote_systemd_resolved/handlers/main.yml new file mode 100644 index 00000000..17d36c50 --- /dev/null +++ b/roles/mgrote_systemd_resolved/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: restart systemd-resolved + ansible.builtin.systemd: + state: restarted + name: systemd-resolved diff --git a/roles/mgrote_systemd_resolved/tasks/main.yml b/roles/mgrote_systemd_resolved/tasks/main.yml new file mode 100644 index 00000000..9b7654b7 --- /dev/null +++ b/roles/mgrote_systemd_resolved/tasks/main.yml @@ -0,0 +1,24 @@ +--- +- name: Make sure systemd-resolved is running + ansible.builtin.systemd: + state: started + masked: false + name: systemd-resolved + +- name: template /etc/systemd/resolved.conf + ansible.builtin.template: + src: resolved.conf.j2 + dest: /etc/systemd/resolved.conf + owner: root + group: root + mode: "0644" + notify: restart systemd-resolved + +- name: template /etc/resolv.conf + ansible.builtin.template: + src: resolv.conf.j2 + dest: /etc/resolv.conf + owner: root + group: root + mode: "0644" + notify: restart systemd-resolved diff --git a/roles/mgrote.systemd-resolved/templates/resolv.conf.j2 b/roles/mgrote_systemd_resolved/templates/resolv.conf.j2 similarity index 100% rename from roles/mgrote.systemd-resolved/templates/resolv.conf.j2 rename to roles/mgrote_systemd_resolved/templates/resolv.conf.j2 diff --git a/roles/mgrote.systemd-resolved/templates/resolved.conf.j2 b/roles/mgrote_systemd_resolved/templates/resolved.conf.j2 similarity index 100% rename from roles/mgrote.systemd-resolved/templates/resolved.conf.j2 rename to roles/mgrote_systemd_resolved/templates/resolved.conf.j2 diff --git a/roles/mgrote.users/README.md b/roles/mgrote_users/README.md similarity index 100% rename from roles/mgrote.users/README.md rename to roles/mgrote_users/README.md diff --git a/roles/mgrote_users/tasks/main.yml b/roles/mgrote_users/tasks/main.yml new file mode 100644 index 00000000..28c0d77a --- /dev/null +++ b/roles/mgrote_users/tasks/main.yml @@ -0,0 +1,43 @@ +--- +- name: set groups as list + ansible.builtin.set_fact: + groups_as_list: "{{ (groups_as_list | default([]) + item.groups.split(',')) | map('trim') | list | sort | unique }}" + loop: '{{ users }}' + when: item.groups is defined + +- name: create groups + ansible.builtin.group: + name: "{{ item }}" + state: present + loop: "{{ groups_as_list }}" + when: groups_as_list is defined + +- name: create users + ansible.builtin.user: + name: "{{ item.username }}" + uid: "{{ item.uid | default(omit) }}" + shell: "{{ item.shell | default('/bin/bash') }}" + password: "{{ item.password }}" + update_password: "{{ item.update_password | default(omit) }}" + groups: "{{ item.groups | default(omit) }}" + createhome: "{{ item.createhome | default('yes') }}" + state: "{{ item.state | default('present') }}" + loop: '{{ users }}' + +- name: add ssh key + ansible.posix.authorized_key: + user: "{{ item.username }}" + key: "{{ item.public_ssh_key }}" + state: present + when: item.public_ssh_key is defined + loop: '{{ users }}' + +- name: add to sudoers + ansible.builtin.lineinfile: + dest: /etc/sudoers + state: present + regexp: '^{{ item.username }} ' + line: "{{ item.username }} ALL=(ALL) {{ 'NOPASSWD:' if (item.allow_passwordless_sudo | d(false)) else '' }}ALL" + validate: 'visudo -cf %s' + when: item.allow_sudo|default(false) and item.allow_sudo is defined + loop: '{{ users }}' diff --git a/roles/mgrote_vim/defaults/main.yml b/roles/mgrote_vim/defaults/main.yml new file mode 100644 index 00000000..656da8bf --- /dev/null +++ b/roles/mgrote_vim/defaults/main.yml @@ -0,0 +1,4 @@ +--- +vim_vundle_path: /home/mg/.vim/bundle/Vundle.vim +vim_vundle_repo_url: https://github.com/VundleVim/Vundle.vim.git +vim_homedir: /home/mg/.vim diff --git a/roles/mgrote_vim/handlers/main.yml b/roles/mgrote_vim/handlers/main.yml new file mode 100644 index 00000000..0ffde0a8 --- /dev/null +++ b/roles/mgrote_vim/handlers/main.yml @@ -0,0 +1,7 @@ +--- +- name: set owner recursive for repo + ansible.builtin.file: + path: "{{ vim_homedir }}" + owner: mg + group: mg + recurse: true diff --git a/roles/mgrote.vim/readme.md b/roles/mgrote_vim/readme.md similarity index 100% rename from roles/mgrote.vim/readme.md rename to roles/mgrote_vim/readme.md diff --git a/roles/mgrote_vim/tasks/main.yml b/roles/mgrote_vim/tasks/main.yml new file mode 100644 index 00000000..a49bc3e8 --- /dev/null +++ b/roles/mgrote_vim/tasks/main.yml @@ -0,0 +1,38 @@ +--- +- name: install packages + become: true + ansible.builtin.package: + name: + - vim + - ripgrep + state: present + +- name: check if vundle is installed - folder + become: true + ansible.builtin.stat: + path: "{{ vim_vundle_path }}" + register: folder_exists + + +- name: set safe directory # noqa command-instead-of-module + become: true + ansible.builtin.command: + cmd: git config --global --add safe.directory "{{ vim_vundle_path }}" + changed_when: false + +- name: Ensure repository is cloned locally. + ansible.builtin.git: + repo: "{{ vim_vundle_repo_url }}" + dest: "{{ vim_vundle_path }}" + depth: 1 + version: master + notify: set owner recursive for repo + +# - name: Vundle - PluginInstall +# ansible.builtin.shell: yes | vim -c PluginInstall -c qall +# args: +# chdir: /home/mg +# when: +# - (folder_exists.stat.exists == False) and ("ansible_facts['distribution'] == 'Ubuntu'") +# become: true +# become_user: mg diff --git a/roles/mgrote.youtubedl/README.md b/roles/mgrote_youtubedl/README.md similarity index 100% rename from roles/mgrote.youtubedl/README.md rename to roles/mgrote_youtubedl/README.md diff --git a/roles/mgrote.youtubedl/defaults/main.yml b/roles/mgrote_youtubedl/defaults/main.yml similarity index 100% rename from roles/mgrote.youtubedl/defaults/main.yml rename to roles/mgrote_youtubedl/defaults/main.yml diff --git a/roles/mgrote_youtubedl/handlers/main.yml b/roles/mgrote_youtubedl/handlers/main.yml new file mode 100644 index 00000000..ab3f5feb --- /dev/null +++ b/roles/mgrote_youtubedl/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true diff --git a/roles/mgrote_youtubedl/tasks/main.yml b/roles/mgrote_youtubedl/tasks/main.yml new file mode 100644 index 00000000..6d296e69 --- /dev/null +++ b/roles/mgrote_youtubedl/tasks/main.yml @@ -0,0 +1,86 @@ +--- +- name: download binary + become: true + ansible.builtin.get_url: + url: "{{ ytdl_dl_url }}" + dest: /usr/local/bin/yt-dlp + mode: "0750" + +- name: install packages + become: true + ansible.builtin.package: + name: + - ffmpeg + - brotli + - python3-mutagen + state: present + +- name: ensure dir exists + become: true + ansible.builtin.file: + path: "{{ ytdl_conf_dir }}" + state: directory + owner: root + group: root + mode: "0755" + +- name: template youtubedl config + become: true + ansible.builtin.template: + src: "{{ item }}" + dest: "{{ ytdl_conf_dir }}/{{ item }}" + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + loop: + - podcast.txt + - youtube.txt + +- name: template systemd services + become: true + ansible.builtin.template: + src: "youtubedl.service.j2" + dest: "/etc/systemd/system/youtubedl.service" + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + when: ytdl_active + +- name: template youtubedl timer + become: true + ansible.builtin.template: + src: "youtubedl.timer.j2" + dest: "/etc/systemd/system/youtubedl.timer" + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + when: ytdl_active + +- name: template youtube_mail.service.j2 + become: true + ansible.builtin.template: + src: "youtubedl_mail.service.j2" + dest: "/etc/systemd/system/youtubedl_mail.service" + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + when: ytdl_active + +- name: systemctl enable timer units + become: true + ansible.builtin.systemd: + name: "youtubedl.timer" + enabled: true + masked: false + state: started + notify: + - systemctl daemon-reload + when: ytdl_active diff --git a/roles/mgrote.youtubedl/templates/podcast.txt b/roles/mgrote_youtubedl/templates/podcast.txt similarity index 100% rename from roles/mgrote.youtubedl/templates/podcast.txt rename to roles/mgrote_youtubedl/templates/podcast.txt diff --git a/roles/mgrote.youtubedl/templates/youtube.txt b/roles/mgrote_youtubedl/templates/youtube.txt similarity index 100% rename from roles/mgrote.youtubedl/templates/youtube.txt rename to roles/mgrote_youtubedl/templates/youtube.txt diff --git a/roles/mgrote.youtubedl/templates/youtubedl.service.j2 b/roles/mgrote_youtubedl/templates/youtubedl.service.j2 similarity index 100% rename from roles/mgrote.youtubedl/templates/youtubedl.service.j2 rename to roles/mgrote_youtubedl/templates/youtubedl.service.j2 diff --git a/roles/mgrote.youtubedl/templates/youtubedl.timer.j2 b/roles/mgrote_youtubedl/templates/youtubedl.timer.j2 similarity index 100% rename from roles/mgrote.youtubedl/templates/youtubedl.timer.j2 rename to roles/mgrote_youtubedl/templates/youtubedl.timer.j2 diff --git a/roles/mgrote.youtubedl/templates/youtubedl_mail.service.j2 b/roles/mgrote_youtubedl/templates/youtubedl_mail.service.j2 similarity index 100% rename from roles/mgrote.youtubedl/templates/youtubedl_mail.service.j2 rename to roles/mgrote_youtubedl/templates/youtubedl_mail.service.j2 diff --git a/roles/mgrote.zfs_arc_mem/README.md b/roles/mgrote_zfs_arc_mem/README.md similarity index 100% rename from roles/mgrote.zfs_arc_mem/README.md rename to roles/mgrote_zfs_arc_mem/README.md diff --git a/roles/mgrote_zfs_arc_mem/defaults/main.yml b/roles/mgrote_zfs_arc_mem/defaults/main.yml new file mode 100644 index 00000000..a6e42f5d --- /dev/null +++ b/roles/mgrote_zfs_arc_mem/defaults/main.yml @@ -0,0 +1,2 @@ +--- +zfs_extra_arc_max_size: "8589934592" #in Bytes diff --git a/roles/mgrote_zfs_arc_mem/tasks/main.yml b/roles/mgrote_zfs_arc_mem/tasks/main.yml new file mode 100644 index 00000000..6360d795 --- /dev/null +++ b/roles/mgrote_zfs_arc_mem/tasks/main.yml @@ -0,0 +1,9 @@ +--- +- name: Limit ZFS Memory Usage + become: true + ansible.builtin.copy: + dest: /etc/modprobe.d/zfs.conf + content: options zfs zfs_arc_max={{ zfs_extra_arc_max_size }} + owner: root + group: root + mode: "0644" diff --git a/roles/mgrote.zfs_health/README.md b/roles/mgrote_zfs_health/README.md similarity index 100% rename from roles/mgrote.zfs_health/README.md rename to roles/mgrote_zfs_health/README.md diff --git a/roles/mgrote_zfs_health/defaults/main.yml b/roles/mgrote_zfs_health/defaults/main.yml new file mode 100644 index 00000000..cb4c8dbf --- /dev/null +++ b/roles/mgrote_zfs_health/defaults/main.yml @@ -0,0 +1,7 @@ +--- +### when should the script be run +zfs_extra_cron_minutes_zfs_health: "0,15,30,45" +zfs_extra_cron_hours_zfs_health: "*" +### under which user the script is run +zfs_health_user_group: "root" +zfs_health_user: "zfs-health" diff --git a/roles/mgrote_zfs_health/tasks/main.yml b/roles/mgrote_zfs_health/tasks/main.yml new file mode 100644 index 00000000..55af11a5 --- /dev/null +++ b/roles/mgrote_zfs_health/tasks/main.yml @@ -0,0 +1,22 @@ +--- +- name: include user tasks + ansible.builtin.include_tasks: user.yml + +- name: template script + become: true + ansible.builtin.template: + src: zfs-health.sh + dest: /usr/local/bin/zfs-health.sh + mode: "0744" + owner: "{{ zfs_health_user }}" + group: "{{ zfs_health_user_group }}" + +- name: ensure cronjob exists + become: true + ansible.builtin.cron: + name: zfs_health + state: present + job: "/usr/local/bin/zfs-health.sh" + minute: "{{ zfs_extra_cron_minutes_zfs_health }}" + hour: "{{ zfs_extra_cron_hours_zfs_health }}" + user: "{{ zfs_health_user }}" diff --git a/roles/mgrote_zfs_health/tasks/user.yml b/roles/mgrote_zfs_health/tasks/user.yml new file mode 100644 index 00000000..5d1bf383 --- /dev/null +++ b/roles/mgrote_zfs_health/tasks/user.yml @@ -0,0 +1,19 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ zfs_health_user_group }}" + state: present + when: + - zfs_health_user_group is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ zfs_health_user }}" + group: "{{ zfs_health_user_group }}" + shell: /usr/sbin/nologin + create_home: false + when: + - zfs_health_user_group is defined + - zfs_health_user is defined diff --git a/roles/mgrote.zfs_health/templates/zfs-health.sh b/roles/mgrote_zfs_health/templates/zfs-health.sh similarity index 100% rename from roles/mgrote.zfs_health/templates/zfs-health.sh rename to roles/mgrote_zfs_health/templates/zfs-health.sh diff --git a/roles/mgrote.zfs_manage_datasets/README.md b/roles/mgrote_zfs_manage_datasets/README.md similarity index 100% rename from roles/mgrote.zfs_manage_datasets/README.md rename to roles/mgrote_zfs_manage_datasets/README.md diff --git a/roles/mgrote_zfs_manage_datasets/tasks/main.yml b/roles/mgrote_zfs_manage_datasets/tasks/main.yml new file mode 100644 index 00000000..f21b3d25 --- /dev/null +++ b/roles/mgrote_zfs_manage_datasets/tasks/main.yml @@ -0,0 +1,59 @@ +--- +- name: create datasets or set options + become: true + community.general.zfs: + name: "{{ item.dataset }}" + state: "{{ item.state | default('present') }}" + extra_zfs_properties: + quota: "{{ item.quota | default(omit) }}" + reservation: "{{ item.reservation | default(omit) }}" + recordsize: "{{ item.recordsize | default(omit) }}" + mountpoint: "{{ item.mountpoint | default(omit) }}" + sharenfs: "{{ item.sharenfs | default(omit) }}" + checksum: "{{ item.checksum | default(omit) }}" + compression: "{{ item.compression | default(omit) }}" + atime: "{{ item.atime | default(omit) }}" + devices: "{{ item.devices | default(omit) }}" + exec: "{{ item.exec | default(omit) }}" + setuid: "{{ item.setuid | default(omit) }}" + readonly: "{{ item.readonly | default(omit) }}" + zoned: "{{ item.zoned | default(omit) }}" + snapdir: "{{ item.snapdir | default(omit) }}" + aclmode: "{{ item.aclmode | default(omit) }}" + aclinherit: "{{ item.aclinherit | default(omit) }}" + canmount: "{{ item.canmount | default(omit) }}" + xattr: "{{ item.xattr | default(omit) }}" + copies: "{{ item.copies | default(omit) }}" + vscan: "{{ item.vscan | default(omit) }}" + nbmand: "{{ item.nbmand | default(omit) }}" + sharesmb: "{{ item.sharesmb | default(omit) }}" + refquota: "{{ item.refquota | default(omit) }}" + refreservation: "{{ item.refreservation | default(omit) }}" + primarycache: "{{ item.primarycache | default(omit) }}" + secondarycache: "{{ item.secondarycache | default(omit) }}" + logbias: "{{ item.logbias | default(omit) }}" + dedup: "{{ item.dedup | default(omit) }}" + mlslabel: "{{ item.mlslabel | default(omit) }}" + sync: "{{ item.sync | default(omit) }}" + dnodesize: "{{ item.dnodesize | default(omit) }}" + volmode: "{{ item.volmode | default(omit) }}" + filesystem_limit: "{{ item.filesystem_limit | default(omit) }}" + snapshot_limit: "{{ item.snapshot_limit | default(omit) }}" + filesystem_count: "{{ item.filesystem_count | default(omit) }}" + snapshot_count: "{{ item.snapshot_count | default(omit) }}" + snapdev: "{{ item.snapdev | default(omit) }}" + acltype: "{{ item.acltype | default(omit) }}" + context: "{{ item.context | default(omit) }}" + fscontext: "{{ item.fscontext | default(omit) }}" + defcontext: "{{ item.defcontext | default(omit) }}" + rootcontext: "{{ item.rootcontext | default(omit) }}" + relatime: "{{ item.relatime | default(omit) }}" + redundant_metadata: "{{ item.redundant_metadata | default(omit) }}" + overlay: "{{ item.overlay | default(omit) }}" + encryption: "{{ item.encryption | default(omit) }}" + keylocation: "{{ item.keylocation | default(omit) }}" + keyformat: "{{ item.keyformat | default(omit) }}" + pbkdf2iters: "{{ item.pbkdf2iters | default(omit) }}" + special_small_blocks: "{{ item.special_small_blocks | default(omit) }}" + loop: "{{ zfs_datasets }}" + when: zfs_datasets is defined # führe nur aus wenn die Variable gesetzt ist diff --git a/roles/mgrote.zfs_packages/README.md b/roles/mgrote_zfs_packages/README.md similarity index 100% rename from roles/mgrote.zfs_packages/README.md rename to roles/mgrote_zfs_packages/README.md diff --git a/roles/mgrote_zfs_packages/tasks/main.yml b/roles/mgrote_zfs_packages/tasks/main.yml new file mode 100644 index 00000000..bef23d0c --- /dev/null +++ b/roles/mgrote_zfs_packages/tasks/main.yml @@ -0,0 +1,9 @@ +--- +- name: install zfs-tools-packages + become: true + ansible.builtin.package: + name: + - zfsutils + - zfs-initramfs + - zfs-zed + state: present diff --git a/roles/mgrote.zfs_sanoid/README.md b/roles/mgrote_zfs_sanoid/README.md similarity index 98% rename from roles/mgrote.zfs_sanoid/README.md rename to roles/mgrote_zfs_sanoid/README.md index 629de03d..70b9f6cd 100644 --- a/roles/mgrote.zfs_sanoid/README.md +++ b/roles/mgrote_zfs_sanoid/README.md @@ -23,7 +23,7 @@ Es gibt 3 Funktionen: --- - hosts: host1,host2 roles: - - { role: mgrote.zfs_sanoid, tags: "sanoid" } + - { role: mgrote_zfs_sanoid, tags: "sanoid" } ``` ### Beispiel - Snapshots erstellen diff --git a/roles/mgrote.zfs_sanoid/defaults/main.yml b/roles/mgrote_zfs_sanoid/defaults/main.yml similarity index 50% rename from roles/mgrote.zfs_sanoid/defaults/main.yml rename to roles/mgrote_zfs_sanoid/defaults/main.yml index 97bd8f52..6c218b35 100644 --- a/roles/mgrote.zfs_sanoid/defaults/main.yml +++ b/roles/mgrote_zfs_sanoid/defaults/main.yml @@ -1,10 +1,10 @@ --- - ### when should sanoid be run (every 5 minutes) - sanoid_timer: '*-*-* *:00/5' - ### when should syncoid be run - sanoid_syncoid_timer: '*-*-* *:00:00' - ### where to download the package - sanoid_deb_url: http://docker10.grote.lan:3344/sanoid_3.0.0.deb +### when should sanoid be run (every 5 minutes) +sanoid_timer: '*-*-* *:00/5' +### when should syncoid be run +sanoid_syncoid_timer: '*-*-* *:00:00' +### where to download the package +sanoid_deb_url: http://docker10.grote.lan:3344/sanoid_3.0.0.deb # ### "Default" Datasets # sanoid_datasets: # dictionary @@ -27,26 +27,26 @@ # autosnap: 'yes' # Automatisches erstellen von Snapshots # autoprune: 'yes' - ### user and group for sanoid - sanoid_user: sanoid - sanoid_user_group: sanoid +### user and group for sanoid +sanoid_user: sanoid +sanoid_user_group: sanoid - ### enable/disable features - ## enable snapshotting - # sanoid_snaps_enable: true - ## enable sending snaps - # sanoid_syncoid_source_host: true - ## enable receiving snaps - # sanoid_syncoid_destination_host: true +### enable/disable features +## enable snapshotting +# sanoid_snaps_enable: true +## enable sending snaps +# sanoid_syncoid_source_host: true +## enable receiving snaps +# sanoid_syncoid_destination_host: true - # syncoid - #sanoid_syncoid_ssh_privkey: "{{ lookup('keepass', 'sanoid_syncoid_private_key', 'notes') }}" - #sanoid_syncoid_ssh_pubkey: "{{ lookup('keepass', 'sanoid_syncoid_public_key', 'notes') }}" +# syncoid +#sanoid_syncoid_ssh_privkey: "{{ lookup('keepass', 'sanoid_syncoid_private_key', 'notes') }}" +#sanoid_syncoid_ssh_pubkey: "{{ lookup('keepass', 'sanoid_syncoid_public_key', 'notes') }}" - ### mgrote.sanoid - #sanoid_syncoid_datasets_sync: - # - source_host: pve5.grote.lan - # source_dataset: hdd_data_raidz/tmp - # destination_mount_check: hdd_data_raidz/tmp # zielpool - # destination_dataset: backup/pve5/tmp +### mgrote.sanoid +#sanoid_syncoid_datasets_sync: +# - source_host: pve5.grote.lan +# source_dataset: hdd_data_raidz/tmp +# destination_mount_check: hdd_data_raidz/tmp # zielpool +# destination_dataset: backup/pve5/tmp diff --git a/roles/mgrote_zfs_sanoid/handlers/main.yml b/roles/mgrote_zfs_sanoid/handlers/main.yml new file mode 100644 index 00000000..ab3f5feb --- /dev/null +++ b/roles/mgrote_zfs_sanoid/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true diff --git a/roles/mgrote_zfs_sanoid/tasks/destination.yml b/roles/mgrote_zfs_sanoid/tasks/destination.yml new file mode 100644 index 00000000..9cb40daf --- /dev/null +++ b/roles/mgrote_zfs_sanoid/tasks/destination.yml @@ -0,0 +1,77 @@ +--- +- name: template ssh private key + become: true + ansible.builtin.copy: + content: "{{ sanoid_syncoid_ssh_privkey }}" + dest: "/etc/sanoid/.ssh/id_sanoid" + owner: "{{ sanoid_user }}" + group: "{{ sanoid_user_group }}" + mode: "0400" + no_log: true + when: + - sanoid_syncoid_destination_host + +- name: add user to sudoers + become: true + ansible.builtin.blockinfile: + path: /etc/sudoers + state: present + block: | + {{ sanoid_user }} ALL=(ALL) NOPASSWD:ALL + validate: '/usr/sbin/visudo -cf %s' + backup: true + marker_begin: sanoid-sudoers BEGIN + marker_end: sanoid-sudoers END + when: + - sanoid_syncoid_destination_host + +- name: template syncoid.service + become: true + ansible.builtin.template: + src: "syncoid.service.j2" + dest: /etc/systemd/system/syncoid.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + when: + - sanoid_syncoid_destination_host + +- name: template syncoid_mail.service + become: true + ansible.builtin.template: + src: "syncoid_mail.service.j2" + dest: /etc/systemd/system/syncoid_mail.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + when: + - sanoid_syncoid_destination_host + +- name: template syncoid.timer + become: true + ansible.builtin.template: + src: "syncoid.timer.j2" + dest: "/etc/systemd/system/syncoid.timer" + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + when: + - sanoid_syncoid_destination_host + +- name: enable syncoid.timer + become: true + ansible.builtin.systemd: + name: "syncoid.timer" + enabled: true + masked: false + state: started + notify: + - systemctl daemon-reload + when: + - sanoid_syncoid_destination_host diff --git a/roles/mgrote_zfs_sanoid/tasks/main.yml b/roles/mgrote_zfs_sanoid/tasks/main.yml new file mode 100644 index 00000000..3379cf3b --- /dev/null +++ b/roles/mgrote_zfs_sanoid/tasks/main.yml @@ -0,0 +1,64 @@ +--- +- name: include user tasks + ansible.builtin.include_tasks: user.yml + +- name: install packages from repo + become: true + ansible.builtin.apt: + name: + - mbuffer + - lzop + - libcapture-tiny-perl + - pv + state: present + +- name: install packages from self-build + become: true + ansible.builtin.apt: + deb: "{{ sanoid_deb_url }}" + state: present + +- name: create sanoid directories + become: true + ansible.builtin.file: + path: "{{ item }}" + state: directory + owner: "{{ sanoid_user }}" + group: "{{ sanoid_user_group }}" + mode: "0700" + with_items: + - "/etc/sanoid" + - "/etc/sanoid/.ssh" + +- name: include snaps tasks + ansible.builtin.include_tasks: snaps.yml + when: + - sanoid_datasets is defined + - sanoid_templates is defined + - sanoid_snaps_enable is defined + - sanoid_snaps_enable + +- name: ensure service are started + become: true + ansible.builtin.systemd: + state: started + name: "{{ item }}" + daemon_reload: true + masked: false + enabled: true + loop: + - sanoid.service + - sanoid-prune.service + - sanoid.timer + +- name: include source-host tasks + ansible.builtin.include_tasks: source.yml + when: + - sanoid_syncoid_source_host is defined and sanoid_syncoid_source_host is true + - sanoid_syncoid_ssh_pubkey is defined + +- name: include destination-host tasks + ansible.builtin.include_tasks: destination.yml + when: + - sanoid_syncoid_destination_host is defined and sanoid_syncoid_destination_host is true + - sanoid_syncoid_ssh_privkey is defined diff --git a/roles/mgrote_zfs_sanoid/tasks/snaps.yml b/roles/mgrote_zfs_sanoid/tasks/snaps.yml new file mode 100644 index 00000000..86e3ab6f --- /dev/null +++ b/roles/mgrote_zfs_sanoid/tasks/snaps.yml @@ -0,0 +1,49 @@ +--- +- name: Generate Sanoid Configuration + become: true + ansible.builtin.template: + src: sanoid.conf.j2 + dest: "/etc/sanoid/sanoid.conf" + owner: "{{ sanoid_user }}" + group: "{{ sanoid_user_group }}" + mode: "0400" + +- name: template sanoid_mail.service + become: true + ansible.builtin.template: + src: "sanoid_mail.service.j2" + dest: /etc/systemd/system/sanoid_mail.service + owner: root + group: root + mode: "0644" + notify: + - systemctl daemon-reload + +- name: add sanoid_mail.service to sanoid.service + become: true + ansible.builtin.blockinfile: + create: true + mode: "0644" + owner: root + group: root + path: /lib/systemd/system/sanoid.service.d/override.conf + block: | + [Unit] + OnFailure = sanoid_mail.service + notify: + - systemctl daemon-reload + +- name: set timer + become: true + ansible.builtin.blockinfile: + create: true + mode: "0644" + owner: root + group: root + path: /lib/systemd/system/sanoid.timer.d/override.conf + block: | + [Timer] + OnCalendar = {{ sanoid_timer }} + when: sanoid_timer is defined + notify: + - systemctl daemon-reload diff --git a/roles/mgrote_zfs_sanoid/tasks/source.yml b/roles/mgrote_zfs_sanoid/tasks/source.yml new file mode 100644 index 00000000..1a769cd3 --- /dev/null +++ b/roles/mgrote_zfs_sanoid/tasks/source.yml @@ -0,0 +1,23 @@ +--- +- name: template ssh public key + become: true + ansible.posix.authorized_key: + user: "{{ sanoid_user }}" + key: "{{ sanoid_syncoid_ssh_pubkey }}" + state: present + when: + - sanoid_syncoid_source_host + +- name: add user to sudoers + become: true + ansible.builtin.blockinfile: + path: /etc/sudoers + state: present + block: | + {{ sanoid_user }} ALL=(ALL) NOPASSWD:ALL + validate: '/usr/sbin/visudo -cf %s' + backup: true + marker_begin: sanoid-sudoers BEGIN + marker_end: sanoid-sudoers END + when: + - sanoid_syncoid_source_host diff --git a/roles/mgrote_zfs_sanoid/tasks/user.yml b/roles/mgrote_zfs_sanoid/tasks/user.yml new file mode 100644 index 00000000..541c63a2 --- /dev/null +++ b/roles/mgrote_zfs_sanoid/tasks/user.yml @@ -0,0 +1,19 @@ +--- +- name: ensure group exists + become: true + ansible.builtin.group: + name: "{{ sanoid_user_group }}" + state: present + when: + - sanoid_user_group is defined + - sanoid_user is defined + +- name: ensure user exists + become: true + ansible.builtin.user: + name: "{{ sanoid_user }}" + group: "{{ sanoid_user_group }}" + create_home: true + when: + - sanoid_user_group is defined + - sanoid_user is defined diff --git a/roles/mgrote.zfs_sanoid/templates/sanoid.conf.j2 b/roles/mgrote_zfs_sanoid/templates/sanoid.conf.j2 similarity index 100% rename from roles/mgrote.zfs_sanoid/templates/sanoid.conf.j2 rename to roles/mgrote_zfs_sanoid/templates/sanoid.conf.j2 diff --git a/roles/mgrote.zfs_sanoid/templates/sanoid_mail.service.j2 b/roles/mgrote_zfs_sanoid/templates/sanoid_mail.service.j2 similarity index 100% rename from roles/mgrote.zfs_sanoid/templates/sanoid_mail.service.j2 rename to roles/mgrote_zfs_sanoid/templates/sanoid_mail.service.j2 diff --git a/roles/mgrote.zfs_sanoid/templates/syncoid.service.j2 b/roles/mgrote_zfs_sanoid/templates/syncoid.service.j2 similarity index 100% rename from roles/mgrote.zfs_sanoid/templates/syncoid.service.j2 rename to roles/mgrote_zfs_sanoid/templates/syncoid.service.j2 diff --git a/roles/mgrote.zfs_sanoid/templates/syncoid.timer.j2 b/roles/mgrote_zfs_sanoid/templates/syncoid.timer.j2 similarity index 100% rename from roles/mgrote.zfs_sanoid/templates/syncoid.timer.j2 rename to roles/mgrote_zfs_sanoid/templates/syncoid.timer.j2 diff --git a/roles/mgrote.zfs_sanoid/templates/syncoid_mail.service.j2 b/roles/mgrote_zfs_sanoid/templates/syncoid_mail.service.j2 similarity index 100% rename from roles/mgrote.zfs_sanoid/templates/syncoid_mail.service.j2 rename to roles/mgrote_zfs_sanoid/templates/syncoid_mail.service.j2 diff --git a/roles/mgrote.zfs_scrub/README.md b/roles/mgrote_zfs_scrub/README.md similarity index 100% rename from roles/mgrote.zfs_scrub/README.md rename to roles/mgrote_zfs_scrub/README.md diff --git a/roles/mgrote_zfs_scrub/defaults/main.yml b/roles/mgrote_zfs_scrub/defaults/main.yml new file mode 100644 index 00000000..31569546 --- /dev/null +++ b/roles/mgrote_zfs_scrub/defaults/main.yml @@ -0,0 +1,2 @@ +--- +zfs_extra_path_zpool: "/usr/sbin/zpool" diff --git a/roles/mgrote_zfs_scrub/tasks/main.yml b/roles/mgrote_zfs_scrub/tasks/main.yml new file mode 100644 index 00000000..bfe0fa72 --- /dev/null +++ b/roles/mgrote_zfs_scrub/tasks/main.yml @@ -0,0 +1,84 @@ +--- +- name: template unit-template + become: true + ansible.builtin.template: + src: zpool-scrub@.service.j2 + dest: /etc/systemd/system/zpool-scrub@.service + owner: root + group: root + mode: "0644" + register: template_unit + +- name: template timer + become: true + ansible.builtin.template: + src: zpool-scrub@.timer.j2 + dest: "/etc/systemd/system/zpool-scrub@{{ item.name }}.timer" + owner: root + group: root + mode: "0644" + loop: "{{ zfs_extra_zfs_pools }}" + register: template_timer + +- name: template mail.service + become: true + ansible.builtin.template: + src: zpool-scrub-mail.service.j2 + dest: "/etc/systemd/system/zpool-scrub-mail.service" + owner: root + group: root + mode: "0644" + register: template_mail + +- name: systemctl daemon-reload + become: true + ansible.builtin.systemd: + daemon_reload: true + when: + - template_unit.changed + - template_timer.changed + +- name: systemctl enable units - timer + become: true + ansible.builtin.systemd: + name: "zpool-scrub@{{ item.name }}.timer" + enabled: true + masked: false + loop: "{{ zfs_extra_zfs_pools }}" + when: + - template_unit.changed + - template_timer.changed + +- name: systemctl enable units - mail + become: true + ansible.builtin.systemd: + name: "zpool-scrub-mail.service" + enabled: true + masked: false + when: + - template_mail + +- name: systemctl start units + become: true + ansible.builtin.systemd: + name: "zpool-scrub@{{ item.name }}.timer" + state: restarted + enabled: true + loop: "{{ zfs_extra_zfs_pools }}" + when: + - template_unit.changed + - template_timer.changed + +- name: remove old cronjobs + become: true + ansible.builtin.cron: + name: zfs-scrub - "{{ item.name }}" + state: absent + with_items: "{{ zfs_extra_zfs_pools }}" + +- name: remove proxmox system scrub job #https://forum.proxmox.com/threads/script-sequential-zfs-scrub-for-cron.25124/ + become: true + ansible.builtin.lineinfile: + path: /etc/cron.d/zfsutils-linux + state: absent + line: '24 0 8-14 * * root if [ $(date +\%w) -eq 0 ] && [ -x /usr/lib/zfs-linux/scrub ]; then /usr/lib/zfs-linux/scrub; fi' diff --git a/roles/mgrote.zfs_scrub/templates/zpool-scrub-mail.service.j2 b/roles/mgrote_zfs_scrub/templates/zpool-scrub-mail.service.j2 similarity index 100% rename from roles/mgrote.zfs_scrub/templates/zpool-scrub-mail.service.j2 rename to roles/mgrote_zfs_scrub/templates/zpool-scrub-mail.service.j2 diff --git a/roles/mgrote.zfs_scrub/templates/zpool-scrub@.service.j2 b/roles/mgrote_zfs_scrub/templates/zpool-scrub@.service.j2 similarity index 100% rename from roles/mgrote.zfs_scrub/templates/zpool-scrub@.service.j2 rename to roles/mgrote_zfs_scrub/templates/zpool-scrub@.service.j2 diff --git a/roles/mgrote.zfs_scrub/templates/zpool-scrub@.timer.j2 b/roles/mgrote_zfs_scrub/templates/zpool-scrub@.timer.j2 similarity index 100% rename from roles/mgrote.zfs_scrub/templates/zpool-scrub@.timer.j2 rename to roles/mgrote_zfs_scrub/templates/zpool-scrub@.timer.j2 diff --git a/roles/mgrote.zfs_zed/README.md b/roles/mgrote_zfs_zed/README.md similarity index 100% rename from roles/mgrote.zfs_zed/README.md rename to roles/mgrote_zfs_zed/README.md diff --git a/roles/mgrote_zfs_zed/handlers/main.yml b/roles/mgrote_zfs_zed/handlers/main.yml new file mode 100644 index 00000000..e1fe92f7 --- /dev/null +++ b/roles/mgrote_zfs_zed/handlers/main.yml @@ -0,0 +1,5 @@ +--- +- name: testmail # noqa no-changed-when + ansible.builtin.shell: + cmd: "set -o pipefail && echo 'zed ist eingerichtet' | mail -s '{{ ansible_hostname }} - zed' '{{ empfaenger_mail }}'" + executable: /bin/bash diff --git a/roles/mgrote_zfs_zed/tasks/main.yml b/roles/mgrote_zfs_zed/tasks/main.yml new file mode 100644 index 00000000..69e817df --- /dev/null +++ b/roles/mgrote_zfs_zed/tasks/main.yml @@ -0,0 +1,9 @@ +--- +- name: kopiere zed.rc + become: true + ansible.builtin.template: + owner: root + mode: "0600" + src: zed.rc + dest: /etc/zfs/zed.d/zed.rc + notify: testmail diff --git a/roles/mgrote.zfs_zed/templates/zed.rc b/roles/mgrote_zfs_zed/templates/zed.rc similarity index 100% rename from roles/mgrote.zfs_zed/templates/zed.rc rename to roles/mgrote_zfs_zed/templates/zed.rc diff --git a/roles/mrlesmithjr.ansible-manage-lvm/molecule/default/converge.yml b/roles/mrlesmithjr.ansible-manage-lvm/molecule/default/converge.yml index 119de5da..d84b3a1a 100644 --- a/roles/mrlesmithjr.ansible-manage-lvm/molecule/default/converge.yml +++ b/roles/mrlesmithjr.ansible-manage-lvm/molecule/default/converge.yml @@ -5,7 +5,7 @@ lvm_groups: - vgname: my_vg disks: - - /dev/sdb1 + - /dev/sdb1 create: true lvnames: - lvname: my_lv diff --git a/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvm/converge.yml b/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvm/converge.yml index ab055c73..87ca2333 100644 --- a/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvm/converge.yml +++ b/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvm/converge.yml @@ -5,7 +5,7 @@ lvm_groups: - vgname: my_vg disks: - - /dev/vdb + - /dev/vdb create: true lvnames: - lvname: my_lv diff --git a/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmonlyvg/converge.yml b/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmonlyvg/converge.yml index be123c46..7842c033 100644 --- a/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmonlyvg/converge.yml +++ b/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmonlyvg/converge.yml @@ -5,7 +5,7 @@ lvm_groups: - vgname: my_vg disks: - - /dev/vdb + - /dev/vdb create: true manage_lvm: true tasks: diff --git a/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmsinglelv/converge.yml b/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmsinglelv/converge.yml index 09d88bd8..e87c325c 100644 --- a/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmsinglelv/converge.yml +++ b/roles/mrlesmithjr.ansible-manage-lvm/molecule/kvmsinglelv/converge.yml @@ -5,7 +5,7 @@ lvm_groups: - vgname: my_vg disks: - - /dev/vdb + - /dev/vdb create: true lvnames: - lvname: my_lv diff --git a/roles/mrlesmithjr.ansible-manage-lvm/playbook.yml b/roles/mrlesmithjr.ansible-manage-lvm/playbook.yml index 6b69e5ae..93babde1 100644 --- a/roles/mrlesmithjr.ansible-manage-lvm/playbook.yml +++ b/roles/mrlesmithjr.ansible-manage-lvm/playbook.yml @@ -4,8 +4,8 @@ lvm_groups: - vgname: test-vg disks: - - /dev/sdb - - /dev/sdc + - /dev/sdb + - /dev/sdc create: true lvnames: - lvname: test_1