From 773fc1dc0cc67967958e00eb39b6f1fda14bd74a Mon Sep 17 00:00:00 2001 From: A Holt Date: Thu, 20 Aug 2020 12:42:51 -0400 Subject: [PATCH 1/5] Create linuxmint-20.yml --- vars/linuxmint-20.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 vars/linuxmint-20.yml diff --git a/vars/linuxmint-20.yml b/vars/linuxmint-20.yml new file mode 100644 index 000000000..f58ba79ed --- /dev/null +++ b/vars/linuxmint-20.yml @@ -0,0 +1,29 @@ +is_debuntu: True +is_ubuntu: True +is_ubuntu_20: True + +# 2019-03-23: These apply if-only-if named_install and/or dhcpd_install are True +# (This is quite rare now that vars/default_vars.yml sets dnsmasq_install: True) +dns_service: bind9 +dns_user: bind +dhcp_service: isc-dhcp-server + +proxy: squid +proxy_user: proxy +apache_service: apache2 +apache_user: www-data +apache_conf_dir: apache2/sites-available +apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150 +apache_log_dir: /var/log/apache2 +smb_service: smbd +nmb_service: nmbd +systemctl_program: /bin/systemctl +# issue raised +mysql_service: mariadb +apache_log: /var/log/apache2/access.log +sshd_package: openssh-server +sshd_service: ssh +php_version: 7.4 +# "postgresql_version: 11.2" failed (too detailed for /etc/systemd/system/postgresql-iiab.service on Ubuntu 19.04) +postgresql_version: 12 +systemd_location: /lib/systemd/system From 39cc56369ec3e5fa0bd6bc088f7384848aef8a81 Mon Sep 17 00:00:00 2001 From: A Holt Date: Thu, 20 Aug 2020 12:51:17 -0400 Subject: [PATCH 2/5] Update local_facts.fact --- scripts/local_facts.fact | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/scripts/local_facts.fact b/scripts/local_facts.fact index 9f4143ce9..21c8727cf 100755 --- a/scripts/local_facts.fact +++ b/scripts/local_facts.fact @@ -22,24 +22,26 @@ DHCPCD_PATH=`which dhcpcd` NM_PATH=`which NetworkManager` case $OS_VER in - "fedora-18" | \ - "fedora-22" | \ - "debian-8" | \ - "debian-9" | \ - "debian-10" | \ - "ubuntu-16" | \ - "ubuntu-17" | \ - "ubuntu-18" | \ - "ubuntu-19" | \ - "ubuntu-20" | \ - "centos-7" | \ - "raspbian-8" | \ - "raspbian-9" | \ + "fedora-18" | \ + "fedora-22" | \ + "debian-8" | \ + "debian-9" | \ + "debian-10" | \ + "ubuntu-16" | \ + "ubuntu-17" | \ + "ubuntu-18" | \ + "ubuntu-19" | \ + "ubuntu-20" | \ + "linuxmint-20" | \ + "centos-7" | \ + "raspbian-8" | \ + "raspbian-9" | \ "raspbian-10") - ;; - *) OS_VER="OS_not_supported" - ;; + ;; + *) OS_VER="OS_not_supported" + ;; esac + # get current version BRANCH=`git rev-parse --abbrev-ref HEAD` COMMIT=`git rev-parse --verify HEAD` @@ -71,7 +73,7 @@ ANSIBLE_VERSION=$(ansible --version|head -n 1|cut -f 2 -d " ") if [ ! x$DHCPCD_PATH = x ]; then DHCPCD=`systemctl is-enabled dhcpcd` fi -# the check is debian family only is_redhad would use NetworkManager as the +# the check is debian family only is_redhat would use NetworkManager as the # service name. if [ ! x$NM_PATH = x ]; then NM=`systemctl is-enabled network-manager` From 7ce4c0dd9c301a19ac5f0bfd82dc6767e3559a4a Mon Sep 17 00:00:00 2001 From: A Holt Date: Fri, 21 Aug 2020 16:34:24 -0400 Subject: [PATCH 3/5] Rename ansible-2.8.x to ansible-2.8.x.deprecated --- scripts/{ansible-2.8.x => ansible-2.8.x.deprecated} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename scripts/{ansible-2.8.x => ansible-2.8.x.deprecated} (100%) diff --git a/scripts/ansible-2.8.x b/scripts/ansible-2.8.x.deprecated similarity index 100% rename from scripts/ansible-2.8.x rename to scripts/ansible-2.8.x.deprecated From 911b1cca73a710beea124223747b3a60df7db0b5 Mon Sep 17 00:00:00 2001 From: A Holt Date: Fri, 21 Aug 2020 16:34:40 -0400 Subject: [PATCH 4/5] Rename ansible-2.9.x to ansible-2.9.x.deprecated --- scripts/{ansible-2.9.x => ansible-2.9.x.deprecated} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename scripts/{ansible-2.9.x => ansible-2.9.x.deprecated} (100%) diff --git a/scripts/ansible-2.9.x b/scripts/ansible-2.9.x.deprecated similarity index 100% rename from scripts/ansible-2.9.x rename to scripts/ansible-2.9.x.deprecated From e87afe3f5fb2a72aa07287f8ee02411eb2b19218 Mon Sep 17 00:00:00 2001 From: A Holt Date: Fri, 21 Aug 2020 16:39:27 -0400 Subject: [PATCH 5/5] Avoid problematic /usr/local/bin/apt on Linux Mint --- scripts/ansible | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/scripts/ansible b/scripts/ansible index 427cee045..b884c1238 100755 --- a/scripts/ansible +++ b/scripts/ansible @@ -1,5 +1,6 @@ #!/bin/bash -e +APT_PATH=/usr/bin # Avoids problematic /usr/local/bin/apt on Linux Mint CURR_VER="undefined" # Ansible version you currently have installed GOOD_VER="2.9.6" # For XO laptops (pip install) & CentOS (yum install rpm) # On other OS's we attempt the latest from PPA, which might be more recent @@ -66,8 +67,8 @@ elif [ -f /etc/centos-release ]; then elif [ -f /etc/debian_version ]; then # Includes Debian, Ubuntu & Raspbian if ! grep -q focal /etc/os-release; then echo -e "\napt update; install dirmngr; PPA to /etc/apt/sources.list.d/iiab-ansible.list\n" - apt update - apt -y install dirmngr + $APT_PATH/apt update + $APT_PATH/apt -y install dirmngr echo "deb http://ppa.launchpad.net/ansible/ansible/ubuntu bionic main" \ > /etc/apt/sources.list.d/iiab-ansible.list @@ -90,8 +91,8 @@ elif [ -f /etc/debian_version ]; then # Includes Debian, Ubuntu & Raspbian fi echo -e "\napt update; apt install ansible and python3 dependencies explained at:" echo -e "https://github.com/iiab/iiab/tree/master/scripts/ansible.md\n" - apt update - apt -y --allow-downgrades install ansible python3-pymysql python3-psycopg2 \ + $APT_PATH/apt update + $APT_PATH/apt -y --allow-downgrades install ansible python3-pymysql python3-psycopg2 \ python3-passlib python3-pip python3-setuptools python3-venv virtualenv echo -e "\nSUCCESS: verify Ansible using 'ansible --version' and/or 'apt -a list ansible'\n\n"