Fixes#275.
Use this as the systemd unit file to run as a service:
[Unit]
Description=Dougal Network Packet Capture
After=network.target remote-fs.target nss-lookup.target
[Service]
ExecStart=/srv/dougal/software/sbin/packet-capture.sh
ExecStop=/bin/kill -s QUIT $MAINPID
Restart=always
User=root
Group=users
Environment=PATH=/usr/bin:/usr/sbin:/usr/local/bin
Environment=INS_HOST=172.31.10.254
WorkingDirectory=/srv/dougal/software/var/
SyslogIdentifier=dougal.pcap
[Install]
WantedBy=multi-user.target
Use https://open-meteo.com/ as a weather forecast provider.
This code is intended for demonstration only, not for
production purposes.
(issue #157)
(cherry picked from commit cc4bce1356)
- `tooltip` takes the name of a GeoJSON property that will be
shown in a tooltip when hovering the mouse over a feature.
- `popup` can take either the name of a property as above, or
the boolean value `true`. In the latter case, a table of all
the feature's properties will be shown when clicking on the
feature. In the former case, only the value of the designated
property will be shown.
The map view limits the size of layers (both user and regular) in
order to keep the system responsive, as Leaflet is not great at
handling large layers.
The user layers are defined in the project configuration under
`imports.map.layers`.
Multiple layers may be defined and each layer may consist of one
or more GeoJSON files. Files are retrieved via the /files/ API
endpoint.
- A single get() function is used both to list all available
layers, if no layer name is given, or a single layer.
- The database no longer holds the actual layer contents,
only the path to the layer file(s), so the list() function
is now redundant as we return the full payload in every case.
- The /gis/layer and /gis/layer/:name endpoints now have the same
payload structure.
- Now a layer may consist of a path pointing to a directory plus a
glob, or a path pointing directly to a single file.
- If a file already exists in the database, check if the layer
name has changed and if so, update it.
- Do not import the actual file contents, as the path is enough
(it can be retrieved via the /file/:path API endpoint).