1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-02-13 11:42:08 +00:00

Merge pull request #274 from iiab/master

sync from iiab/iiab
This commit is contained in:
A Holt 2019-07-23 16:50:38 -04:00 committed by GitHub
commit 67e40978ce
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 32 additions and 15 deletions

View file

@ -1,17 +1,26 @@
#!/bin/bash -x
# Pull down repo's entire wiki (and similar) to create offline docs
# This /opt/iiab/iiab/roles/httpd/templates/refresh-wiki-docs.sh becomes
# /usr/bin/iiab-refresh-wiki-docs during IIAB's install.
set -e
source {{ iiab_env_file }}
# This pulls down iiab/iiab repo's entire Tech Docs Wiki (and scrapes/downloads
# other docs!) to create IIAB's offline docs collection: http://box/info
# TO DO: find more pages to download/scrape and offline links to fix,
# based on "fieldback" from truly remote implementer/operators.
set -e # Exit on error (avoids snowballing)
source {{ iiab_env_file }} # /etc/iiab/iiab.env
INPUT=/tmp/iiab-wiki
OUTPUT=/tmp/iiab-wiki.out
DESTPATH=/library/www/html/info
DESTPATH={{ doc_root }}/info # /library/www/html/info
DOCSPATH=$DESTPATH/docs # /library/www/html/info/docs
rm -rf $INPUT
rm -rf $OUTPUT
mkdir -p $INPUT
mkdir -p $OUTPUT
mkdir -p $DOCSPATH
git clone https://github.com/iiab/iiab.wiki.git $INPUT
@ -23,8 +32,6 @@ done
rsync -av $OUTPUT/ $DESTPATH
# To Do: find more pages to d/l and offline links to fix, based on "fieldback" from truly remote implementer/operators
# Download FAQ etc
lynx -reload -source http://wiki.laptop.org/go/IIAB/FAQ > $DESTPATH/FAQ.html
lynx -reload -source http://wiki.laptop.org/go/IIAB/Security > $DESTPATH/Security.html
@ -38,14 +45,20 @@ lynx -reload -source https://github.com/XSCE/xsce/blob/release-6.2/ReleaseNotes6
lynx -reload -source https://github.com/XSCE/xsce/blob/release-6.2/ReleaseNotes6.1.md > $DESTPATH/ReleaseNotes6.1.html
# Download Raspberry Pi guides
wget -nc -P $DESTPATH https://www.raspberrypi.org/magpi-issues/Beginners_Guide_v1.pdf
wget -nc -P $DESTPATH https://dn.odroid.com/IoT/other_doc.pdf
wget -nc https://www.raspberrypi.org/magpi-issues/Beginners_Guide_v1.pdf -O $DOCSPATH/Raspberry_Pi_Beginners_Guide_v1.pdf || true # Overrides set -e
wget -nc https://dn.odroid.com/IoT/other_doc.pdf -O $DOCSPATH/Raspberry_Pi_User_Guide_v4.pdf || true
# Update Raspberry Pi guide links on main page (http://box/info)
sed -i -r "s|https://www.raspberrypi.org/magpi-issues/Beginners_Guide_v1.pdf|Beginners_Guide_v1.pdf|g" $DESTPATH/index.html
sed -i -r "s|https://dn.odroid.com/IoT/other_doc.pdf|other_doc.pdf|g" $DESTPATH/index.html
# Copy PDF from Lokole playbook
cp -p "{{ iiab_dir }}/roles/lokole/Lokole-IIAB_Users_Manual.pdf" $DOCSPATH # From /opt/iiab/iiab
# Make links refer to local items
# MAKE LINKS REFER TO LOCAL ITEMS...
# ...on main page (http://box/info)
sed -i -r "s|https://www.raspberrypi.org/magpi-issues/Beginners_Guide_v1.pdf|docs/Raspberry_Pi_Beginners_Guide_v1.pdf|g" $DESTPATH/index.html
sed -i -r "s|https://dn.odroid.com/IoT/other_doc.pdf|docs/Raspberry_Pi_User_Guide_v4.pdf|g" $DESTPATH/index.html
sed -i -r "s|https://github.com/iiab/iiab/blob/master/roles/lokole/Lokole-IIAB_Users_Manual.pdf|docs/Lokole-IIAB_Users_Manual.pdf|g" $DESTPATH/index.html
# ...and within subpages
for f in $DESTPATH/*.html; do
sed -i -r "s|https://github.com/iiab/iiab/wiki/([-.A-Za-z0-9]*)|\1.html|g" $f

View file

@ -80,7 +80,7 @@ Lokole and Internet-in-a-Box would welcome a business plan (whether volunteer-ba
Troubleshooting
---------------
For further usage information and troubleshooting, refer to the `Lokole user manual <https://github.com/iiab/iiab/raw/master/roles/lokole/The%20Lokole-IIAB%20User's%20Manual.pdf>`_.
For further usage information and troubleshooting, refer to the `Lokole user manual <Lokole-IIAB_Users_Manual.pdf>`_.
Known Issues
------------

View file

@ -1,3 +1,6 @@
# Lokole PDF (User's Guide) gets copied for offline use (http://box/info) here:
# https://github.com/iiab/iiab/blob/master/roles/httpd/templates/refresh-wiki-docs.sh#L47
- name: "Install 7 packages for Lokole: python3, python3-pip, python3-venv, python3-dev, libffi-dev, libssl-dev, bcrypt"
apt:
name:

View file

@ -30,6 +30,7 @@
owner: "{{ item.owner }}"
group: "{{ item.group }}"
mode: "{{ item.mode }}"
force: no
with_items:
- src: 'roles/network/templates/squid/squid.sysconfig'
dest: '/etc/sysconfig/squid'

View file

@ -35,8 +35,8 @@ acl whitelist dstdomain "/etc/{{ proxy }}/sites.whitelist.txt"
acl school src 172.18.0.0/16
#acl localhost src 127.0.0.1/32
#acl to_localhost dst 127.0.0.0/8
acl localhost src 127.0.0.1/32
acl to_localhost dst 127.0.0.0/8
acl to_schoolserver dst 178.16.0.0/16 # to schoolserver or other local hosts.
acl SSL_ports port 443
acl Safe_ports port 80 # http