Part III — Giving shade

05 · The gathering's network: preparing the shade

Before the circle, someone sweeps the yard and lays the mat under the tree.

This chapter is for whoever organises the gathering: a workshop, a festival, a three-day congress, a school. The idea is that anyone who arrives can, with just their phone and without internet, open the mucua's site, create an account, chat and send photos.

Two ways to set up the network

The two ways: the mucua creates the network, or the mucua on cable with routers

1. The mucua creates the network (MODO=ponto, or the menu option criar a propria rede Wi-Fi). Nothing else is needed: the mucua becomes the open Baobaxia Wi-Fi and hands out an address to each phone.

  • It's the simplest way — switch on and it works.
  • An ordinary computer's Wi-Fi card usually copes with 10 to 30 devices at once. Plenty for a workshop; not enough for an auditorium.
  • If the mucua is also on a cable with internet, it shares the internet with whoever is on its network.

2. The mucua on cable, and routers doing the Wi-Fi. For a lot of people, use real routers or access points and plug the mucua into them by cable (MODO=cliente, or auto without WIFI_NOME).

  • It copes with hundreds of people: the Wi-Fi is the routers' job.
  • The site opens at http://baobaxia.local or at the mucua's IP. For the padlock address to work (local.baobaxia.net), the router needs two things: always give the mucua the same IP (a DHCP reservation) and point local.baobaxia.net to that IP (local DNS). Not every home router does this.

The padlock address

An https:// address with a padlock unlocks things on the phone: the camera and microphone in the browser (live broadcasting), and "install the site as an app". For that, the image must have come with a certificate — for example for local.baobaxia.net.

On the network the mucua creates, it answers by itself that local.baobaxia.net and baobaxia.local are itself (its address there is always 10.42.0.1). To make it work even on phones that ask somewhere else (mobile data, Android's "private DNS"), whoever looks after the domain can create this record on the internet:

local.baobaxia.net.   A   10.42.0.1

The certificate lasts 90 days. Get a new one before an important gathering (the command is baobaxia-certificado obter). Ask for one with a wildcard (*.local.baobaxia.net): it also covers the chat's file uploads (arquivos.local.baobaxia.net) and other mucuas at the same place (mucua2.local.baobaxia.net).

Phones and "Wi-Fi without internet"

On a network without internet, Android usually warns "no internet access" and sends everything over mobile data — and the mucua's site "doesn't open". That's why, on the network the mucua creates, it answers the phones' "is there internet?" checks, and they use the Wi-Fi normally. In baobaxia-rede.txt:

LineWhat it does
PORTAL=simdefault. The phone thinks there is internet and stays on the mucua's Wi-Fi.
PORTAL=abrirWhen connecting, the phone shows "Sign in to network" and opens the mucua's page by itself. Some Androids use mobile data for everything else.
PORTAL=naoLeaves it alone.

And, when the mucua has no internet, any site someone tries to open leads to its page (REDIRECIONAR=auto). https:// sites show a security warning — it's the browser protecting you; just type the mucua's address.

Several mucuas at the same place

At a big gathering you can have more than one mucua, sharing the load:

  • each with its own network name (PONTO_NOME=Baobaxia-Stage, Baobaxia-Workshops…), if each one creates its own;
  • the address baobaxia.local goes to the first one switched on; the others become baobaxia-2.local, baobaxia-3.local… (each one's IP shows on its screen);
  • with the wildcard certificate, each can have its own padlock name: mucua2.local.baobaxia.net;
  • they exchange knowledge among themselves, as in any galaxy.

The "Just joined the network?" page and the poster

On a gathering mucua — with the local chat turned on or with the chat app stored on it — the site gets an arrival page: Just joined the network? Start here (chapter 06). It has a Print poster button, which produces this:

The printed poster, with the QR codes for the site, the app, the room and the bot

Print it, stick it at the entrance, on the tables, on the room's wall. It's the map for whoever arrives.

The day before

A checklist to go through calmly, before the day:

  1. The mucua switches on by itself and shows its address on screen.
  2. A phone joins the Wi-Fi and opens the site — through the poster's QR.
  3. You can create an account and log in.
  4. The chat app downloads from the mucua itself, logs in with the account and gets to the room.
  5. Sending a photo to the bot returns the link of the knowledge item.
  6. The mucua's clock is right (with the wrong time, the browser refuses the certificate).
  7. The admin password is written down, and baobaxia-credenciais.txt has been deleted.
  8. The posters are printed.

ver este capítulo como saber