From f98a2a63c35b209ae67e98aba485d5f79d7d4c2d Mon Sep 17 00:00:00 2001 From: Tanguy Herbron Date: Tue, 5 Dec 2023 10:02:01 +0100 Subject: [PATCH] fix(OMV): Enable SSH after installation and update version --- README.md | 4 ++++ node-configuration/handlers/main.yml | 1 + node-configuration/tasks/omv.yaml | 33 ++++++++++++++++++++++------ 3 files changed, 31 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index fb883bd..8d1ee2f 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,10 @@ Catalogue of Ansible playbooks and helper scripts for server management - Split user provisioning to get rid of `creator` and use `atmen` as fast as possible | This should be done using two differnt playbooks, and switch user between the two - Add configuration for `creator` to lock the account after initial provisioning, only allowing short connection with returned message +### Disable creator +Change `~/.profile` to only contain a print message and `exit 0` +Add `.hushlogin` to remove ssh login message + ## Node configuration process ### Setup user configuration - Create provisioning user without password and sudo diff --git a/node-configuration/handlers/main.yml b/node-configuration/handlers/main.yml index b450037..ef36d8f 100644 --- a/node-configuration/handlers/main.yml +++ b/node-configuration/handlers/main.yml @@ -5,3 +5,4 @@ name: sshd state: restarted listen: "restart sshd" + ignore_errors: yes diff --git a/node-configuration/tasks/omv.yaml b/node-configuration/tasks/omv.yaml index b4e9ef4..b824a3a 100644 --- a/node-configuration/tasks/omv.yaml +++ b/node-configuration/tasks/omv.yaml @@ -4,6 +4,18 @@ name: gnupg state: present +- name: Download OMV-extras + ansible.builtin.get_url: + url: https://github.com/OpenMediaVault-Plugin-Developers/installScript/raw/master/install + dest: /tmp/omv-extras.install + mode: u+rwx + +# B: Beta to enable installation on Debian 12 +# N: Skip networking installation +# F: Skip flashmemory plugin installation +- name: Install OMV-extras + ansible.builtin.shell: /tmp/omv-extras.install -n -f >> /tmp/omv-extras.log + # TODO: Only enable this within Homelab configuration - name: Add Vagrant user to ssh group ansible.builtin.user: @@ -17,11 +29,18 @@ groups: ssh append: yes -- name: Download OMV-extras - ansible.builtin.get_url: - url: https://github.com/OpenMediaVault-Plugin-Developers/installScript/raw/master/install - dest: /tmp/omv-extras.install - mode: u+rwx +- name: Upgrade packages + ansible.builtin.apt: + update_cache: yes + name: "*" + state: latest -- name: Install OMV-extras - ansible.builtin.shell: /tmp/omv-extras.install -n -f >> /tmp/omv-extras.log +- name: Install ZFS, S3 with Minio and Filebrowser + ansible.builtin.apt: + pkg: + - openmediavault-zfs + - openmediavault-s3 + - openmediavault-filebrowser + +- name: Reboot to enable ZFS module and finish upgrade + ansible.builtin.reboot: