1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-03-09 15:40:17 +00:00

Merge pull request #3 from iiab/master

Sync with upstream
This commit is contained in:
Blondel MONDESIR 2024-10-01 16:13:34 -04:00 committed by GitHub
commit 9302dfbd65
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 13 additions and 8 deletions

View file

@ -18,6 +18,9 @@
ignore_errors: True # Shows red errors, and continue...
#failed_when: False # Hides red errors, and continue...
# Official upstream instructions:
# apt install python3-pip python3-venv
# https://github.com/janeczku/calibre-web/wiki/Manual-installation
- name: "Install packages: imagemagick, python3-netifaces"
package:
name:

View file

@ -5,7 +5,7 @@
# If nec, change them by editing /etc/iiab/local_vars.yml prior to installing!
mediawiki_major_version: "1.42" # "1.40" quotes nec if trailing zero
mediawiki_minor_version: 1
mediawiki_minor_version: 3
mediawiki_version: "{{ mediawiki_major_version }}.{{ mediawiki_minor_version }}"
mediawiki_download_base_url: "https://releases.wikimedia.org/mediawiki/{{ mediawiki_major_version }}"

View file

@ -62,7 +62,7 @@ echo -e " tailscale logout\n"
#tailscale status --json | jq -r '.Self,.Peer[] | .Tags[] + " " + .TailscaleIPs[] + " " + .HostName + " " + .DNSName + " " + .OS + " " + .Relay + " " + (.Online|tostring)' | sort -V | column -t
#echo -e '\e[44;1mVPN peers: ("true" in 6th column means online)\e[0m\n'
echo -e '\e[44;1mVPN peers: (6th column = online/offline)\e[0m\n'
tailscale status --json | jq -r '.Self,.Peer[] | .Tags[] + " " + .TailscaleIPs[] + " " + .HostName + " " + .DNSName + " " + .Relay + " XXX" + (.Online|tostring) + "XXX " + .OS' | sort -V | column -t | \
tailscale status --json | jq -r '.Self,.Peer[] | (if .Tags[] == "" then "-" else .Tags[] end) + " " + .TailscaleIPs[] + " " + .HostName + " " + .DNSName + " " + (if .Relay == "" then "-" else .Relay end) + " XXX" + (.Online|tostring) + "XXX " + .OS' | sort -V | column -t | \
while read l; do
line=$(echo "$l" | sed 's/ XXXtrueXXX /\\e[0;32m ✅\\e[0m/ ; s/ XXXfalseXXX /\\e[0;31m ❌ \\e[0m/')
echo -e "$line" $(tailscale whois --json $(echo $line | cut -d' ' -f2) | jq -r '.Node.Hostinfo | .Distro + " " + .DistroVersion + " " + .DeviceModel');

View file

@ -94,10 +94,12 @@
# 2022-06-30: internet_available var removed
- name: 'Test for Internet access, using: {{ iiab_download_url }}/heart-beat.txt'
- name: 'Test for Internet access, using: https://wiki.iiab.io'
get_url:
url: "{{ iiab_download_url }}/heart-beat.txt"
dest: /tmp/heart-beat.txt
#url: "{{ iiab_download_url }}/heart-beat.txt"
url: https://wiki.iiab.io
#dest: /tmp/heart-beat.txt
dest: /tmp/internet_access_test.html
#timeout: "{{ download_timeout }}"
# @jvonau recommends: 100sec is too much (keep 10sec default)
ignore_errors: True
@ -105,9 +107,9 @@
#poll: 2
register: internet_access_test
- name: Remove downloaded Internet test file /tmp/heart-beat.txt
- name: Remove downloaded Internet test file /tmp/internet_access_test.html
file:
path: /tmp/heart-beat.txt
path: /tmp/internet_access_test.html
state: absent
- name: Run /usr/bin/iiab-refresh-wiki-docs (scraper script) to create http://box/info offline documentation. (This script was installed in Stage 3 = roles/3-base-server/tasks/main.yml, which ran roles/www_base/tasks/main.yml)

View file

@ -222,7 +222,7 @@ nginx_high_php_limits: False
apache_allow_sudo: False
# Toggle iiab-refresh-wiki-docs scraping for offline docs (http://box/info)
nodocs: False
nodocs: True
# 5-XO-SERVICES