1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-02-12 19:22:24 +00:00

Mostly var cleanup across ~80 files

This commit is contained in:
root 2020-01-30 04:00:00 -05:00
parent a6112381a3
commit 814efd5a02
88 changed files with 679 additions and 260 deletions

View file

@ -72,7 +72,7 @@
- name: Copy xs-activity-server config file - name: Copy xs-activity-server config file
template: src=xs-activity-server.conf template: src=xs-activity-server.conf
dest=/etc/{{ apache_config_dir }} dest=/etc/{{ apache_conf_dir }}
owner=root owner=root
group=root group=root
mode=0644 mode=0644

View file

@ -29,10 +29,10 @@
state: link state: link
force: yes force: yes
- name: Install /etc/{{ apache_config_dir }}/dokuwiki.conf from template, for DokuWiki's http://box{{ dokuwiki_url }} - name: Install /etc/{{ apache_conf_dir }}/dokuwiki.conf from template, for DokuWiki's http://box{{ dokuwiki_url }}
template: template:
src: dokuwiki.conf.j2 src: dokuwiki.conf.j2
dest: "/etc/{{ apache_config_dir }}/dokuwiki.conf" dest: "/etc/{{ apache_conf_dir }}/dokuwiki.conf"
# - name: Symlink /etc/apache2/sites-enabled/dokuwiki.conf to /etc/apache2/sites-available/dokuwiki.conf if dokuwiki_enabled (debuntu) # - name: Symlink /etc/apache2/sites-enabled/dokuwiki.conf to /etc/apache2/sites-available/dokuwiki.conf if dokuwiki_enabled (debuntu)
# file: # file:

View file

@ -9,7 +9,7 @@
- download - download
- name: Remove stock moodle conf - name: Remove stock moodle conf
file: path='/etc/{{ apache_config_dir }}/moodle.conf' file: path='/etc/{{ apache_conf_dir }}/moodle.conf'
state=absent state=absent
- name: Configure moodle - name: Configure moodle
@ -21,7 +21,7 @@
mode={{ item.mode }} mode={{ item.mode }}
with_items: with_items:
- src: '020-iiab-moodle.conf.j2' - src: '020-iiab-moodle.conf.j2'
dest: '/etc/{{ apache_config_dir }}/020-iiab-moodle.conf' dest: '/etc/{{ apache_conf_dir }}/020-iiab-moodle.conf'
mode: '0655' mode: '0655'
- src: 'moodle-xs.service.j2' - src: 'moodle-xs.service.j2'
dest: '/etc/systemd/system/moodle-xs.service' dest: '/etc/systemd/system/moodle-xs.service'

View file

@ -102,10 +102,10 @@
line: "path_to_virtualenv = '/usr/local/osm'" line: "path_to_virtualenv = '/usr/local/osm'"
state: present state: present
- name: Install /etc/{{ apache_config_dir }}/osm.conf from template - name: Install /etc/{{ apache_conf_dir }}/osm.conf from template
template: template:
src: osm.conf.j2 src: osm.conf.j2
dest: "/etc/{{ apache_config_dir }}/osm.conf" dest: "/etc/{{ apache_conf_dir }}/osm.conf"
owner: root owner: root
group: root group: root
mode: 0644 mode: 0644
@ -114,7 +114,7 @@
- name: Create softlink osm.conf from sites-enabled to sites-available (debuntu) - name: Create softlink osm.conf from sites-enabled to sites-available (debuntu)
file: file:
src: "/etc/{{ apache_config_dir }}/osm.conf" src: "/etc/{{ apache_conf_dir }}/osm.conf"
path: /etc/apache2/sites-enabled/osm.conf path: /etc/apache2/sites-enabled/osm.conf
state: link state: link
when: osm_enabled and is_debuntu when: osm_enabled and is_debuntu
@ -125,9 +125,9 @@
state: absent state: absent
when: not osm_enabled and is_debuntu when: not osm_enabled and is_debuntu
- name: Remove /{{ apache_config_dir }}/osm.conf (redhat) - name: Remove /{{ apache_conf_dir }}/osm.conf (redhat)
file: file:
path: "/{{ apache_config_dir }}/osm.conf" path: "/{{ apache_conf_dir }}/osm.conf"
state: absent state: absent
when: not osm_enabled and is_redhat when: not osm_enabled and is_redhat

View file

@ -7,7 +7,7 @@
- name: Enable owncloud by copying template to httpd config - name: Enable owncloud by copying template to httpd config
template: src=owncloud.conf.j2 template: src=owncloud.conf.j2
dest=/etc/{{ apache_config_dir }}/owncloud.conf dest=/etc/{{ apache_conf_dir }}/owncloud.conf
owner=root owner=root
group=root group=root
mode=0644 mode=0644

View file

@ -179,11 +179,11 @@
# group: root # group: root
# mode: '0644' # mode: '0644'
- name: Install /etc/{{ apache_config_dir }}/pathagar.conf from template - name: Install /etc/{{ apache_conf_dir }}/pathagar.conf from template
template: template:
src: pathagar.conf src: pathagar.conf
backup: yes backup: yes
dest: "/etc/{{ apache_config_dir }}/pathagar.conf" dest: "/etc/{{ apache_conf_dir }}/pathagar.conf"
mode: 0644 mode: 0644
- name: Enable Pathagar via Apache (debuntu) - name: Enable Pathagar via Apache (debuntu)

View file

@ -1,6 +1,6 @@
- name: Copy RACHEL httpd conf file - name: Copy RACHEL httpd conf file
template: src=rachel.conf.j2 template: src=rachel.conf.j2
dest=/etc/{{ apache_config_dir }}/rachel.conf dest=/etc/{{ apache_conf_dir }}/rachel.conf
- name: enable Rachel - name: enable Rachel
file: path=/etc/apache2/sites-enabled/rachel.conf file: path=/etc/apache2/sites-enabled/rachel.conf

View file

@ -18,7 +18,7 @@
- dest: '/etc/systemd/system/schooltool.service' - dest: '/etc/systemd/system/schooltool.service'
src: 'schooltool.service' src: 'schooltool.service'
mode: '0644' mode: '0644'
- dest: '/etc/{{ apache_config_dir }}/schooltool.conf' - dest: '/etc/{{ apache_conf_dir }}/schooltool.conf'
src: 'schooltool.conf' src: 'schooltool.conf'
mode: '0644' mode: '0644'

View file

@ -22,9 +22,9 @@
name: bluetooth name: bluetooth
when: is_rpi and bluetooth_install # or bluetooth_installed is defined when: is_rpi and bluetooth_install # or bluetooth_installed is defined
- name: USB-LIB - name: USB_LIB
include_role: include_role:
name: usb-lib name: usb_lib
when: usb_lib_install | bool when: usb_lib_install | bool
# This is in Stage 4-SERVER-OPTIONS (rather than 3-BASE-SERVER) because var # This is in Stage 4-SERVER-OPTIONS (rather than 3-BASE-SERVER) because var

View file

@ -30,10 +30,10 @@
- "{{ apache_log_dir }}" - "{{ apache_log_dir }}"
- /usr/lib/cgi-bin/awstats # create backward compatible path for awstats - /usr/lib/cgi-bin/awstats # create backward compatible path for awstats
- name: Install /etc/{{ apache_config_dir }}/awstats.conf from template - name: Install /etc/{{ apache_conf_dir }}/awstats.conf from template
template: template:
src: apache-awstats.conf src: apache-awstats.conf
dest: "/etc/{{ apache_config_dir }}/awstats.conf" dest: "/etc/{{ apache_conf_dir }}/awstats.conf"
- name: Install /etc/logrotate.d/apache2 from template, to ensure logrotate doesn't make logs unreadable - name: Install /etc/logrotate.d/apache2 from template, to ensure logrotate doesn't make logs unreadable
template: template:
@ -76,6 +76,13 @@
shell: /usr/bin/perl /usr/lib/cgi-bin/awstats.pl -config=schoolserver -update shell: /usr/bin/perl /usr/lib/cgi-bin/awstats.pl -config=schoolserver -update
# when: awstats_enabled | bool # when: awstats_enabled | bool
# RECORD AWStats AS INSTALLED
- name: "Set 'awstats_installed: True'"
set_fact:
awstats_installed: True
- name: "Add 'awstats_installed: True' to {{ iiab_state_file }}" - name: "Add 'awstats_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -64,6 +64,13 @@
args: args:
chdir: "{{ azuracast_host_dir }}" chdir: "{{ azuracast_host_dir }}"
# RECORD AzuraCast AS INSTALLED
- name: "Set 'azuracast_installed: True'"
set_fact:
azuracast_installed: True
- name: "Add 'azuracast_installed: True' to {{ iiab_state_file }}" - name: "Add 'azuracast_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -55,6 +55,13 @@
regexp: '^#DiscoverableTimeout' regexp: '^#DiscoverableTimeout'
line: 'DiscoverableTimeout = 0' line: 'DiscoverableTimeout = 0'
# RECORD Bluetooth AS INSTALLED
- name: "Set 'bluetooth_installed: True'"
set_fact:
bluetooth_installed: True
- name: "Add 'bluetooth_installed: True' to {{ iiab_state_file }}" - name: "Add 'bluetooth_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -35,17 +35,17 @@
# NGINX # NGINX
# TO DO: restore http://box/libros & http://box/livres, along English (http://box/books) # TO DO: restore http://box/libros & http://box/livres, alongside English (#2195)
- name: Enable http://box{{ calibreweb_url1 }} via NGINX, by installing {{ nginx_conf_dir }}/calibre-web-nginx.conf from template - name: Enable http://box{{ calibreweb_url1 }} via NGINX, by installing {{ nginx_conf_dir }}/calibre-web-nginx.conf from template # http://box/books
template: template:
src: calibre-web-nginx.conf.j2 src: calibre-web-nginx.conf.j2
dest: "{{ nginx_conf_dir }}/calibre-web-nginx.conf" dest: "{{ nginx_conf_dir }}/calibre-web-nginx.conf" # /etc/nginx/conf.d
when: nginx_install and calibreweb_enabled when: nginx_install and calibreweb_enabled
- name: Disable http://box{{ calibreweb_url1 }} via NGINX, by removing {{ nginx_conf_dir }}/calibre-web-nginx.conf - name: Disable http://box{{ calibreweb_url1 }} via NGINX, by removing {{ nginx_conf_dir }}/calibre-web-nginx.conf
file: file:
path: "{{ nginx_conf_dir }}/calibre-web-nginx.conf" path: "{{ nginx_conf_dir }}/calibre-web-nginx.conf" # /etc/nginx/conf.d
state: absent state: absent
when: nginx_install and not calibreweb_enabled when: nginx_install and not calibreweb_enabled

View file

@ -1,7 +1,6 @@
- name: Install ImageMagick (debuntu) - name: Install ImageMagick package (debuntu)
package: package:
name: name: imagemagick
- imagemagick
state: present state: present
when: is_debuntu | bool when: is_debuntu | bool
@ -14,12 +13,12 @@
state: present state: present
when: is_debuntu | bool when: is_debuntu | bool
- name: Create 3 Calibre-Web folders to store data and configuration files - name: "Create 3 Calibre-Web folders to store data and configuration files: {{ calibreweb_home }}, {{ calibreweb_venv_path }}, {{ calibreweb_config }}"
file: file:
path: "{{ item }}" path: "{{ item }}"
owner: "{{ calibreweb_user }}" owner: "{{ calibreweb_user }}"
group: "{{ apache_user }}" group: "{{ apache_user }}"
mode: 0755 mode: '0755'
state: directory state: directory
with_items: with_items:
- "{{ calibreweb_home }}" - "{{ calibreweb_home }}"
@ -67,10 +66,11 @@
dest: "{{ item.dest }}" dest: "{{ item.dest }}"
owner: root owner: root
group: root group: root
mode: 0644 mode: '0644'
with_items: with_items:
- { src: 'calibre-web.service.j2', dest: '/etc/systemd/system/calibre-web.service' } - { src: 'calibre-web.service.j2', dest: '/etc/systemd/system/calibre-web.service' }
- { src: 'calibre-web.conf.j2', dest: '/etc/apache2/sites-available/calibre-web.conf' } - { src: 'calibre-web.conf.j2', dest: '/etc/apache2/sites-available/calibre-web.conf' }
when: apache_install | bool
- name: Does /library/calibre-web/metadata.db exist? - name: Does /library/calibre-web/metadata.db exist?
stat: stat:
@ -83,7 +83,7 @@
dest: "{{ calibreweb_home }}" dest: "{{ calibreweb_home }}"
owner: "{{ calibreweb_user }}" owner: "{{ calibreweb_user }}"
group: "{{ apache_user }}" group: "{{ apache_user }}"
mode: 0644 mode: '0644'
backup: yes backup: yes
with_items: with_items:
- roles/calibre-web/files/metadata.db - roles/calibre-web/files/metadata.db
@ -97,11 +97,18 @@
dest: "{{ calibreweb_config }}" dest: "{{ calibreweb_config }}"
owner: "{{ calibreweb_user }}" owner: "{{ calibreweb_user }}"
group: "{{ apache_user }}" group: "{{ apache_user }}"
mode: 0644 mode: '0644'
backup: yes backup: yes
when: not metadatadb.stat.exists when: not metadatadb.stat.exists
#when: calibreweb_provision | bool #when: calibreweb_provision | bool
# RECORD Calibre-Web AS INSTALLED
- name: "Set 'calibreweb_installed: True'"
set_fact:
calibreweb_installed: True
- name: "Add 'calibreweb_installed: True' to {{ iiab_state_file }}" - name: "Add 'calibreweb_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -31,6 +31,9 @@
# - run testing branch for Ubuntu 16.04: scripts/calibre-install-latest.sh # - run testing branch for Ubuntu 16.04: scripts/calibre-install-latest.sh
# - run unstable branch for Debian etc: scripts/calibre-install-unstable.sh # - run unstable branch for Debian etc: scripts/calibre-install-unstable.sh
# 2. SYSTEMD SERVICES
- name: Create calibre-serve.service and calibre.conf (IF /usr/bin/calibre WAS MISSING) - name: Create calibre-serve.service and calibre.conf (IF /usr/bin/calibre WAS MISSING)
template: template:
src: "{{ item.src }}" src: "{{ item.src }}"
@ -42,7 +45,7 @@
#register: calibre_config #register: calibre_config
with_items: with_items:
- { src: 'calibre-serve.service.j2', dest: '/etc/systemd/system/calibre-serve.service', mode: '0644'} - { src: 'calibre-serve.service.j2', dest: '/etc/systemd/system/calibre-serve.service', mode: '0644'}
- { src: 'calibre.conf', dest: '/etc/{{ apache_config_dir }}', mode: '0644'} - { src: 'calibre.conf', dest: '/etc/{{ apache_conf_dir }}', mode: '0644'}
when: (not calib_executable.stat.exists) when: (not calib_executable.stat.exists)
- name: Stop service 'calibre-serve' (/usr/bin/calibre-server by Kovid Goyal) - name: Stop service 'calibre-serve' (/usr/bin/calibre-server by Kovid Goyal)
@ -51,6 +54,7 @@
state: stopped state: stopped
daemon_reload: yes daemon_reload: yes
# 3. CREATE USER DATABASE # 3. CREATE USER DATABASE
- name: Create /library/calibre (mandatory since Calibre 3.x) - name: Create /library/calibre (mandatory since Calibre 3.x)
@ -68,6 +72,7 @@
mode: 0644 mode: 0644
when: (not calib_executable.stat.exists) when: (not calib_executable.stat.exists)
# 4. CREATE CONTENT DATABASE WITH A SAMPLE BOOK (REQUIRED AS OF CALIBRE 3.x) # 4. CREATE CONTENT DATABASE WITH A SAMPLE BOOK (REQUIRED AS OF CALIBRE 3.x)
- name: Does /library/calibre/metadata.db exist? - name: Does /library/calibre/metadata.db exist?
@ -79,6 +84,13 @@
include_tasks: create-db.yml include_tasks: create-db.yml
when: not calibre_db.stat.exists when: not calibre_db.stat.exists
# 5. RECORD Calibre AS INSTALLED
- name: "Set 'calibre_installed: True'"
set_fact:
calibre_installed: True
- name: "Add 'calibre_installed: True' to {{ iiab_state_file }}" - name: "Add 'calibre_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -52,6 +52,13 @@
args: args:
creates: /etc/nginx/sites-available/capture.conf creates: /etc/nginx/sites-available/capture.conf
# RECORD Captive Portal AS INSTALLED
- name: "Set 'captiveportal_installed: True'"
set_fact:
captiveportal_installed: True
- name: "Add 'captiveportal_installed: True' to {{ iiab_state_file }}" - name: "Add 'captiveportal_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -19,7 +19,7 @@
quiet: yes quiet: yes
- name: Install Captive Portal if 'captiveportal_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml - name: Install Captive Portal if 'captiveportal_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml include_tasks: install.yml
when: captiveportal_installed is undefined when: captiveportal_installed is undefined

View file

@ -1,20 +1,33 @@
# administer this service by browsing to localhost:631 # Administer CUPS at http://box:631
# Above URL does NOT work over OpenVPN (ANYONE KNOW WHY?)
# TO DO:
# - validate input vars + prereqs
# - move 5 top stanzas into install.yml
# - move 5-7 next stanzas into enable-or-disable.yml
- name: Install 'cups' package - name: Install 'cups' package
package: package:
name: cups name: cups
state: present state: present
when: cups_install | bool
#tags: download
- name: Install our own /etc/cups/cupsd.conf from template, to permit local LAN admin - name: Install our own /etc/cups/cupsd.conf from template, to permit local LAN admin
template: template:
src: cupsd.conf src: cupsd.conf
dest: /etc/cups/cupsd.conf dest: /etc/cups/cupsd.conf
- name: Install /etc/{{ apache_config_dir }}/cups.conf from template - name: Install /etc/{{ apache_conf_dir }}/cups.conf from template
template: template:
src: cups.conf src: cups.conf
dest: "/etc/{{ apache_config_dir }}/" dest: "/etc/{{ apache_conf_dir }}/"
# RECORD CUPS AS INSTALLED
- name: "Set 'cups_installed: True'"
set_fact:
cups_installed: True
- name: "Add 'cups_installed: True' to {{ iiab_state_file }}" - name: "Add 'cups_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
@ -22,11 +35,16 @@
regexp: '^cups_installed' regexp: '^cups_installed'
line: 'cups_installed: True' line: 'cups_installed: True'
- name: Enable http://box/cups via Apache (MIGHT NOT WORK?) - name: Enable http://box/cups via Apache (MIGHT NOT WORK?)
command: a2ensite cups.conf command: a2ensite cups.conf
when: cups_enabled when: cups_enabled | bool
- name: Enable & Start services 'cups' and 'cups-browsed' (OS's other than Fedora 18) - name: Disable http://box/cups via Apache
command: a2dissite cups.conf
when: not cups_enabled
- name: Enable & Start 'cups' and 'cups-browsed' systemd services (OS's other than Fedora 18)
service: service:
name: "{{ item }}" name: "{{ item }}"
state: started state: started
@ -36,34 +54,35 @@
- cups-browsed - cups-browsed
when: cups_enabled and not is_F18 when: cups_enabled and not is_F18
- name: Enable & Start service 'cups' (Fedora 18, for XO laptops) - name: Enable & Start 'cups' systemd service (Fedora 18, for XO laptops)
systemd: systemd:
name: cups name: cups
state: started state: started
enabled: yes enabled: yes
when: cups_enabled and is_F18 when: cups_enabled and is_F18
- name: Permit headless admin of CUPS -- only works when CUPS daemon is running - name: Permit headless admin of CUPS -- only works when CUPS daemon is running, if cups_enabled
shell: "cupsctl --remote-admin" shell: "cupsctl --remote-admin"
when: cups_enabled | bool when: cups_enabled | bool
- name: Disable both CUPS services (OS's other than Fedora 18) - name: Disable & Stop 'cups' & 'cups-browsed' systemd services (OS's other than Fedora 18)
systemd: systemd:
name: "{{ item }}" name: "{{ item }}"
state: stopped
enabled: no enabled: no
state: stopped
with_items: with_items:
- cups - cups
- cups-browsed - cups-browsed
when: not cups_enabled and not is_F18 when: not cups_enabled and not is_F18
- name: Disable services for CUPS (Fedora 18, for XO laptops) - name: Disable & Stop 'cups' systemd service (Fedora 18, for XO laptops)
systemd: systemd:
name: cups name: cups
state: stopped
enabled: no enabled: no
state: stopped
when: not cups_enabled and is_F18 when: not cups_enabled and is_F18
- name: Add 'cups' variable values to {{ iiab_ini_file }} - name: Add 'cups' variable values to {{ iiab_ini_file }}
ini_file: ini_file:
path: "{{ iiab_ini_file }}" path: "{{ iiab_ini_file }}"
@ -75,7 +94,7 @@
value: CUPS value: CUPS
- option: description - option: description
value: '"CUPS (Common UNIX Printing System) is a modular printing system that allows a computer to act as a print server. A computer running CUPS is a host that can accept print jobs from client computers, process them, and send them to the appropriate printer."' value: '"CUPS (Common UNIX Printing System) is a modular printing system that allows a computer to act as a print server. A computer running CUPS is a host that can accept print jobs from client computers, process them, and send them to the appropriate printer."'
- option: installed - option: install
value: "{{ cups_install }}" value: "{{ cups_install }}"
- option: cups_enabled - option: enabled
value: "{{ cups_enabled }}" value: "{{ cups_enabled }}"

View file

@ -48,9 +48,9 @@
copy: copy:
src: "/opt/{{ elgg_xx }}/vendor/elgg/elgg/install/config/htaccess.dist" src: "/opt/{{ elgg_xx }}/vendor/elgg/elgg/install/config/htaccess.dist"
dest: "/opt/{{ elgg_xx }}/.htaccess" dest: "/opt/{{ elgg_xx }}/.htaccess"
mode: 0644
owner: "{{ apache_user }}" owner: "{{ apache_user }}"
group: "{{ apache_user }}" group: "{{ apache_user }}"
mode: '0644'
#regexp='^#RewriteBase' #regexp='^#RewriteBase'
- name: Change .htaccess to include RewriteBase for http://box{{ elgg_url }} # http://box/elgg - name: Change .htaccess to include RewriteBase for http://box{{ elgg_url }} # http://box/elgg
@ -63,18 +63,18 @@
- name: Set /opt/elgg/engine directory permissions to 0755 so Apache can write there - name: Set /opt/elgg/engine directory permissions to 0755 so Apache can write there
file: file:
state: directory
path: /opt/elgg/engine/ path: /opt/elgg/engine/
owner: "{{ apache_user }}" owner: "{{ apache_user }}"
mode: 0755 mode: '0755'
state: directory
- name: Change /opt/elgg-{{ elgg_version }} ownership to {{ apache_user }}:{{ apache_user }} (likely not nec, as unarchive & all do this above) - name: Change /opt/elgg-{{ elgg_version }} ownership to {{ apache_user }}:{{ apache_user }} (likely not nec, as unarchive & all do this above)
file: file:
state: directory # Overkill given recurse below?
path: "/opt/elgg-{{ elgg_version }}" path: "/opt/elgg-{{ elgg_version }}"
owner: "{{ apache_user }}" owner: "{{ apache_user }}"
group: "{{ apache_user }}" group: "{{ apache_user }}"
recurse: yes recurse: yes
state: directory
- name: Create upload directory {{ elgg_upload_path }} that Apache (and Elgg) can write to - name: Create upload directory {{ elgg_upload_path }} that Apache (and Elgg) can write to
file: file:
@ -82,10 +82,17 @@
state: directory state: directory
owner: "{{ apache_user }}" owner: "{{ apache_user }}"
- name: Install /etc/{{ apache_config_dir }}/elgg.conf from template, for http://box{{ elgg_url }} # http://box/elgg - name: Install /etc/{{ apache_conf_dir }}/elgg.conf from template, for http://box{{ elgg_url }} # http://box/elgg
template: template:
src: elgg.conf src: elgg.conf
dest: "/etc/{{ apache_config_dir }}/elgg.conf" dest: "/etc/{{ apache_conf_dir }}/elgg.conf"
# RECORD Elgg AS INSTALLED
- name: "Set 'elgg_installed: True'"
set_fact:
elgg_installed: True
- name: "Add 'elgg_installed: True' to {{ iiab_state_file }}" - name: "Add 'elgg_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:

View file

@ -4,14 +4,12 @@
systemd: systemd:
name: gitea name: gitea
state: stopped state: stopped
#tags: pre-install
ignore_errors: yes ignore_errors: yes
- name: Ensure group gitea exists - name: Ensure group gitea exists
group: group:
name: gitea name: gitea
state: present state: present
#tags: pre-install
- name: Create user gitea - name: Create user gitea
user: user:
@ -19,7 +17,6 @@
comment: Gitea daemon account comment: Gitea daemon account
groups: gitea groups: gitea
home: "{{ gitea_home }}" home: "{{ gitea_home }}"
#tags: pre-install
- name: Create Gitea directory structure - name: Create Gitea directory structure
file: file:
@ -28,7 +25,6 @@
owner: gitea owner: gitea
group: gitea group: gitea
with_items: "{{ gitea_subdirectories }}" with_items: "{{ gitea_subdirectories }}"
#tags: pre-install
- name: Make directories data, indexers, and log writable - name: Make directories data, indexers, and log writable
file: file:
@ -38,7 +34,6 @@
- data - data
- indexers - indexers
- log - log
#tags: pre-install
# Download, verify, and link Gitea binary # Download, verify, and link Gitea binary
@ -59,24 +54,21 @@
get_url: get_url:
url: "{{ gitea_integrity_url }}" url: "{{ gitea_integrity_url }}"
dest: "{{ gitea_checksum_path }}" dest: "{{ gitea_checksum_path }}"
#tags: never, verify
when: internet_available | bool when: internet_available | bool
- name: Verify Gitea binary with GPG signature - name: Verify Gitea binary with GPG signature
shell: | shell: |
gpg --keyserver pgp.mit.edu --recv {{ gitea_gpg_key }} gpg --keyserver pgp.mit.edu --recv {{ gitea_gpg_key }}
gpg --verify {{ gitea_checksum_path }} {{ gitea_install_path }} gpg --verify {{ gitea_checksum_path }} {{ gitea_install_path }}
#tags: never, verify
ignore_errors: yes ignore_errors: yes
- name: Link Gitea - name: Symlink {{ gitea_link_path }} -> {{ gitea_install_path }}
file: file:
src: "{{ gitea_install_path }}" src: "{{ gitea_install_path }}"
dest: "{{ gitea_link_path }}" path: "{{ gitea_link_path }}"
owner: gitea owner: gitea
group: gitea group: gitea
state: link state: link
#tags: install
# Configure Gitea # Configure Gitea
@ -87,12 +79,11 @@
- name: Create Gitea config directory - name: Create Gitea config directory
file: file:
path: /etc/gitea
state: directory state: directory
path: /etc/gitea
owner: root owner: root
group: gitea group: gitea
mode: '0770' mode: '0770'
#tags: config
- name: Create app.ini - name: Create app.ini
template: template:
@ -110,7 +101,14 @@
dest: "{{ item.dest }}" dest: "{{ item.dest }}"
with_items: with_items:
- { src: 'gitea.service.j2', dest: '/etc/systemd/system/gitea.service' } - { src: 'gitea.service.j2', dest: '/etc/systemd/system/gitea.service' }
- { src: 'gitea.conf.j2', dest: "/etc/{{ apache_config_dir }}/gitea.conf" } - { src: 'gitea.conf.j2', dest: "/etc/{{ apache_conf_dir }}/gitea.conf" }
# RECORD Gitea AS INSTALLED
- name: "Set 'gitea_installed: True'"
set_fact:
gitea_installed: True
- name: "Add 'gitea_installed: True' to {{ iiab_state_file }}" - name: "Add 'gitea_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:

View file

@ -6,14 +6,14 @@
mode: 0755 mode: 0755
state: directory state: directory
- name: Install /etc/{{ apache_config_dir }}/iiab-homepage.conf from template, for http://box redirect to http://box/home/ - name: Install /etc/{{ apache_conf_dir }}/iiab-homepage.conf from template, for http://box redirect to http://box/home/
template: template:
src: iiab-homepage.conf src: iiab-homepage.conf
dest: "/etc/{{ apache_config_dir }}/iiab-homepage.conf" dest: "/etc/{{ apache_conf_dir }}/iiab-homepage.conf"
- name: Symlink /etc/apache2/sites-enabled/iiab-homepage.conf to /etc/{{ apache_config_dir }}/iiab-homepage.conf (debuntu) - name: Symlink /etc/apache2/sites-enabled/iiab-homepage.conf to /etc/{{ apache_conf_dir }}/iiab-homepage.conf (debuntu)
file: file:
src: "/etc/{{ apache_config_dir }}/iiab-homepage.conf" src: "/etc/{{ apache_conf_dir }}/iiab-homepage.conf"
path: /etc/apache2/sites-enabled/iiab-homepage.conf path: /etc/apache2/sites-enabled/iiab-homepage.conf
state: link state: link
when: is_debuntu | bool when: is_debuntu | bool

View file

@ -21,29 +21,29 @@
# group: root # group: root
# mode: 0644 # mode: 0644
with_items: with_items:
- { src: 'roles/httpd/templates/010-iiab.conf.j2', dest: '/etc/{{ apache_config_dir }}/010-iiab.conf' } - { src: 'roles/httpd/templates/010-iiab.conf.j2', dest: '/etc/{{ apache_conf_dir }}/010-iiab.conf' }
- { src: 'roles/httpd/templates/proxy_ajp.conf.j2', dest: '/etc/{{ apache_config_dir }}/proxy_ajp.conf' } - { src: 'roles/httpd/templates/proxy_ajp.conf.j2', dest: '/etc/{{ apache_conf_dir }}/proxy_ajp.conf' }
- name: Enable our site, creating 010-iiab.conf symlink from sites-enabled to sites-available (debuntu) - name: Enable our site, creating 010-iiab.conf symlink from sites-enabled to sites-available (debuntu)
file: file:
src: "/etc/{{ apache_config_dir }}/010-iiab.conf" src: "/etc/{{ apache_conf_dir }}/010-iiab.conf"
path: /etc/apache2/sites-enabled/010-iiab.conf path: /etc/apache2/sites-enabled/010-iiab.conf
state: link state: link
when: is_debuntu | bool when: is_debuntu | bool
# SEE https://github.com/iiab/iiab/issues/1143 as the old roles/osm playbook is rarely used as of late 2018 (if anybody still uses roles/osm, they can overwrite osm.conf using the original osm playbook, or in other ways) # SEE https://github.com/iiab/iiab/issues/1143 as the old roles/osm playbook is rarely used as of late 2018 (if anybody still uses roles/osm, they can overwrite osm.conf using the original osm playbook, or in other ways)
- name: Install /etc/{{ apache_config_dir }}/osm.conf for http://box/maps (all OS's) - name: Install /etc/{{ apache_conf_dir }}/osm.conf for http://box/maps (all OS's)
copy: copy:
src: roles/httpd/files/osm.conf src: roles/httpd/files/osm.conf
dest: "/etc/{{ apache_config_dir }}" dest: "/etc/{{ apache_conf_dir }}"
# owner: root # owner: root
# group: root # group: root
# mode: 0644 # mode: 0644
when: osm_vector_maps_install | bool when: osm_vector_maps_install | bool
- name: Symlink /etc/apache2/sites-enabled/osm.conf -> /etc/{{ apache_config_dir }}/osm.conf (debuntu) - name: Symlink /etc/apache2/sites-enabled/osm.conf -> /etc/{{ apache_conf_dir }}/osm.conf (debuntu)
file: file:
src: "/etc/{{ apache_config_dir }}/osm.conf" src: "/etc/{{ apache_conf_dir }}/osm.conf"
path: /etc/apache2/sites-enabled/osm.conf path: /etc/apache2/sites-enabled/osm.conf
state: link state: link
when: is_debuntu and osm_vector_maps_enabled when: is_debuntu and osm_vector_maps_enabled

View file

@ -143,6 +143,13 @@
mode: '0755' mode: '0755'
state: directory state: directory
# RECORD Apache AS INSTALLED
- name: "Set 'apache_installed: True'"
set_fact:
apache_installed: True
- name: "Add 'apache_installed: True' to {{ iiab_state_file }}" - name: "Add 'apache_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -40,7 +40,7 @@
value: "{{ item.value | string }}" value: "{{ item.value | string }}"
with_items: with_items:
- option: name - option: name
value: Internet Archive Offline value: Internet Archive
- option: description - option: description
value: '"Dweb-mirror is intended to make the Internet Archive experience and UI available offline."' value: '"Dweb-mirror is intended to make the Internet Archive experience and UI available offline."'
- option: internetarchive_enabled - option: internetarchive_enabled

View file

@ -1,20 +1,33 @@
- name: Install NodeJS # INSTALL 3 PREREQS
- name: "Set 'nodejs_install: True' and 'nodejs_enabled: True'"
set_fact:
nodejs_install: True
nodejs_enabled: True
- name: Install Node.JS
include_role: include_role:
name: nodejs name: nodejs
- name: "Set 'yarn_install: True' and 'yarn_enabled: True'"
set_fact:
yarn_install: True
yarn_enabled: True
- name: Install Yarn - name: Install Yarn
include_role: include_role:
name: yarn name: yarn
- name: Install packages needed by Internet Archive Offline - name: Install package 'libsecret-1-dev'
package: package:
name: name: libsecret-1-dev
- libsecret-1-dev
state: present state: present
- name: Create directory {{ internetarchive_dir }} # CREATE 2 DIRS & RUN YARN
- name: mkdir {{ internetarchive_dir }}
file: file:
path: "{{ internetarchive_dir }}" path: "{{ internetarchive_dir }}" # /opt/iiab/internetarchive
state: directory state: directory
owner: "root" owner: "root"
@ -26,7 +39,7 @@
when: internet_available | bool when: internet_available | bool
register: internetarchive_installing register: internetarchive_installing
- name: Create directory /library/archiveorg - name: mkdir /library/archiveorg
file: file:
path: "/library/archiveorg" path: "/library/archiveorg"
state: directory state: directory
@ -38,13 +51,20 @@
template: template:
src: "{{ item.src }}" src: "{{ item.src }}"
dest: "{{ item.dest }}" dest: "{{ item.dest }}"
mode: 0644 mode: '0644'
owner: root owner: root
group: root group: root
with_items: with_items:
- { src: 'internetarchive.service.j2', dest: '/etc/systemd/system/internetarchive.service' } - { src: 'internetarchive.service.j2', dest: '/etc/systemd/system/internetarchive.service' }
- { src: 'internetarchive.conf', dest: '/etc/apache2/sites-available/internetarchive.conf' } - { src: 'internetarchive.conf', dest: '/etc/apache2/sites-available/internetarchive.conf' }
# RECORD Internet Archive AS INSTALLED
- name: "Set 'internetarchive_installed: True'"
set_fact:
internetarchive_installed: True
- name: "Add 'internetarchive_installed: True' to {{ iiab_state_file }}" - name: "Add 'internetarchive_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -80,7 +80,7 @@
with_items: with_items:
- { src: 'kalite.sh.j2', dest: '/usr/bin/kalite', mode: '0755'} - { src: 'kalite.sh.j2', dest: '/usr/bin/kalite', mode: '0755'}
- { src: 'kalite-serve.service.j2', dest: '/etc/systemd/system/kalite-serve.service', mode: '0644'} - { src: 'kalite-serve.service.j2', dest: '/etc/systemd/system/kalite-serve.service', mode: '0644'}
- { src: 'kalite.conf', dest: '/etc/{{ apache_config_dir }}', mode: '0644'} - { src: 'kalite.conf', dest: '/etc/{{ apache_conf_dir }}', mode: '0644'}
- name: Fix KA Lite bug in regex parsing ifconfig output, for @m-anish's network names that contain dashes - name: Fix KA Lite bug in regex parsing ifconfig output, for @m-anish's network names that contain dashes
replace: replace:
@ -88,9 +88,8 @@
regexp: 'a-zA-Z0-9' regexp: 'a-zA-Z0-9'
replace: 'a-zA-Z0-9\-' replace: 'a-zA-Z0-9\-'
# SHOULD REALLY BE HERE...but for now this runs in kalite/tasks/setup.yml
# - name: "Add 'kalite_installed: True' to {{ iiab_state_file }}" # RECORD KA Lite AS INSTALLED
# lineinfile:
# dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml # TO DO: move the last 2 stanzas from setup.yml so they live right here,
# regexp: '^kalite_installed' # as any action named "install.yml" should do exactly what it says (install!)
# line: 'kalite_installed: True'

View file

@ -15,7 +15,16 @@
async: 1800 async: 1800
poll: 10 poll: 10
# CAN WE MOVE THIS TO THE END OF kalite/tasks/install.yml (HENCE ITS FILENAME!)
# RECORD KA Lite AS INSTALLED
# TO DO: move these last 2 stanzas to install.yml,
# as any action named "install.yml" should do exactly what it says (install!)
- name: "Set 'kalite_installed: True'"
set_fact:
kalite_installed: True
- name: "Add 'kalite_installed: True' to {{ iiab_state_file }}" - name: "Add 'kalite_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -44,6 +44,7 @@
path: "{{ kiwix_path }}/bin" path: "{{ kiwix_path }}/bin"
state: directory state: directory
# 2. INSTALL KIWIX-TOOLS EXECUTABLES # 2. INSTALL KIWIX-TOOLS EXECUTABLES
- name: Unarchive {{ kiwix_src_file }} to /tmp # e.g. kiwix-tools_linux-armhf-0.6.1-1.tar.gz - name: Unarchive {{ kiwix_src_file }} to /tmp # e.g. kiwix-tools_linux-armhf-0.6.1-1.tar.gz
@ -54,6 +55,7 @@
- name: Move /tmp/{{ kiwix_src_dir }}/* to permanent location /opt/iiab/kiwix/bin (armhf & linux64 & i686) - name: Move /tmp/{{ kiwix_src_dir }}/* to permanent location /opt/iiab/kiwix/bin (armhf & linux64 & i686)
shell: "mv /tmp/{{ kiwix_src_dir }}/* {{ kiwix_path }}/bin/" shell: "mv /tmp/{{ kiwix_src_dir }}/* {{ kiwix_path }}/bin/"
# 3. ENABLE MODS FOR APACHE PROXY IF DEBUNTU # 3. ENABLE MODS FOR APACHE PROXY IF DEBUNTU
# 2019-10-07: Moved to roles/httpd/tasks/main.yml # 2019-10-07: Moved to roles/httpd/tasks/main.yml
@ -68,6 +70,7 @@
# - rewrite # - rewrite
# when: is_debuntu | bool # when: is_debuntu | bool
# 4. INSTALL iiab-make-kiwix-lib*, kiwix-serve.service, kiwix.conf for Apache # 4. INSTALL iiab-make-kiwix-lib*, kiwix-serve.service, kiwix.conf for Apache
- name: 'Install from templates: kiwix-serve.service, iiab-make-kiwix-lib, iiab-make-kiwix-lib.py, kiwix.conf' - name: 'Install from templates: kiwix-serve.service, iiab-make-kiwix-lib, iiab-make-kiwix-lib.py, kiwix.conf'
@ -79,9 +82,14 @@
- { src: 'kiwix-serve.service.j2', dest: '/etc/systemd/system/kiwix-serve.service', mode: '0644' } - { src: 'kiwix-serve.service.j2', dest: '/etc/systemd/system/kiwix-serve.service', mode: '0644' }
- { src: 'iiab-make-kiwix-lib', dest: '/usr/bin/iiab-make-kiwix-lib', mode: '0755' } - { src: 'iiab-make-kiwix-lib', dest: '/usr/bin/iiab-make-kiwix-lib', mode: '0755' }
- { src: 'iiab-make-kiwix-lib3.py', dest: '/usr/bin/iiab-make-kiwix-lib.py', mode: '0755' } - { src: 'iiab-make-kiwix-lib3.py', dest: '/usr/bin/iiab-make-kiwix-lib.py', mode: '0755' }
- { src: 'kiwix.conf.j2', dest: '/etc/{{ apache_config_dir }}/kiwix.conf', mode: '0644' } - { src: 'kiwix.conf.j2', dest: '/etc/{{ apache_conf_dir }}/kiwix.conf', mode: '0644' }
# 5. RECORD KIWIX AS INSTALLED IN /etc/iiab/iiab_state.yml
# 5. RECORD Kiwix AS INSTALLED
- name: "Set 'kiwix_installed: True'"
set_fact:
kiwix_installed: True
- name: "Add 'kiwix_installed: True' to {{ iiab_state_file }}" - name: "Add 'kiwix_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:

View file

@ -113,6 +113,13 @@
# apache2_module: # apache2_module:
# name: proxy_http # name: proxy_http
# RECORD Kolibri AS INSTALLED
- name: "Set 'kolibri_installed: True'"
set_fact:
kolibri_installed: True
- name: "Add 'kolibri_installed: True' to {{ iiab_state_file }}" - name: "Add 'kolibri_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -67,10 +67,10 @@
. {{ lokole_run_directory }}/webapp_secrets.sh . {{ lokole_run_directory }}/webapp_secrets.sh
{{ lokole_venv }}/bin/manage.py createadmin --name='{{ lokole_admin_user }}' --password='{{ lokole_admin_password }}' {{ lokole_venv }}/bin/manage.py createadmin --name='{{ lokole_admin_user }}' --password='{{ lokole_admin_password }}'
- name: Install /etc/{{ apache_config_dir }}/lokole.conf from template, for http://box{{ lokole_url }} via Apache # http://box/lokole - name: Install /etc/{{ apache_conf_dir }}/lokole.conf from template, for http://box{{ lokole_url }} via Apache # http://box/lokole
template: template:
src: lokole.conf.j2 src: lokole.conf.j2
dest: "/etc/{{ apache_config_dir }}/lokole.conf" dest: "/etc/{{ apache_conf_dir }}/lokole.conf"
when: apache_install | bool when: apache_install | bool
- name: Install /etc/systemd/system/lokole.service unit file from template - name: Install /etc/systemd/system/lokole.service unit file from template
@ -86,6 +86,13 @@
# state: restarted # state: restarted
# when: lokole_enabled | bool # when: lokole_enabled | bool
# RECORD Lokole AS INSTALLED
- name: "Set 'lokole_installed: True'"
set_fact:
lokole_installed: True
- name: "Add 'lokole_installed: True' to {{ iiab_state_file }}" - name: "Add 'lokole_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -80,10 +80,17 @@
regexp: '^\$wgServer =' regexp: '^\$wgServer ='
line: '$wgServer = "//" . $_SERVER["HTTP_HOST"];' line: '$wgServer = "//" . $_SERVER["HTTP_HOST"];'
- name: Install /etc/{{ apache_config_dir }}/mediawiki.conf from template, for http://box{{ mediawiki_url }} via Apache - name: Install /etc/{{ apache_conf_dir }}/mediawiki.conf from template, for http://box{{ mediawiki_url }} via Apache
template: template:
src: mediawiki.conf.j2 src: mediawiki.conf.j2
dest: "/etc/{{ apache_config_dir }}/mediawiki.conf" dest: "/etc/{{ apache_conf_dir }}/mediawiki.conf"
# RECORD MediaWiki AS INSTALLED
- name: "Set 'mediawiki_installed: True'"
set_fact:
mediawiki_installed: True
- name: "Add 'mediawiki_installed: True' to {{ iiab_state_file }}" - name: "Add 'mediawiki_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:

View file

@ -1,18 +1,18 @@
# Calculate local variables # Calculate local variables
- include_tasks: calc_vars.yml - include_tasks: calc_vars.yml
- name: Check for minetest world file ({{ minetest_world_dir }}/world.mt) - name: Check for Minetest world file ({{ minetest_world_dir }}/world.mt)
stat: stat:
path: "{{ minetest_world_dir }}/world.mt" path: "{{ minetest_world_dir }}/world.mt"
register: minetest_world register: minetest_world
- name: Create /library/games - name: mkdir /library/games
file: file:
state: directory state: directory
path: /library/games path: /library/games
# owner: root # owner: root
# group: root # group: root
# mode: 0755 # mode: '0755'
# rpi only # rpi only
- include_tasks: rpi_minetest_install.yml - include_tasks: rpi_minetest_install.yml
@ -28,7 +28,7 @@
depth: 1 depth: 1
when: not minetest_world.stat.exists and minetest_default_game == "carbone-ng" when: not minetest_world.stat.exists and minetest_default_game == "carbone-ng"
- name: Give minetest user ownership of carbone-ng - name: Give Minetest user ownership of carbone-ng
file: file:
state: directory state: directory
path: "{{ minetest_game_dir }}" path: "{{ minetest_game_dir }}"
@ -69,6 +69,13 @@
path: "{{ minetest_game_dir }}/mods/name_restrictions" path: "{{ minetest_game_dir }}/mods/name_restrictions"
when: minetest_default_game == "carbone-ng" when: minetest_default_game == "carbone-ng"
# RECORD Minetest AS INSTALLED
- name: "Set 'minetest_installed: True'"
set_fact:
minetest_installed: True
- name: "Add 'minetest_installed: True' to {{ iiab_state_file }}" - name: "Add 'minetest_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -128,9 +128,10 @@
- { src: 'iiab-mongodb-repair-if-no-lock.j2', dest: '/usr/bin/iiab-mongodb-repair-if-no-lock', mode: '0755' } - { src: 'iiab-mongodb-repair-if-no-lock.j2', dest: '/usr/bin/iiab-mongodb-repair-if-no-lock', mode: '0755' }
3. RECORD MongoDB AS INSTALLED # 3. RECORD MongoDB AS INSTALLED
- set_fact: - name: "Set 'mongodb_installed: True'"
set_fact:
mongodb_installed: True mongodb_installed: True
- name: "Add 'mongodb_installed: True' to {{ iiab_state_file }}" - name: "Add 'mongodb_installed: True' to {{ iiab_state_file }}"

View file

@ -23,10 +23,7 @@
when: (is_debian and not is_raspbian) and (not is_debian_8) and (not is_debian_9) when: (is_debian and not is_raspbian) and (not is_debian_8) and (not is_debian_9)
# 2019-07-08: mongodb_install is completely ignored. FYI mongodb_enabled: False - name: Install MongoDB if 'mongodb_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
# works but is ineffective, as Sugarizer starts mongodb's systemd svc on its own
- name: Install 'mongodb' if not Debian 10+
include_tasks: install.yml include_tasks: install.yml
when: mongodb_installed is undefined when: mongodb_installed is undefined

View file

@ -56,6 +56,13 @@
- option: enabled - option: enabled
value: "{{ monit_enabled }}" value: "{{ monit_enabled }}"
# RECORD Monit AS INSTALLED
- name: "Set 'monit_installed: True'"
set_fact:
monit_installed: True
- name: "Add 'monit_installed: True' to {{ iiab_state_file }}" - name: "Add 'monit_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -78,13 +78,13 @@
- name: Remove Apache's stock moodle.conf - name: Remove Apache's stock moodle.conf
file: file:
path: "/etc/{{ apache_config_dir }}/moodle.conf" path: "/etc/{{ apache_conf_dir }}/moodle.conf"
state: absent state: absent
- name: Install Apache's 022-moodle.conf from template, if moodle_enabled - name: Install Apache's 022-moodle.conf from template, if moodle_enabled
template: template:
src: 022-moodle.j2 src: 022-moodle.j2
dest: "/etc/{{ apache_config_dir }}/022-moodle.conf" dest: "/etc/{{ apache_conf_dir }}/022-moodle.conf"
# owner: root # owner: root
# group: root # group: root
# mode: '0644' # mode: '0644'
@ -147,6 +147,13 @@
path: "{{ moodle_base }}/config.php" path: "{{ moodle_base }}/config.php"
mode: '0644' mode: '0644'
# RECORD Moodle AS INSTALLED
- name: "Set 'moodle_installed: True'"
set_fact:
moodle_installed: True
- name: "Add 'moodle_installed: True' to {{ iiab_state_file }}" - name: "Add 'moodle_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -30,6 +30,13 @@
group: root group: root
mode: '0755' mode: '0755'
# RECORD Mosquitto AS INSTALLED
- name: "Set 'mosquitto_installed: True'"
set_fact:
mosquitto_installed: True
- name: "Add 'mosquitto_installed: True' to {{ iiab_state_file }}" - name: "Add 'mosquitto_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -26,7 +26,7 @@
# mode: 0644 # mode: 0644
with_items: with_items:
- { src: 'munin.conf.j2', dest: '/etc/munin/munin.conf' } - { src: 'munin.conf.j2', dest: '/etc/munin/munin.conf' }
- { src: 'munin24.conf.j2', dest: '/etc/{{ apache_config_dir }}/munin24.conf' } - { src: 'munin24.conf.j2', dest: '/etc/{{ apache_conf_dir }}/munin24.conf' }
- name: Establish username/password Admin/changeme in /etc/munin/munin-htpasswd - name: Establish username/password Admin/changeme in /etc/munin/munin-htpasswd
htpasswd: htpasswd:
@ -48,6 +48,13 @@
- /usr/share/munin/plugins/mysql_threads - /usr/share/munin/plugins/mysql_threads
when: mysql_enabled | bool when: mysql_enabled | bool
# RECORD Munin AS INSTALLED
- name: "Set 'munin_installed: True'"
set_fact:
munin_installed: True
- name: "Add 'munin_installed: True' to {{ iiab_state_file }}" - name: "Add 'munin_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -19,7 +19,7 @@
quiet: yes quiet: yes
- name: Install Munin if 'munin_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml - name: Install Munin if 'munin_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml include_tasks: install.yml
when: munin_installed is undefined when: munin_installed is undefined

View file

@ -1,9 +1,9 @@
# TO DO: # TO DO:
# - Validate input vars mysql_install & mysql_enabled # - Validate input vars mysql_install & mysql_enabled
# - Put ~12 stanzas just below into install.yml # - Put ~13 stanzas just below into install.yml
# - Triggered by... 'when: mysql_installed is undefined' # - Triggered by... 'when: mysql_installed is undefined'
# - Eliminate stale Fedora/CentOS code & gratuitous when: is_debuntu clauses? # - Eliminate stale Fedora/CentOS code & gratuitous when: is_debuntu clauses?
# - Consider putting ~8 stanzas below that into enable.yml or similar? # - Put ~8 stanzas below that into enable-or-disable.yml
- name: 'Install MySQL packages: mariadb-server, mariadb-client, and 8 php packages (debuntu)' - name: 'Install MySQL packages: mariadb-server, mariadb-client, and 8 php packages (debuntu)'
package: package:
@ -114,9 +114,11 @@
# line: "TimeoutStartSec=180" # line: "TimeoutStartSec=180"
when: mariadb_unit_file.stat.exists when: mariadb_unit_file.stat.exists
# RECORD MySQL AS INSTALLED # RECORD MySQL AS INSTALLED
- set_fact: - name: "Set 'mysql_installed: True'"
set_fact:
mysql_installed: True mysql_installed: True
- name: "Add 'mysql_installed: True' to {{ iiab_state_file }}" - name: "Add 'mysql_installed: True' to {{ iiab_state_file }}"

View file

@ -70,11 +70,11 @@
dest: "/etc/systemd/system/{{ dns_service }}.service" dest: "/etc/systemd/system/{{ dns_service }}.service"
mode: '0644' mode: '0644'
- name: "Install /etc/{{ apache_config_dir }}/dns-jail.conf from template: dns-jail redirect requires the named.blackhole, disabling recursion (if dns_jail_enabled)" - name: "Install /etc/{{ apache_conf_dir }}/dns-jail.conf from template: dns-jail redirect requires the named.blackhole, disabling recursion (if dns_jail_enabled)"
# in named-iiab.conf, and the redirection of 404 error documents to / # in named-iiab.conf, and the redirection of 404 error documents to /
template: template:
src: roles/network/templates/named/dns-jail.conf src: roles/network/templates/named/dns-jail.conf
dest: "/etc/{{ apache_config_dir }}/" dest: "/etc/{{ apache_conf_dir }}/"
when: dns_jail_enabled | bool when: dns_jail_enabled | bool
- name: "Add 'named_installed: True' to {{ iiab_state_file }}" - name: "Add 'named_installed: True' to {{ iiab_state_file }}"

View file

@ -173,13 +173,19 @@
- name: Install Apache's nextcloud.conf from template, for http://box/nextcloud - name: Install Apache's nextcloud.conf from template, for http://box/nextcloud
template: template:
src: nextcloud.conf.j2 src: nextcloud.conf.j2
dest: "/etc/{{ apache_config_dir }}/nextcloud.conf" dest: "/etc/{{ apache_conf_dir }}/nextcloud.conf"
- name: Provision Nextcloud's MySQL DB, run Nextcloud's install wizard etc - name: Provision Nextcloud's MySQL DB, run Nextcloud's install wizard etc
include_tasks: setup.yml include_tasks: setup.yml
# RECORD Nextcloud AS INSTALLED
- name: "Set 'nextcloud_installed: True'"
set_fact:
nextcloud_installed: True
- name: "Add 'nextcloud_installed: True' to {{ iiab_state_file }}" - name: "Add 'nextcloud_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -19,19 +19,17 @@
quiet: yes quiet: yes
#- name: Does {{ nextcloud_prefix }}//nextcloud/version.php exist? # /opt - name: Install Nextcloud if 'nextcloud_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
# stat:
# path: "{{ nextcloud_prefix }}/nextcloud/version.php"
# register: nextcloud_page
- name: Install Nextcloud if 'nextcloud_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml include_tasks: install.yml
when: nextcloud_installed is undefined # or not nextcloud_page.stat.exists when: nextcloud_installed is undefined
#
# ABOVE install.yml RUNS setup.yml
- name: Enable/Disable/Restart Apache if primary #- name: Enable/Disable/Restart Apache if primary
- name: SHIM FOR NOW SO ALWAYS DO THE...Enable/Disable/Restart Apache
include_tasks: apache.yml include_tasks: apache.yml
when: not nginx_enabled #when: not nginx_enabled
- name: Enable/Disable/Restart NGINX if primary - name: Enable/Disable/Restart NGINX if primary
include_tasks: nginx.yml include_tasks: nginx.yml

View file

@ -1,10 +1,10 @@
- name: Enable http://box{{ nextcloud_url }} via NGINX, by installing {{ nginx_conf_dir }}/nextcloud-nginx.conf from template # http://box/nextcloud - name: "SHIM: Enable http://box{{ nextcloud_url }} via NGINX, by installing {{ nginx_conf_dir }}/nextcloud-nginx.conf from template" # http://box/nextcloud
template: template:
src: nextcloud-nginx.conf.j2 src: nextcloud-nginx.conf.j2
dest: "{{ nginx_conf_dir }}/nextcloud-nginx.conf" # /etc/nginx/conf.d dest: "{{ nginx_conf_dir }}/nextcloud-nginx.conf" # /etc/nginx/conf.d
when: nextcloud_enabled | bool when: nextcloud_enabled | bool
- name: Disable http://box{{ nextcloud_url }} via NGINX, by removing {{ nginx_conf_dir }}/nextcloud-nginx.conf # http://box/nextcloud - name: "SHIM: Disable http://box{{ nextcloud_url }} via NGINX, by removing {{ nginx_conf_dir }}/nextcloud-nginx.conf" # http://box/nextcloud
file: file:
path: "{{ nginx_conf_dir }}/nextcloud-nginx.conf" # /etc/nginx/conf.d path: "{{ nginx_conf_dir }}/nextcloud-nginx.conf" # /etc/nginx/conf.d
state: absent state: absent

View file

@ -43,6 +43,13 @@
state: restarted state: restarted
when: nginx_enabled when: nginx_enabled
# RECORD NGINX AS INSTALLED
- name: "Set 'nginx_installed: True'"
set_fact:
nginx_installed: True
- name: "Add 'nginx_installed: True' to {{ iiab_state_file }}" - name: "Add 'nginx_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -151,9 +151,10 @@
3. RECORD Node.js AS INSTALLED # 3. RECORD Node.js AS INSTALLED
- set_fact: - name: "Set 'nodejs_installed: True'"
set_fact:
nodejs_installed: True nodejs_installed: True
- name: "Add 'nodejs_installed: True' to {{ iiab_state_file }}" - name: "Add 'nodejs_installed: True' to {{ iiab_state_file }}"

View file

@ -85,11 +85,11 @@
dest: /etc/systemd/system/nodered.service dest: /etc/systemd/system/nodered.service
# mode: '0666' # mode: '0666'
- name: Install /etc/{{ apache_config_dir }}/nodered.conf from template - name: Install /etc/{{ apache_conf_dir }}/nodered.conf from template
template: template:
backup: yes backup: yes
src: nodered.conf.j2 src: nodered.conf.j2
dest: "/etc/{{ apache_config_dir }}/nodered.conf" dest: "/etc/{{ apache_conf_dir }}/nodered.conf"
# mode: '0666' # mode: '0666'
# SEE ALSO THE apache2_module SECTION IN roles/httpd/tasks/main.yml # SEE ALSO THE apache2_module SECTION IN roles/httpd/tasks/main.yml
@ -98,6 +98,13 @@
state: present state: present
name: proxy_wstunnel name: proxy_wstunnel
# RECORD Node-RED AS INSTALLED
- name: "Set 'nodered_installed: True'"
set_fact:
nodered_installed: True
- name: "Add 'nodered_installed: True' to {{ iiab_state_file }}" - name: "Add 'nodered_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -1,4 +1,4 @@
# TO DO: WRAP 11 OR 12 STANZAS BELOW INTO install.yml, conditioned by... # TO DO: WRAP 12 OR 13 STANZAS BELOW INTO install.yml, conditioned by...
# 'when: openvpn_installed is undefined' # 'when: openvpn_installed is undefined'
# #
# BEWARE: 4th stanza (ssh pubkey deletions) is already conditioned by... # BEWARE: 4th stanza (ssh pubkey deletions) is already conditioned by...
@ -107,6 +107,13 @@
path: /usr/bin/iiab-vpn-off path: /usr/bin/iiab-vpn-off
state: link state: link
# RECORD OpenVPN AS INSTALLED
- name: "Set 'openvpn_installed: True'"
set_fact:
openvpn_installed: True
- name: "Add 'openvpn_installed: True' to {{ iiab_state_file }}" - name: "Add 'openvpn_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
@ -114,7 +121,7 @@
line: 'openvpn_installed: True' line: 'openvpn_installed: True'
# TO DO: WRAP COMMENTS + 4 ACTIVE STANZAS BELOW INTO enable.yml... # TO DO: WRAP COMMENTS + 4 ACTIVE STANZAS BELOW INTO enable-or-disable.yml...
# FIXED SOMETIME PRIOR TO AUGUST 2018: earlier versions of Ansible had not # FIXED SOMETIME PRIOR TO AUGUST 2018: earlier versions of Ansible had not
# been working with systemd service names that contained the "@" character. # been working with systemd service names that contained the "@" character.

View file

@ -67,6 +67,12 @@
dest: "{{ vector_map_path }}/index.html" # /library/www/osm-vector-maps dest: "{{ vector_map_path }}/index.html" # /library/www/osm-vector-maps
# RECORD OSM Vector Maps AS INSTALLED
- name: "Set 'osm_vector_maps_installed: True'"
set_fact:
osm_vector_maps_installed: True
- name: "Add 'osm_vector_maps_installed: True' to {{ iiab_state_file }}" - name: "Add 'osm_vector_maps_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -19,7 +19,7 @@
quiet: yes quiet: yes
- name: Install OSM Vector Maps if 'osm_vector_maps_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml - name: Install OSM Vector Maps if 'osm_vector_maps_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml include_tasks: install.yml
when: osm_vector_maps_installed is undefined when: osm_vector_maps_installed is undefined

View file

@ -49,3 +49,16 @@
- name: Asterisk - Install chan_dongle - name: Asterisk - Install chan_dongle
include: chan_dongle.yml include: chan_dongle.yml
when: asterisk_chan_dongle | bool when: asterisk_chan_dongle | bool
# RECORD PBX AS INSTALLED
- name: "Set 'pbx_installed: True'"
set_fact:
pbx_installed: True
- name: "Add 'pbx_installed: True' to {{ iiab_state_file }}"
lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp: '^pbx_installed'
line: 'pbx_installed: True'

View file

@ -45,6 +45,19 @@
# # recurse: yes # # recurse: yes
# # state: directory # # state: directory
- name: Install /etc/{{ apache_conf_dir }}/phpmyadmin.conf from template, if phpmyadmin_enabled
template:
src: phpmyadmin.j2
dest: "/etc/{{ apache_conf_dir }}/phpmyadmin.conf"
when: apache_install | bool
# RECORD phpMyAdmin AS INSTALLED
- name: "Set 'phpmyadmin_installed: True'"
set_fact:
phpmyadmin_installed: True
- name: "Add 'phpmyadmin_installed: True' to {{ iiab_state_file }}" - name: "Add 'phpmyadmin_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
@ -52,24 +65,13 @@
line: 'phpmyadmin_installed: True' line: 'phpmyadmin_installed: True'
- name: Install /etc/{{ apache_config_dir }}/phpmyadmin.conf from template, if phpmyadmin_enabled - name: Enable phpMyAdmin via Apache, if phpmyadmin_enabled
template: command: a2ensite phpmyadmin.conf
src: phpmyadmin.j2 when: apache_install and phpmyadmin_enabled
dest: "/etc/{{ apache_config_dir }}/phpmyadmin.conf"
when: phpmyadmin_enabled | bool
- name: Create symlink phpmyadmin.conf from sites-enabled to sites-available (debuntu) - name: Disable phpMyAdmin via Apache, if not phpmyadmin_enabled
file: command: a2dissite phpmyadmin.conf
src: /etc/apache2/sites-available/phpmyadmin.conf when: apache_install and not phpmyadmin_enabled
path: /etc/apache2/sites-enabled/phpmyadmin.conf
state: link
when: phpmyadmin_enabled and is_debuntu
- name: Remove /etc/apache2/sites-enabled/phpmyadmin.conf, if not phpmyadmin_enabled (debuntu)
file:
path: /etc/apache2/sites-enabled/phpmyadmin.conf
state: absent
when: not phpmyadmin_enabled and is_debuntu
- name: Add 'phpmyadmin' variable values to {{ iiab_ini_file }} - name: Add 'phpmyadmin' variable values to {{ iiab_ini_file }}

View file

@ -1,6 +1,6 @@
# TO DO: # TO DO:
# - Validate input vars postgresql_install & postgresql_enabled # - Validate input vars postgresql_install & postgresql_enabled
# - Put ~12 stanzas just below into install.yml # - Put ~13 stanzas just below into install.yml
# - Triggered by... 'when: postgresql_installed is undefined' # - Triggered by... 'when: postgresql_installed is undefined'
- name: Install 'postgresql' package - name: Install 'postgresql' package
@ -85,9 +85,11 @@
state: stopped state: stopped
enabled: no enabled: no
# RECORD PostgreSQL AS INSTALLED # RECORD PostgreSQL AS INSTALLED
- set_fact: - name: "Set 'postgresql_installed: True'"
set_fact:
postgresql_installed: True postgresql_installed: True
- name: "Add 'postgresql_installed: True' to {{ iiab_state_file }}" - name: "Add 'postgresql_installed: True' to {{ iiab_state_file }}"

View file

@ -21,51 +21,55 @@
- samba-common - samba-common
- cifs-utils - cifs-utils
state: present state: present
#tags: samba, download
- name: Install /etc/samba/smb.conf from template - name: Install /etc/samba/smb.conf from template
template: template:
src: smb.conf.j2 src: smb.conf.j2
dest: /etc/samba/smb.conf dest: /etc/samba/smb.conf
# RECORD Samba AS INSTALLED
- name: "Set 'samba_installed: True'"
set_fact:
samba_installed: True
- name: "Add 'samba_installed: True' to {{ iiab_state_file }}" - name: "Add 'samba_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp: '^samba_installed' regexp: '^samba_installed'
line: 'samba_installed: True' line: 'samba_installed: True'
- name: Enable & Start Samba systemd service
- name: Enable & Start Samba ({{ smb_service }}) systemd service, if samba_enabled
service: service:
name: "{{ smb_service }}" name: "{{ smb_service }}"
state: started state: started
enabled: yes enabled: yes
#tags: samba
when: samba_enabled | bool when: samba_enabled | bool
- name: Enable & Start NetBIOS name server ({{ nmb_service }}) - name: Enable & Start NetBIOS name server ({{ nmb_service }}) if samba_enabled
service: service:
name: "{{ nmb_service }}" name: "{{ nmb_service }}"
state: started state: started
enabled: yes enabled: yes
#tags: samba
when: samba_enabled | bool when: samba_enabled | bool
- name: Disable Samba if not samba_enabled - name: Disable & Stop Samba ({{ smb_service }}) systemd service, if not samba_enabled
service: systemd:
name: "{{ smb_service }}" name: "{{ smb_service }}"
state: stopped state: stopped
enabled: no enabled: no
#tags: samba
when: not samba_enabled when: not samba_enabled
- name: Disable NetBIOS name server ({{ nmb_service }}) if not samba_enabled - name: Disable & Stop NetBIOS name server ({{ nmb_service }}) if not samba_enabled
service: systemd:
name: "{{ nmb_service }}" name: "{{ nmb_service }}"
state: stopped state: stopped
enabled: no enabled: no
#tags: samba
when: not samba_enabled when: not samba_enabled
- name: Add 'samba' variable values to {{ iiab_ini_file }} - name: Add 'samba' variable values to {{ iiab_ini_file }}
ini_file: ini_file:
path: "{{ iiab_ini_file }}" path: "{{ iiab_ini_file }}"

View file

@ -2,25 +2,24 @@
package: package:
name: "{{ sshd_package }}" name: "{{ sshd_package }}"
state: present state: present
when: sshd_enabled | bool
- name: Disable root login with password - name: Disable password-based logins to root
lineinfile: lineinfile:
dest: /etc/ssh/sshd_config dest: /etc/ssh/sshd_config
regexp: '^PermitRootLogin' regexp: '^PermitRootLogin'
line: 'PermitRootLogin without-password' line: 'PermitRootLogin without-password'
state: present state: present
when: sshd_enabled | bool #when: sshd_enabled | bool
#TODO: use handler to reload ssh #TODO: use handler to reload ssh
- name: Create root .ssh - name: mkdir /root/.ssh
file: file:
state: directory
path: /root/.ssh path: /root/.ssh
owner: root owner: root
group: root group: root
mode: 0700 mode: '0700'
state: directory #when: sshd_enabled | bool
when: sshd_enabled | bool
- name: Install dummy root keys as placeholder - name: Install dummy root keys as placeholder
copy: copy:
@ -28,19 +27,34 @@
dest: /root/.ssh/authorized_keys dest: /root/.ssh/authorized_keys
owner: root owner: root
group: root group: root
mode: 0600 mode: '0600'
force: no force: no
when: sshd_enabled | bool #when: sshd_enabled | bool
- name: Enable & start ssh daemon
service: # RECORD sshd AS INSTALLED
- name: "Set 'sshd_installed: True'"
set_fact:
sshd_installed: True
- name: "Add 'sshd_installed: True' to {{ iiab_state_file }}"
lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp: '^sshd_installed'
line: 'sshd_installed: True'
- name: Enable & Start ssh daemon ({{ sshd_service }}) if sshd_enabled
systemd:
name: "{{ sshd_service }}" name: "{{ sshd_service }}"
daemon_reload: yes
enabled: yes enabled: yes
state: started state: started
when: sshd_enabled | bool when: sshd_enabled | bool
- name: Disable ssh daemon - name: Disable & Stop ssh daemon ({{ sshd_service }}) if not sshd_enabled
service: systemd:
name: "{{ sshd_service }}" name: "{{ sshd_service }}"
enabled: no enabled: no
state: stopped state: stopped

View file

@ -1,6 +1,13 @@
0. ATTEMPT INSTALL-THEN-ASSERT OF (1) HARD PREREQ Node.js (2) SOFT PREREQ MongoDB # 0. ATTEMPT INSTALL-THEN-ASSERT OF (1) HARD PREREQ Node.js (2) SOFT PREREQ MongoDB
- set_fact: - debug:
var: nodejs_install
- debug:
var: nodejs_enabled
- name: "Set 'nodejs_install: True' and 'nodejs_enabled: True'"
set_fact:
nodejs_install: True nodejs_install: True
nodejs_enabled: True nodejs_enabled: True
@ -18,7 +25,14 @@
msg: "Sugarizer install cannot proceed, as it currently requires Node.js 12.x, and your nodejs_version appears to be {{ nodejs_version }}. Please check the value of nodejs_version in /opt/iiab/iiab/vars/default_vars.yml, /etc/iiab/local_vars.yml, /opt/iiab/iiab/roles/nodejs, etc!" msg: "Sugarizer install cannot proceed, as it currently requires Node.js 12.x, and your nodejs_version appears to be {{ nodejs_version }}. Please check the value of nodejs_version in /opt/iiab/iiab/vars/default_vars.yml, /etc/iiab/local_vars.yml, /opt/iiab/iiab/roles/nodejs, etc!"
when: nodejs_version != "12.x" when: nodejs_version != "12.x"
- set_fact:
- debug:
var: mongodb_install
- debug:
var: mongodb_enabled
- name: "Set 'mongodb_install: True' and 'mongodb_enabled: True'"
set_fact:
mongodb_install: True mongodb_install: True
mongodb_enabled: True mongodb_enabled: True
@ -178,7 +192,7 @@
# mode: '0644' # mode: '0644'
with_items: with_items:
- { src: 'sugarizer.service', dest: '/etc/systemd/system/sugarizer.service' } - { src: 'sugarizer.service', dest: '/etc/systemd/system/sugarizer.service' }
- { src: 'sugarizer.conf.j2', dest: "/etc/{{ apache_config_dir }}/sugarizer.conf" } - { src: 'sugarizer.conf.j2', dest: "/etc/{{ apache_conf_dir }}/sugarizer.conf" }
#- { src: 'sugarizer.ini.j2', dest: '{{ iiab_base }}/sugarizer-server/env/sugarizer.ini' } #- { src: 'sugarizer.ini.j2', dest: '{{ iiab_base }}/sugarizer-server/env/sugarizer.ini' }
#- { src: 'sugarizer.js', dest: '{{ iiab_base }}/sugarizer-server' } #- { src: 'sugarizer.js', dest: '{{ iiab_base }}/sugarizer-server' }
@ -253,9 +267,10 @@
# # block: "\tvar pathPrefix = '/sugarizer';\n\tapp.use(pathPrefix, require('path-prefix-proxy')(pathPrefix));" # # block: "\tvar pathPrefix = '/sugarizer';\n\tapp.use(pathPrefix, require('path-prefix-proxy')(pathPrefix));"
6. RECORD Sugarizer AS INSTALLED # 6. RECORD Sugarizer AS INSTALLED
- set_fact: - name: "Set 'sugarizer_installed: True'"
set_fact:
sugarizer_installed: True sugarizer_installed: True
- name: "Add 'sugarizer_installed: True' to {{ iiab_state_file }}" - name: "Add 'sugarizer_installed: True' to {{ iiab_state_file }}"

View file

@ -19,7 +19,7 @@
quiet: yes quiet: yes
- name: Install Sugarizer if 'sugarizer_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml - name: Install Sugarizer if 'sugarizer_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml include_tasks: install.yml
when: sugarizer_installed is undefined when: sugarizer_installed is undefined

View file

@ -7,11 +7,11 @@
- name: Create download dir {{ transmission_download_dir }}, owned by {{ transmission_user }}:{{ transmission_group }} - name: Create download dir {{ transmission_download_dir }}, owned by {{ transmission_user }}:{{ transmission_group }}
file: file:
state: directory
path: "{{ transmission_download_dir }}" # /library/transmission path: "{{ transmission_download_dir }}" # /library/transmission
owner: "{{ transmission_user }}" # debian-transmission owner: "{{ transmission_user }}" # debian-transmission
group: "{{ transmission_group }}" # root group: "{{ transmission_group }}" # root
# mode: '0755' # mode: '0755'
state: directory
- name: Stop 'transmission-daemon' systemd service, before modifying its settings - name: Stop 'transmission-daemon' systemd service, before modifying its settings
systemd: systemd:
@ -23,9 +23,16 @@
template: template:
src: settings.json.j2 src: settings.json.j2
dest: /etc/transmission-daemon/settings.json dest: /etc/transmission-daemon/settings.json
# mode: '0644'
owner: "{{ transmission_user }}" # debian-transmission owner: "{{ transmission_user }}" # debian-transmission
group: "{{ transmission_group }}" # root group: "{{ transmission_group }}" # root
# mode: '0644'
# RECORD Transmission AS INSTALLED
- name: "Set 'transmission_installed: True'"
set_fact:
transmission_installed: True
- name: "Add 'transmission_installed: True' to {{ iiab_state_file }}" - name: "Add 'transmission_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:

View file

@ -0,0 +1,109 @@
# TO DO:
# - validate input vars + prereqs
# - move 6 top stanzas into install.yml
# - move 6 mid/lower stanzas into enable-or-disable.yml
# - verify analogous NGINX logic from roles/nginx/* -- then integrate as nec?
- name: Add dir {{ doc_root }}/local_content, where USB drive links can appear
file:
state: directory
path: "{{ doc_root }}/local_content"
owner: "{{ apache_user }}"
group: "{{ iiab_admin_user }}" # ISN'T "{{ apache_user }}" MORE APPROPRIATE?
mode: '0775'
- name: 'Install from template: /etc/udev/rules.d/usbmount.rules, /etc/systemd/system/usbmount@.service, /usr/bin/iiab-usb_lib-show-all-on, /usr/bin/iiab-usb_lib-show-all-off'
template:
src: "{{ item.src }}"
dest: "{{ item.dest }}"
mode: "{{ item.mode }}"
with_items:
- { src: 'usbmount@.service.j2' , dest: '/etc/systemd/system/usbmount@.service', mode: '0644' }
- { src: 'usbmount.rules.j2' , dest: '/etc/udev/rules.d/usbmount.rules', mode: '0644' }
- { src: 'iiab-usb_lib-show-all-on' , dest: '/usr/bin/', mode: '0755' }
- { src: 'iiab-usb_lib-show-all-off' , dest: '/usr/bin/', mode: '0755' }
- name: Enable exFAT and NTFS in /etc/usbmount/usbmount.conf
lineinfile:
regexp: '^FILESYSTEMS.*'
line: 'FILESYSTEMS="vfat ext2 ext3 ext4 hfsplus exfat fuseblk ntfs"'
path: /etc/usbmount/usbmount.conf
- name: Install /etc/{{ apache_conf_dir }}/content_dir.conf from template
template:
src: content_dir.conf
dest: "/etc/{{ apache_conf_dir }}"
when: apache_install
# RECORD usb_lib AS INSTALLED
- name: "Set 'usb_lib_installed: True'"
set_fact:
usb_lib_installed: True
- name: "Add 'usb_lib_installed: True' to {{ iiab_state_file }}"
lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp: '^usb_lib_installed'
line: 'usb_lib_installed: True'
- name: Install /etc/usbmount/mount.d/70-usb-library from template, if usb_lib_enabled
template:
src: mount.d/70-usb-library
dest: /etc/usbmount/mount.d/
owner: root
group: root
mode: '0751'
when: usb_lib_enabled | bool
- name: Install /etc/usbmount/umount.d/70-usb-library from template, if usb_lib_enabled
template:
src: umount.d/70-usb-library
dest: /etc/usbmount/umount.d
owner: root
group: root
mode: '0751'
when: usb_lib_enabled | bool
- name: Remove /etc/usbmount/mount.d/70-usb-library if not usb_lib_enabled
file:
path: /etc/usbmount/mount.d/70-usb-library
state: absent
when: not usb_lib_enabled
- name: Remove /etc/usbmount/umount.d/70-usb-library if not usb_lib_enabled
file:
path: /etc/usbmount/umount.d/70-usb-library
state: absent
when: not usb_lib_enabled
- name: Enable http://box/usb via Apache, if usb_lib_enabled
command: a2ensite content_dir.conf
when: apache_install and usb_lib_enabled
- name: Disable http://box/usb via Apache, if not usb_lib_enabled
command: a2dissite content_dir.conf
when: apache_install and not usb_lib_enabled
- name: Put variable in iiab.env that enables display of content at root of USB
lineinfile:
path: "{{ iiab_env_file }}"
regexp: "^IIAB_USB_LIB_SHOW_ALL.*"
line: "IIAB_USB_LIB_SHOW_ALL={{ iiab_usb_lib_show_all }}"
- name: Add 'usb_lib' variable values to {{ iiab_ini_file }}
ini_file:
path: "{{ iiab_ini_file }}"
section: usb_lib
option: "{{ item.option }}"
value: "{{ item.value | string }}"
with_items:
- option: name
value: usb_lib
- option: description
value: '"usb_lib automounts Teacher Content on USB drives to /library/www/html/local_content, so students can browse it almost immediately at http://box/usb"'
- option: enabled
value: "{{ usb_lib_enabled }}"

View file

@ -1,21 +1,18 @@
# TO DO:
# - validate input vars + prereqs
# - move 6 top stanzas into install.yml
# - move 6 mid/lower stanzas into enable-or-disable.yml
# - verify analogous NGINX logic from roles/nginx/* -- then integrate as nec?
- name: Add dir {{ doc_root }}/local_content, where USB drive links can appear - name: Add dir {{ doc_root }}/local_content, where USB drive links can appear
file: file:
path: "{{ doc_root }}/local_content"
state: directory state: directory
path: "{{ doc_root }}/local_content"
owner: "{{ apache_user }}" owner: "{{ apache_user }}"
group: "{{ iiab_admin_user }}" # ISN'T "{{ apache_user }}" MORE APPROPRIATE? group: "{{ iiab_admin_user }}" # ISN'T "{{ apache_user }}" MORE APPROPRIATE?
mode: 0775 mode: '0775'
- name: Install /etc/usbmount/mount.d/70-usb-library from template - name: 'Install from template: /etc/udev/rules.d/usbmount.rules, /etc/systemd/system/usbmount@.service, /usr/bin/iiab-usb_lib-show-all-on, /usr/bin/iiab-usb_lib-show-all-off'
template:
src: mount.d/70-usb-library
dest: /etc/usbmount/mount.d/
owner: root
group: root
mode: 0751
when: usb_lib_enabled | bool
- name: 'Install from template: /etc/udev/rules.d/usbmount.rules, /etc/systemd/system/usbmount@.service, /usr/bin/iiab-usb-lib-show-all-on, /usr/bin/iiab-usb-lib-show-all-off'
template: template:
src: "{{ item.src }}" src: "{{ item.src }}"
dest: "{{ item.dest }}" dest: "{{ item.dest }}"
@ -23,22 +20,51 @@
with_items: with_items:
- { src: 'usbmount@.service.j2' , dest: '/etc/systemd/system/usbmount@.service', mode: '0644' } - { src: 'usbmount@.service.j2' , dest: '/etc/systemd/system/usbmount@.service', mode: '0644' }
- { src: 'usbmount.rules.j2' , dest: '/etc/udev/rules.d/usbmount.rules', mode: '0644' } - { src: 'usbmount.rules.j2' , dest: '/etc/udev/rules.d/usbmount.rules', mode: '0644' }
- { src: 'iiab-usb-lib-show-all-on' , dest: '/usr/bin/', mode: '0755' } - { src: 'iiab-usb_lib-show-all-on' , dest: '/usr/bin/', mode: '0755' }
- { src: 'iiab-usb-lib-show-all-off' , dest: '/usr/bin/', mode: '0755' } - { src: 'iiab-usb_lib-show-all-off' , dest: '/usr/bin/', mode: '0755' }
- name: Enable exFAT and NTFS in /etc/usbmount/usbmount.conf - name: Enable exFAT and NTFS in /etc/usbmount/usbmount.conf
lineinfile: lineinfile:
regexp: '^FILESYSTEMS.*' regexp: '^FILESYSTEMS.*'
line: 'FILESYSTEMS="vfat ext2 ext3 ext4 hfsplus exfat fuseblk ntfs"' line: 'FILESYSTEMS="vfat ext2 ext3 ext4 hfsplus exfat fuseblk ntfs"'
path: /etc/usbmount/usbmount.conf path: /etc/usbmount/usbmount.conf
- name: Install /etc/usbmount/umount.d/70-usb-library from template - name: Install /etc/{{ apache_conf_dir }}/content_dir.conf from template
template:
src: content_dir.conf
dest: "/etc/{{ apache_conf_dir }}"
when: apache_install
# RECORD usb_lib AS INSTALLED
- name: "Set 'usb_lib_installed: True'"
set_fact:
usb_lib_installed: True
- name: "Add 'usb_lib_installed: True' to {{ iiab_state_file }}"
lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp: '^usb_lib_installed'
line: 'usb_lib_installed: True'
- name: Install /etc/usbmount/mount.d/70-usb-library from template, if usb_lib_enabled
template:
src: mount.d/70-usb-library
dest: /etc/usbmount/mount.d/
owner: root
group: root
mode: '0751'
when: usb_lib_enabled | bool
- name: Install /etc/usbmount/umount.d/70-usb-library from template, if usb_lib_enabled
template: template:
src: umount.d/70-usb-library src: umount.d/70-usb-library
dest: /etc/usbmount/umount.d dest: /etc/usbmount/umount.d
owner: root owner: root
group: root group: root
mode: 0751 mode: '0751'
when: usb_lib_enabled | bool when: usb_lib_enabled | bool
- name: Remove /etc/usbmount/mount.d/70-usb-library if not usb_lib_enabled - name: Remove /etc/usbmount/mount.d/70-usb-library if not usb_lib_enabled
@ -53,47 +79,31 @@
state: absent state: absent
when: not usb_lib_enabled when: not usb_lib_enabled
- name: Enable http://box/usb via Apache, if usb_lib_enabled
shell: a2ensite content_dir.conf
when: apache_install and usb_lib_enabled
- name: Disable http://box/usb via Apache, if not usb_lib_enabled
shell: a2dissite content_dir.conf
when: apache_install and not usb_lib_enabled
- name: Put variable in iiab.env that enables display of content at root of USB - name: Put variable in iiab.env that enables display of content at root of USB
lineinfile: lineinfile:
path: "{{ iiab_env_file }}" path: "{{ iiab_env_file }}"
regexp: "^IIAB_USB_LIB_SHOW_ALL.*" regexp: "^IIAB_USB_LIB_SHOW_ALL.*"
line: "IIAB_USB_LIB_SHOW_ALL={{ iiab_usb_lib_show_all }}" line: "IIAB_USB_LIB_SHOW_ALL={{ iiab_usb_lib_show_all }}"
- name: Install /etc/{{ apache_config_dir }}/content_dir.conf from template - name: Add 'usb_lib' variable values to {{ iiab_ini_file }}
template:
src: content_dir.conf
dest: "/etc/{{ apache_config_dir }}"
when: usb_lib_enabled | bool
- name: Create symlink content_dir.conf from sites-enabled to sites-available (debuntu)
file:
src: "/etc/{{ apache_config_dir }}/content_dir.conf"
dest: /etc/apache2/sites-enabled/content_dir.conf
state: link
when: is_debuntu | bool
- name: Remove symlink content_dir.conf from /etc/apache2/sites-enabled (debuntu)
file:
dest: /etc/apache2/sites-enabled/content_dir.conf
state: absent
when: is_debuntu and not usb_lib_enabled
- name: Remove content_dir.conf from /etc/{{ apache_config_dir }}
file:
name: "/etc/{{ apache_config_dir }}/content_dir.conf"
state: absent
when: not usb_lib_enabled
- name: Add 'usb-lib' variable values to {{ iiab_ini_file }}
ini_file: ini_file:
path: "{{ iiab_ini_file }}" path: "{{ iiab_ini_file }}"
section: usb-lib section: usb_lib
option: "{{ item.option }}" option: "{{ item.option }}"
value: "{{ item.value | string }}" value: "{{ item.value | string }}"
with_items: with_items:
- option: name - option: name
value: usb-lib value: usb_lib
- option: description - option: description
value: '"usb-lib automounts Teacher Content on USB drives to /library/www/html/local_content, so students can browse it almost immediately at http://box/usb"' value: '"usb_lib automounts Teacher Content on USB drives to /library/www/html/local_content, so students can browse it almost immediately at http://box/usb"'
- option: enabled - option: enabled
value: "{{ usb_lib_enabled }}" value: "{{ usb_lib_enabled }}"

View file

@ -19,6 +19,13 @@
shell: /usr/bin/vnstat -i {{ iiab_lan_iface }} shell: /usr/bin/vnstat -i {{ iiab_lan_iface }}
when: iiab_lan_iface is defined when: iiab_lan_iface is defined
# RECORD vnStat AS INSTALLED
- name: "Set 'vnstat_installed: True'"
set_fact:
vnstat_installed: True
- name: "Add 'vnstat_installed: True' to {{ iiab_state_file }}" - name: "Add 'vnstat_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
@ -26,7 +33,7 @@
line: 'vnstat_installed: True' line: 'vnstat_installed: True'
- name: Enable & Start vnStat's systemd service (vnstat) - name: Enable & (Re)Start 'vnstat' systemd service, if vnstat_enabled
systemd: systemd:
name: vnstat name: vnstat
daemon_reload: yes daemon_reload: yes

View file

@ -85,12 +85,19 @@
group: "{{ apache_user }}" # DO WE REALLY STILL WANT THIS FOR NGINX? group: "{{ apache_user }}" # DO WE REALLY STILL WANT THIS FOR NGINX?
mode: '0660' # Others strongly recommend '0600' (or do PHP/Apache/NGINX really need group read & write permissions?) mode: '0660' # Others strongly recommend '0600' (or do PHP/Apache/NGINX really need group read & write permissions?)
- name: Install etc/{{ apache_config_dir }}/wordpress.conf from template, for http://box{{ wp_url }} via Apache - name: Install etc/{{ apache_conf_dir }}/wordpress.conf from template, for http://box{{ wp_url }} via Apache
template: template:
src: wordpress.conf.j2 src: wordpress.conf.j2
dest: "/etc/{{ apache_config_dir }}/wordpress.conf" dest: "/etc/{{ apache_conf_dir }}/wordpress.conf"
when: apache_enabled | bool when: apache_enabled | bool
# RECORD WordPress AS INSTALLED
- name: "Set 'wordpress_installed: True'"
set_fact:
wordpress_installed: True
- name: "Add 'wordpress_installed: True' to {{ iiab_state_file }}" - name: "Add 'wordpress_installed: True' to {{ iiab_state_file }}"
lineinfile: lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml

View file

@ -21,11 +21,11 @@
quiet: yes quiet: yes
- name: Provision MySQL DB for WordPress, if 'wordpress_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml - name: Provision MySQL DB for WordPress, if 'wordpress_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: setup.yml include_tasks: setup.yml
when: wordpress_installed is undefined # and not installing when: wordpress_installed is undefined # and not installing
- name: Install WordPress if 'wordpress_installed' is not defined in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml - name: Install WordPress if 'wordpress_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
include_tasks: install.yml include_tasks: install.yml
when: wordpress_installed is undefined when: wordpress_installed is undefined

View file

@ -7,7 +7,7 @@
file: file:
path: /etc/apt/sources.list.d/yarn.list path: /etc/apt/sources.list.d/yarn.list
owner: root owner: root
mode: 0644 mode: '0644'
state: touch state: touch
- name: "Yarn | Ensure Debian package is in sources list" - name: "Yarn | Ensure Debian package is in sources list"
@ -17,8 +17,8 @@
line: 'deb http://dl.yarnpkg.com/debian/ stable main' line: 'deb http://dl.yarnpkg.com/debian/ stable main'
state: present state: present
- name: "Yarn | Update APT cache" - name: "Yarn | Update APT cache"
apt: apt:
update_cache: yes update_cache: yes
- name: "Yarn | Install" - name: "Yarn | Install"
@ -26,3 +26,16 @@
name: yarn name: yarn
state: latest state: latest
when: internet_available and is_debuntu when: internet_available and is_debuntu
# RECORD Yarn AS INSTALLED
- name: "Set 'yarn_installed: True'"
set_fact:
yarn_installed: True
- name: "Add 'yarn_installed: True' to {{ iiab_state_file }}"
lineinfile:
dest: "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp: '^yarn_installed'
line: 'yarn_installed: True'

View file

@ -57,7 +57,7 @@
#- { role: sugar-stats } #- { role: sugar-stats }
#- { role: teamviewer } #- { role: teamviewer }
- { role: transmission } - { role: transmission }
- { role: usb-lib } - { role: usb_lib }
- { role: vnstat } - { role: vnstat }
- { role: wordpress } - { role: wordpress }
#- { roles: xovis } #- { roles: xovis }

View file

@ -11,7 +11,8 @@ proxy: squid
proxy_user: squid proxy_user: squid
apache_service: httpd apache_service: httpd
apache_user: apache apache_user: apache
apache_config_dir: httpd/conf.d apache_conf_dir: httpd/conf.d
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_log_dir: /var/log/httpd apache_log_dir: /var/log/httpd
smb_service: smb smb_service: smb
nmb_service: nmb nmb_service: nmb

View file

@ -11,7 +11,8 @@ dns_user: bind
proxy: squid proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_config_dir: apache2/sites-available apache_conf_dir: apache2/sites-available
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_user: www-data apache_user: www-data
apache_log_dir: /var/log/apache2 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd

View file

@ -10,7 +10,8 @@ dns_user: bind
proxy: squid3 proxy: squid3
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_config_dir: apache2/sites-available apache_conf_dir: apache2/sites-available
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_user: www-data apache_user: www-data
apache_log_dir: /var/log/apache2 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd

View file

@ -11,7 +11,8 @@ dns_user: bind
proxy: squid proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_config_dir: apache2/sites-available apache_conf_dir: apache2/sites-available
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_user: www-data apache_user: www-data
apache_log_dir: /var/log/apache2 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd

View file

@ -11,7 +11,8 @@ proxy: squid
proxy_user: squid proxy_user: squid
apache_service: httpd apache_service: httpd
apache_user: apache apache_user: apache
apache_config_dir: httpd/conf.d apache_conf_dir: httpd/conf.d
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_log_dir: /var/log/httpd apache_log_dir: /var/log/httpd
smb_service: smb smb_service: smb
nmb_service: nmb nmb_service: nmb

View file

@ -11,7 +11,8 @@ proxy: squid
proxy_user: squid proxy_user: squid
apache_service: httpd apache_service: httpd
apache_user: apache apache_user: apache
apache_config_dir: httpd/conf.d apache_conf_dir: httpd/conf.d
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_log_dir: /var/log/httpd apache_log_dir: /var/log/httpd
smb_service: smb smb_service: smb
nmb_service: nmb nmb_service: nmb

View file

@ -15,7 +15,8 @@ dhcp_service: isc-dhcp-server
proxy: squid proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_config_dir: apache2/sites-available apache_conf_dir: apache2/sites-available
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_user: www-data apache_user: www-data
apache_log_dir: /var/log/apache2 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd

View file

@ -14,7 +14,8 @@ dns_user: bind
proxy: squid3 proxy: squid3
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_config_dir: apache2/sites-available apache_conf_dir: apache2/sites-available
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_user: www-data apache_user: www-data
apache_log_dir: /var/log/apache2 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd

View file

@ -15,7 +15,8 @@ dhcp_service: isc-dhcp-server
proxy: squid proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_config_dir: apache2/sites-available apache_conf_dir: apache2/sites-available
apache_config_dir: "{{ apache_conf_dir }}" # for iiab-admin-console/roles/console/tasks/main.yml Line 150
apache_user: www-data apache_user: www-data
apache_log_dir: /var/log/apache2 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd

View file

@ -12,7 +12,8 @@ proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_user: www-data apache_user: www-data
apache_config_dir: apache2/sites-available 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 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd
nmb_service: nmbd nmb_service: nmbd

View file

@ -12,7 +12,8 @@ proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_user: www-data apache_user: www-data
apache_config_dir: apache2/sites-available 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 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd
nmb_service: nmbd nmb_service: nmbd

View file

@ -12,7 +12,8 @@ proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_user: www-data apache_user: www-data
apache_config_dir: apache2/sites-available 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 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd
nmb_service: nmbd nmb_service: nmbd

View file

@ -12,7 +12,8 @@ proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_user: www-data apache_user: www-data
apache_config_dir: apache2/sites-available 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 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd
nmb_service: nmbd nmb_service: nmbd

View file

@ -12,7 +12,8 @@ proxy: squid
proxy_user: proxy proxy_user: proxy
apache_service: apache2 apache_service: apache2
apache_user: www-data apache_user: www-data
apache_config_dir: apache2/sites-available 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 apache_log_dir: /var/log/apache2
smb_service: smbd smb_service: smbd
nmb_service: nmbd nmb_service: nmbd