README 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. README FOR THE TUX MODULE (by Sascha Schumann)
  2. ($Date$)
  3. This is a SAPI module for the TUX web-server by Ingo Molnar.
  4. The special thing about TUX is that it is integrated into the Linux
  5. kernel and thus provides high-speed serving of static files.
  6. The web-server provides a user-space API which allows arbitrary
  7. plug-ins to be made available.
  8. All requests to the PHP userspace module are currently serialized.
  9. This module is of alpha quality. Due to incomplete APIs, HTTP
  10. authentication and handling of POST requests has not been
  11. implemented yet.
  12. SECURITY NOTE: PHP will happily run everything under the
  13. web-root through the parser; so be careful what you put
  14. there.
  15. Note that requests are served in a chroot'ed environment.
  16. The initialization of PHP does not take place in the chroot'ed
  17. environment, so that e.g. /usr/local/lib/php.ini is treated
  18. as usual.
  19. REQUIRED DOWNLOADS
  20. 1. TUX
  21. http://people.redhat.com/~mingo/TUX-patches/QuickStart-TUX.txt
  22. 2. PHP 4.0.x
  23. Download:
  24. http://www.php.net/
  25. Snapshots from CVS:
  26. http://snaps.php.net/
  27. BUILD INSTRUCTIONS
  28. 1. Install TUX as outlined in the QuickStart text.
  29. Create /tux-modules where modules will reside.
  30. 2. Prepare PHP
  31. $ cd php-*
  32. $ ./configure \
  33. --with-tux=/tux-modules \
  34. <further PHP options>
  35. # make install
  36. You can see the list of valid PHP options by executing
  37. $ ./configure --help
  38. 3. Touch a file in your web-root 'php5.tux'. This will
  39. cause requests to '/php5.tux' to be redirected to the
  40. userspace module php5.tux.
  41. 4. Start TUX with something like
  42. # tux -d -t 8 -r /www -m /tux-modules php5.tux
  43. (daemon mode, eight threads, web-root /www, modules in
  44. /tux-modules, load php5.tux)
  45. BEFORE running this command, the kernel side of TUX has to
  46. be properly setup.
  47. 5. Try to access
  48. http://yourserver/php5.tux?=PHPB8B5F2A0-3C92-11d3-A3A9-4C7B08C10000
  49. It should display the PHP credits page.
  50. To access a script /foo/bar.php, use
  51. http://yourserver/php5.tux?/foo/bar.php
  52. Parameters can be appended:
  53. http://yourserver/php5.tux?/foo/bar.php&var=value