diff --git a/roles/calibre/tasks/debs.yml b/roles/calibre/tasks/debs.yml index 797b2bb57..23504f511 100644 --- a/roles/calibre/tasks/debs.yml +++ b/roles/calibre/tasks/debs.yml @@ -28,8 +28,9 @@ # when: is_rpi and internet_available - name: Upgrade to latest Calibre using .deb's from testing (rpi) - #command: scripts/calibre-install-latest-rpi-plus.sh # NEC FOR Calibre 3.27.1 on 2018-07-22 (#948 -> PR #950) THO NOT BOOTABLE IN Zero W (#952). Similar to Calibre 3.24.x & 3.25 in June 2018, which had used calibre-install-packages.sh then Debian's own calibre-install-latest.sh - command: scripts/calibre-install-latest-rpi.sh # WORKS for Calibre 3.28 on 2018-07-26 (PR #971). Likewise for Calibre 3.26.x + #command: scripts/calibre-install-latest-rpi-plus.sh # WORKS for Calibre 3.27.1 on 2018-07-22 (#948 -> PR #950) THO NOT BOOTABLE IN Zero W (#952). Similar to Calibre 3.24.x & 3.25 in June 2018, which had used calibre-install-packages.sh then Debian's own calibre-install-latest.sh + #command: scripts/calibre-install-latest-rpi.sh # WORKS for Calibre 3.28 on 2018-07-26 (PR #971). Likewise for Calibre 3.26.x + command: scripts/calibre-install-latest.sh # REQUIRED for Calibre 3.29 on 2018-08-21 (PR #1015), as all above strategies failed (only script that was not attempted: Sid-like calibre-install-unstable.sh). CLARIF: RESULTING microSD's ARE NOT BOOTABLE IN Zero W (#952) when: is_rpi and internet_available - name: Upgrade to Calibre testing .deb's - target Ubuntu 16.04 (not rpi and not ubuntu_18) diff --git a/roles/httpd/tasks/html.yml b/roles/httpd/tasks/html.yml index d6ea61dc3..df00e4266 100644 --- a/roles/httpd/tasks/html.yml +++ b/roles/httpd/tasks/html.yml @@ -1,4 +1,4 @@ -- name: Copy css files +- name: Copy css files to /library/www/html/common/css copy: src: "{{ item }}" dest: "{{ doc_root }}/common/css" @@ -8,7 +8,7 @@ with_fileglob: - html/css/*.css -- name: Copy js files +- name: Copy js files to /library/www/html/common/js copy: src: "{{ item }}" dest: "{{ doc_root }}/common/js" @@ -18,7 +18,7 @@ with_fileglob: - html/js/*.js -- name: Copy fonts files +- name: Copy fonts files to /library/www/html/common/fonts copy: src: "{{ item }}" dest: "{{ doc_root }}/common/fonts" @@ -28,7 +28,7 @@ with_fileglob: - html/fonts/* -- name: Copy html files +- name: Copy html files to /library/www/html/common/html copy: src: "{{ item }}" dest: "{{ doc_root }}/common/html" @@ -38,7 +38,7 @@ with_fileglob: - html/html/* -- name: Copy assets files +- name: Copy assets files to /library/www/html/common/assets copy: src: "{{ item }}" dest: "{{ doc_root }}/common/assets" @@ -49,7 +49,7 @@ - html/assets/* # copy all services, even if not permissioned elsewhere -- name: Copy services files +- name: Copy services files to /library/www/html/common/services copy: src: "{{ item }}" dest: "{{ doc_root }}/common/services" @@ -59,7 +59,7 @@ with_fileglob: - html/services/* -- name: Create symlink from assets to iiab.ini +- name: Create symlink from assets to /etc/iiab/iiab.ini file: src: "/etc/iiab/iiab.ini" dest: "{{ doc_root }}/common/assets/iiab.ini" diff --git a/roles/httpd/tasks/main.yml b/roles/httpd/tasks/main.yml index ba5543dc5..797cbc05a 100644 --- a/roles/httpd/tasks/main.yml +++ b/roles/httpd/tasks/main.yml @@ -11,13 +11,14 @@ - download when: is_debian -- name: Debian changed sqlite name (debian-8) +- name: Debian changed SQLite name (debian-8) package: name: "php{{ php_version }}-sqlite" when: is_debian and ansible_distribution_major_version == "8" -- name: Debian changed sqlite name (debian-9) - package: name=php{{ php_version }}-sqlite3 +- name: Debian changed SQLite3 name (debian-9) + package: + name: "php{{ php_version }}-sqlite3" when: is_debian and ansible_distribution_major_version == "9" - name: Install httpd required packages (ubuntu) @@ -31,7 +32,7 @@ - download when: is_ubuntu -- name: Sqlite3 no longer included in another package in ubuntu18 +- name: SQLite3 no longer included in another package (ubuntu-18) package: name: php{{ php_version }}-sqlite3 when: is_ubuntu_18 @@ -50,11 +51,12 @@ - download when: is_redhat -- name: Remove the default apache2 config file (debuntu) - file: - path: /etc/apache2/sites-enabled/000-default.conf - state: absent - when: is_debuntu +# MOVED DOWN ~58 LINES +#- name: Remove the default apache2 config file (debuntu) +# file: +# path: /etc/apache2/sites-enabled/000-default.conf +# state: absent +# when: is_debuntu - name: Create httpd config files template: @@ -65,9 +67,9 @@ group: root mode: "{{ item.mode }}" with_items: - - { src: '010-iiab.conf.j2' , dest: '/etc/{{ apache_config_dir }}/010-iiab.conf', mode: '0755' } - - { src: 'proxy_ajp.conf.j2' , dest: '/etc/{{ apache_config_dir }}/proxy_ajp.conf', mode: '0644' } - - { src: 'php.ini.j2' , dest: '/etc/php.ini' , mode: '0644' } + - { src: '010-iiab.conf.j2', dest: '/etc/{{ apache_config_dir }}/010-iiab.conf', mode: '0755' } + - { src: 'proxy_ajp.conf.j2', dest: '/etc/{{ apache_config_dir }}/proxy_ajp.conf', mode: '0644' } + - { src: 'php.ini.j2', dest: '/etc/php.ini', mode: '0644' } # remove symlinks for mpm-event, replace with mpm-prefork - name: Remove mpm event links (debuntu) @@ -100,20 +102,23 @@ - name: Create symlinks for enabling our site (debuntu) file: - path: "/etc/apache2/sites-enabled/{{ item }}" + path: "/etc/apache2/sites-enabled/{{ item }}" # Not nec on Raspbian. Is this really still needed elsewhere? src: "/etc/apache2/sites-available/{{ item }}" state: link with_items: - 010-iiab.conf when: is_debuntu -- name: Remove the default site container (debuntu) +- name: Remove apache2 default config files (debuntu) file: - dest: /etc/apache2/000-default.conf + path: "{{ item }}" state: absent + with_items: + - /etc/apache2/000-default.conf + - /etc/apache2/sites-enabled/000-default.conf when: is_debuntu -- name: Create http pid dir +- name: Create http pid dir /var/run/{{ apache_user }} file: path: "/var/run/{{ apache_user }}" mode: 0755 @@ -126,14 +131,14 @@ name: admin state: present -- name: Add apache user to admin group +- name: Add {{ apache_user }} (from variable apache_user) to admin group user: name: "{{ apache_user }}" groups: admin state: present createhome: no -- name: Create httpd log dir +- name: Create httpd log dir /var/log/{{ apache_service }} file: path: "/var/log/{{ apache_service }}" mode: 0755 @@ -180,14 +185,14 @@ dest: /usr/bin/iiab-refresh-wiki-docs mode: 0755 -- name: Give apache_user permission for poweroff +- name: Give apache_user permission to poweroff template: src: 020_apache_poweroff.j2 dest: /etc/sudoers.d/020_apache_poweroff mode: 0755 when: allow_apache_sudo -- name: Remove apache_user permission for poweroff +- name: Remove apache_user permission to poweroff file: dest: /etc/sudoers.d/020_apache_poweroff state: absent diff --git a/roles/teamviewer/defaults/main.yml b/roles/teamviewer/defaults/main.yml index f66401b80..b3fc48ace 100644 --- a/roles/teamviewer/defaults/main.yml +++ b/roles/teamviewer/defaults/main.yml @@ -1,4 +1,4 @@ teamviewer_url: "{{ iiab_download_url }}" teamviewer_rpm_file: teamviewer_10.0.41499.i686.rpm -teamviewer_install: True +teamviewer_install: False teamviewer_enabled: False diff --git a/scripts/calibre-install-latest-rpi-plus.sh b/scripts/calibre-install-latest-rpi-plus.sh index cf9d5114c..7237f2b2b 100755 --- a/scripts/calibre-install-latest-rpi-plus.sh +++ b/scripts/calibre-install-latest-rpi-plus.sh @@ -12,7 +12,8 @@ # Thanks to Jerry Vonau (https://github.com/jvonau) who made this critical # breakthrough possible! # -# SEE COMMENTS AT THE TOP OF scripts/calibre-install-packages.sh +# Might break future updates; you have been warned. +# SEE NOTES AT TOP OF scripts/calibre-install-packages.sh export DEBIAN_FRONTEND=noninteractive diff --git a/scripts/calibre-install-latest-rpi.sh b/scripts/calibre-install-latest-rpi.sh index 869a4b64f..607592bbb 100755 --- a/scripts/calibre-install-latest-rpi.sh +++ b/scripts/calibre-install-latest-rpi.sh @@ -3,7 +3,8 @@ # Thanks to Jerry Vonau (https://github.com/jvonau) who made this critical # breakthrough possible! # -# SEE COMMENTS AT THE TOP OF scripts/calibre-install-packages.sh +# Might break future updates; you have been warned. +# SEE NOTES AT TOP OF scripts/calibre-install-packages.sh export DEBIAN_FRONTEND=noninteractive # Prepares to update to latest from raspbian testing diff --git a/scripts/calibre-install-latest.sh b/scripts/calibre-install-latest.sh index c8bf11ebd..363866335 100755 --- a/scripts/calibre-install-latest.sh +++ b/scripts/calibre-install-latest.sh @@ -1,9 +1,19 @@ #!/bin/bash +# Calibre 3.29 requires this approach, to overcome error: +# +# calibre-bin : Depends: qtbase-abi-5-10-0 but it is not installable +# E: Unable to correct problems, you have held broken packages. +# +# Above error proved insurmountable when trying most all scripts in /opt/iiab/iiab/scripts -- even those that DID solve this error: +# +# calibre : Depends: python-pyqt5 (>= 5.11.2+dfsg-1+b1) + # Thanks to Jerry Vonau (https://github.com/jvonau) who made this critical # breakthrough possible! # -# SEE COMMENTS AT THE TOP OF scripts/calibre-install-packages.sh +# Might break future updates; you have been warned. +# SEE NOTES AT TOP OF scripts/calibre-install-packages.sh export DEBIAN_FRONTEND=noninteractive # Drags in stock desktop dependencies without too much from testing below diff --git a/scripts/calibre-install-unstable.sh b/scripts/calibre-install-unstable.sh index 333985103..ab510bc5d 100755 --- a/scripts/calibre-install-unstable.sh +++ b/scripts/calibre-install-unstable.sh @@ -11,6 +11,7 @@ # http://archive.raspbian.org/raspbian/pool/main/c/calibre/ # # Might break future updates; you have been warned. +# SEE NOTES AT TOP OF scripts/calibre-install-packages.sh export DEBIAN_FRONTEND=noninteractive # Prepares to update to latest from unstable diff --git a/vars/default_vars.yml b/vars/default_vars.yml index 245bc85c3..e7a92d215 100644 --- a/vars/default_vars.yml +++ b/vars/default_vars.yml @@ -380,33 +380,33 @@ munin_enabled: False phpmyadmin_install: False phpmyadmin_enabled: False -# sugar-stats - unmaintained -sugar_stats_install: False -sugar_stats_enabled: False - -# TeamViewer - unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - # vnStat vnstat_install: True vnstat_enabled: False -# XOVis - unmaintained -xovis_install: False -xovis_enabled: False -xovis_target_host: "127.0.0.1:5984" -xovis_deployment_name: olpc -xovis_db_name: xovis -xovis_db_user: admin -xovis_db_password: admin - -xovis_root: "/opt/xovis" -xovis_backup_dir: "/library/users" -xovis_chart_heading: "My School: Usage Data Visualization" - # ================================================================ +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + +# sugar-stats - unmaintained +# sugar_stats_install: False +# sugar_stats_enabled: False + +# XOVis - unmaintained +# xovis_install: False +# xovis_enabled: False +# xovis_target_host: "127.0.0.1:5984" +# xovis_deployment_name: olpc +# xovis_db_name: xovis +# xovis_db_user: admin +# xovis_db_password: admin + +# xovis_root: "/opt/xovis" +# xovis_backup_dir: "/library/users" +# xovis_chart_heading: "My School: Usage Data Visualization" + # Ajenti - unmaintained # ajenti_install: False # ajenti_enabled: False @@ -419,9 +419,10 @@ xovis_chart_heading: "My School: Usage Data Visualization" # rachel_doc_root: "{{ doc_root }}/modules" # ================================================================ -# Platforms - turn all off and let .yml turn on as appropriate -# wide to narrow +# Platforms - turn all off and let /opt/iiab/iiab/vars/.yml turn on as appropriate + +# Wide to narrow is_debuntu: False is_ubuntu: False is_ubuntu_18: False diff --git a/vars/local_vars_big.yml b/vars/local_vars_big.yml index 603bd2901..3c30426bc 100644 --- a/vars/local_vars_big.yml +++ b/vars/local_vars_big.yml @@ -212,13 +212,13 @@ munin_enabled: True phpmyadmin_install: True phpmyadmin_enabled: False -# Unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - vnstat_install: True vnstat_enabled: True +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + # Unmaintained # sugar_stats_install: False # sugar_stats_enabled: False diff --git a/vars/local_vars_big_vpn.yml b/vars/local_vars_big_vpn.yml index 081ea50b5..393e84f86 100644 --- a/vars/local_vars_big_vpn.yml +++ b/vars/local_vars_big_vpn.yml @@ -212,13 +212,13 @@ munin_enabled: True phpmyadmin_install: True phpmyadmin_enabled: False -# Unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - vnstat_install: True vnstat_enabled: True +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + # Unmaintained # sugar_stats_install: False # sugar_stats_enabled: False diff --git a/vars/local_vars_medium.yml b/vars/local_vars_medium.yml index 9290dfee8..43f17384a 100644 --- a/vars/local_vars_medium.yml +++ b/vars/local_vars_medium.yml @@ -212,13 +212,13 @@ munin_enabled: True phpmyadmin_install: False phpmyadmin_enabled: False -# Unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - vnstat_install: True vnstat_enabled: True +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + # Unmaintained # sugar_stats_install: False # sugar_stats_enabled: False diff --git a/vars/local_vars_medium_vpn.yml b/vars/local_vars_medium_vpn.yml index 41f30edad..b78bc5f5a 100644 --- a/vars/local_vars_medium_vpn.yml +++ b/vars/local_vars_medium_vpn.yml @@ -212,13 +212,13 @@ munin_enabled: True phpmyadmin_install: False phpmyadmin_enabled: False -# Unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - vnstat_install: True vnstat_enabled: True +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + # Unmaintained # sugar_stats_install: False # sugar_stats_enabled: False diff --git a/vars/local_vars_min.yml b/vars/local_vars_min.yml index 2a6a7d2f4..78e53e111 100644 --- a/vars/local_vars_min.yml +++ b/vars/local_vars_min.yml @@ -212,13 +212,13 @@ munin_enabled: True phpmyadmin_install: False phpmyadmin_enabled: False -# Unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - vnstat_install: True vnstat_enabled: True +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + # Unmaintained # sugar_stats_install: False # sugar_stats_enabled: False diff --git a/vars/local_vars_min_vpn.yml b/vars/local_vars_min_vpn.yml index 349513bcf..a60ecaaff 100644 --- a/vars/local_vars_min_vpn.yml +++ b/vars/local_vars_min_vpn.yml @@ -212,13 +212,13 @@ munin_enabled: True phpmyadmin_install: False phpmyadmin_enabled: False -# Unmaintained (better to install from http://teamviewer.com) -teamviewer_install: False -teamviewer_enabled: False - vnstat_install: True vnstat_enabled: True +# Unmaintained (better to install from http://teamviewer.com or prep scripts at http://download.iiab.io) +# teamviewer_install: False +# teamviewer_enabled: False + # Unmaintained # sugar_stats_install: False # sugar_stats_enabled: False