summaryrefslogtreecommitdiffstats
path: root/README.rst
blob: 28e4f8b4c625067db65fdabc482b4b2e5d0fda5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
`Warsaw Hackerspace`_  presence tracker hosted on https://at.hackersapce.pl. It
uses dhcpd.leases file to track MAC adressess of devices connected to hs LAN
network.

.. _Warsaw Hackerspace: https://hackerspace.pl

Setup
-----
.. code:: bash

    cp at.cfg.dist at.dist

    # edit config file using your favourite editor
    $EDITOR at.cfg

    # create new database file (or copy existing one)
    sqlite3 at.db < dbsetup.sql

    # create python virtual environment
    python3 -m venv vevnv
    ./venv/bin/python3 -m pip install -r requirements
    ./venv/bin/python3 -m pip install gunicorn

Running
-------
.. code:: bash

   ./venv/bin/gunicorn run:app

When running on OpenBSD make sure to pass '--no-sendfile' argument to gunicorn
command. This will prevent AttributeError on os.sendfile that seems to be
missing in this marvelous OS-es python3 stdlib.