2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 12:49:34 +00:00
fhem-mirror/fhem/webfrontend/pgm2
rudolfkoenig cd7523c23d 4.5 Prep
git-svn-id: https://svn.fhem.de/fhem/trunk@274 2b470e98-0d58-463d-a4d8-8e2adae1ed80
2008-12-03 16:49:19 +00:00
..
01_FHEMWEB.pm 4.5 Prep 2008-12-03 16:49:19 +00:00
98_SVG.pm FHEMWEB cleanup, some small additional fixes/additions 2008-08-08 10:46:25 +00:00
98_weblink.pm FHEMWEB cleanup, some small additional fixes/additions 2008-08-08 10:46:25 +00:00
cpulog.gplot FHEMWEB cleanup, some small additional fixes/additions 2008-08-08 10:46:25 +00:00
cul_em.gplot 4.5 Prep 2008-12-03 16:49:19 +00:00
cul_ws.gplot 4.5 Prep 2008-12-03 16:49:19 +00:00
em.gplot Preparing 4.4: Doc checking and small fixes 2008-07-28 12:33:29 +00:00
fht.gplot Preparing 4.4: Doc checking and small fixes 2008-07-28 12:33:29 +00:00
fs20.gplot Preparing 4.4: Doc checking and small fixes 2008-07-28 12:33:29 +00:00
FS20.off.gif Initial version 2007-01-30 12:47:36 +00:00
FS20.on.gif Initial version 2007-01-30 12:47:36 +00:00
garden.gplot FHEMWEB cleanup, some small additional fixes/additions 2008-08-08 10:46:25 +00:00
hms_tf.gplot Cosmetic change reported by Klaus 2008-08-12 10:49:19 +00:00
ks300_1.gplot Small fixes / avg_month gnuplot 2008-08-01 07:44:06 +00:00
ks300_2.gplot Small fixes / avg_month gnuplot 2008-08-01 07:44:06 +00:00
ks300_3.gplot Small fixes / avg_month gnuplot 2008-08-01 07:44:06 +00:00
ks300_4.gplot Small fixes / avg_month gnuplot 2008-08-01 07:44:06 +00:00
mpiri.gplot Preparing 4.4: Doc checking and small fixes 2008-07-28 12:33:29 +00:00
Next.png WebPgm2 gnuplot scrolling 2008-06-12 07:22:59 +00:00
piri.gplot Preparing 4.4: Doc checking and small fixes 2008-07-28 12:33:29 +00:00
Prev.png WebPgm2 gnuplot scrolling 2008-06-12 07:22:59 +00:00
README fhemweb.pl converted to a FHEM module 2007-12-31 14:43:02 +00:00
style.css CUL_WS / CUL changes 2008-10-12 15:07:46 +00:00
svg_style.css FHEMWEB cleanup, some small additional fixes/additions 2008-08-08 10:46:25 +00:00
Zoom-in.png WebPgm2 gnuplot scrolling 2008-06-12 07:22:59 +00:00
Zoom-out.png WebPgm2 gnuplot scrolling 2008-06-12 07:22:59 +00:00

Installation:
=============
- copy the gif files to the destination directory
  cp *.gif /home/httpd/icons
- copy docs/commandref.html to the doc directory
  cp ../..docs/commandref.html /home/httpd/html
- check if the above directories are set correctly in 01_FHEMWEB.pm
  vi 01_FHEMWEB.pm
- copy 01_FHEMWEB.pm to the fhem module directory
  cp *.pm /usr/local/lib/FHEM
- restart fhem.pl
- define a new FHEMWEB instance in fhem
  define WEB FHEMWEB 8080 global

Now you can access it from the web browser via
  http://<yourhost>:8080/fhem

Additional features:
====================
- Rooms: If you have more than 10 devices/logs/notifies/etc. then it make sense
  to divide them into "rooms". For this purpose assign the attribute room to
  each device.
- hide devices: Devices in the room "hidden" will not be shown. Devices without
  a room attribute go to the room "Unsorted".
- Title: You can set the title of the webpage with 
    attr global title "My-Title"
- If you set the attribute model of an FS20 device, and the device is an
  FS20-sender, then you will not be able to switch it from the frontend.
- You can first set an attribute to an arbitrary (wrong) value, then click on
  the attribute: you will be guided to the correct place in the documentation;
  now you can chnage the attribute value to the correct one.
- To log the HTTP requests in the logfile, either set the global verbose to a
  value greater than 3 or set the HTTP device loglevel to a lower value
   attr <FHEMWEBDEVICE> loglevel 2
  

Graphs for plotted logs (gnuplot):
==================================
- Set FHEMWEB_gnuplot in 01_FHEMWEB.pm to the gnuplot binary
- copy the gnuplot files to the gnuplot scripts to the gnuplot directory
  cp *.gplot /home/httpd/cgi-bin
- copy 99_weblink.pm to the FHEM modules directory and restart fhem.pl
- assign the logtype attribute to your FileLog device.
  Look at the XXX.gplot file, how the FileLog should be defined, and
  set the corresponding logtype attribute to XXX.
  You can use more than one logtype, see commandref.html for more.
- To show more than one plot on one page, convert them to weblink, and assign
  each weblink the same room. If a weblink is created for the CURRENT logfile,
  it will always use the CURRENT logfile.

Password/HTTPS:
===============
- These features are implemented by apache, and apache must be configured to
  redirect the page to 01_FHEMWEB.pm. For this purpose add the following lines
  to your httpd.conf:

  <Proxy *>
    AuthType Basic
    AuthName "Password Required"
    AuthUserFile /home/httpd/etc/passwd
    Require valid-user
    Allow from 127.0.0.1
  </Proxy>
  ProxyPass        /fhem  http://localhost:<FHEMPORT>/fhem
  ProxyPassReverse /fhem  http://localhost:<FHEMPORT>/fhem

  and then restart httpd with apachectl graceful. To create the password file,
  execute htpasswd -c /home/httpd/etc/passwd <username>

- To enable HTTPS, please check the web.
  In essence:
  - Edit httpd.conf, add:
      LoadModule ssl_module lib/apache/mod_ssl.so
      Include /etc/httpd/conf/ssl.conf
  - Create a server certificate
  - Start httpd with the startssl option (SSL or the like must be set in one
    of your system files, look at /etc/init.d/httpd).