mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
kiwix - add when nginx_enabled - restart2
This commit is contained in:
parent
de5cdde3cc
commit
3e9ffb8987
3 changed files with 40 additions and 7 deletions
|
@ -104,7 +104,25 @@
|
|||
src: /etc/apache2/sites-available/kiwix.conf
|
||||
path: /etc/apache2/sites-enabled/kiwix.conf
|
||||
state: link
|
||||
when: is_debuntu | bool
|
||||
when: kiwix_enabled | bool and not nginx_enabled | bool
|
||||
|
||||
- name: Install nginx support
|
||||
template:
|
||||
backup: no
|
||||
src: "{{ item.src }}"
|
||||
dest: "{{ item.dest }}"
|
||||
owner: root
|
||||
group: root
|
||||
mode: "{{ item.mode }}"
|
||||
with_items:
|
||||
- { src: 'kiwix-nginx.conf', dest: '/etc/nginx/conf.d/kiwix-nginx.conf', mode: '0644' }
|
||||
when: kiwix_enabled | bool and nginx_enabled | bool
|
||||
|
||||
- name: Remove symlink /etc/apache2/sites-enabled/kiwix.conf
|
||||
file:
|
||||
path: /etc/apache2/sites-enabled/kiwix.conf
|
||||
state: absent
|
||||
when: not kiwix_enabled | bool or nginx_enabled | bool
|
||||
|
||||
- name: Enable & Restart 'kiwix-serve' service
|
||||
systemd:
|
||||
|
@ -142,9 +160,22 @@
|
|||
when: kiwix_enabled and is_redhat
|
||||
|
||||
- name: Restart Apache, so it picks up kiwix.conf
|
||||
service:
|
||||
systemd:
|
||||
name: "{{ apache_service }}"
|
||||
state: restarted
|
||||
when: not nginx_enabled | bool
|
||||
|
||||
- name: Remove nginx support for kiwix
|
||||
file:
|
||||
path: /etc/nginx/conf.d/kiwix-nginx.conf
|
||||
state: absent
|
||||
when: not kiwix_enabled | bool
|
||||
|
||||
- name: Restart nginx, so it picks up kiwix-nginx.conf state
|
||||
systemd:
|
||||
name: nginx
|
||||
state: restarted
|
||||
when: nginx_enabled | bool
|
||||
|
||||
# 5. FINALIZE
|
||||
|
||||
|
|
|
@ -5,18 +5,20 @@
|
|||
1. Principal functions migrated to nginx.
|
||||
* Admin Console
|
||||
* Awstats
|
||||
* kiwix -- goes directly to port 3000
|
||||
* kalite -- goes directly to port 8009
|
||||
* calibre-web
|
||||
* kolibri
|
||||
* usb-lib
|
||||
* maps
|
||||
2. Still proxied to Apache
|
||||
2. Dual support
|
||||
* kiwix -- goes directly to port 3000
|
||||
* calibre-web
|
||||
* kolibri
|
||||
* sugarizer
|
||||
3. Still proxied to Apache
|
||||
* mediawiki
|
||||
* elgg
|
||||
* nodered
|
||||
* nextcloud
|
||||
* wordpress
|
||||
* moodle
|
||||
3. Not dealt with yet
|
||||
4. Not dealt with yet
|
||||
* archive.org
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue