Installation
------------

Requirements to show a graph:

- PHP: Language version needed is 7.4+.

- Program files: Download syweb-version.tar.gz from the website and
  copy htdocs/ and symon/ from the archive into ~www.

- Data files: Make your symon rrds accessable to php as run by your
  http server. Move them into ~www/symon/rrds and update symux.

- Configuration: Customise ~www/htdocs/syweb/setup.inc. The supplied
  setup.inc is intended for chrooted httpd using php-fpm on OpenBSD.

- RRDtool: Must be available in whatever web container you are
  using. E.g. for OpenBSD chrooted httpd, rrdtool must be available
  inside the chroot.

- Date & time: chrooted httpd may have a different idea of
  timezone. Add etc/localtime to chroot if needed.

Point your browser to http://127.0.0.1/syweb/configtest.php to test the
configuration. This page will show if the application cannot deal with a
setting in setup.inc.

Point your browser to http://127.0.0.1/syweb/index.php for the main page.

You can move index_noui.php to index.php if you do not need the ui.


RRDTool and chrooted httpd
--------------------------

RRDTool has a large number of requirements that it must be able to
access in order to run. This can require copying a fair number of
files inside your chrooted httpd.

- Dynamically linked libraries: find out using ldd rrdtool

- Dynamically linking kit: ld.so must be available inside chroot to do
  the dynamic linking, and must be fed a chroot adjusted
  ~www/var/run/ld.so.hints

- Fonts data: a subset of fonts from
  /usr/X11R6/lib/X11/fonts/TTF/DevaVuSansMono* must be available in a
  ~www/fontdirectory.

- Font configuration: "fontdirectory" must be specified in chroot
  ~www/etc/fonts/fonts.conf.

And finally:

- sh binary: this is needed by PHP to be able to execute rrdtool.

All these steps are detailed for OpenBSD in install_rrdtool.sh.