Lighttpd Serving Wikidot
tags: files lighttpd serving uploaded wikidot
12 Jun 2008 06:46
I work on the configuration of the Lighttpd webserver and Wikidot tweaks to eventually run Wikidot on Lighttpd.
The configuration of Lighttpd:
- .htaccess rewritten to lighttpd.conf
- all rules are rewrite-once (like RewriteRule [L] in Apache)
- mixing rewrite-repeat with rewrite-once is tricky
- standard lighttpd fastcgi php configuration
- serving uploaded files through php program (no more flags/private)
- non-existing avatars handled by 404 error handler on avatar directories
The tweaks in Wikidot:
- sanitized PrivateFileFlowController
- created new: UploadedFileFlowController
- they can eventually become one file (PrivateFileFlowController shouldn't be needed anymore)
- created new: local.php (to substitute private_file_filter.php)
- SSL seem to work correctly
Still to do:
- replace (configure the backend) readfile() with Header("X-Sendfile…")
- UploadedFileFlowController should deal with:
- redirections
- html files
- secure *.wdupload.wikidotsyndication.com domain
- SSL
- magic database better
UPDATE: 2008-06-13: done some things, still to do:
- replace (configure the backend) readfile() with Header("X-Sendfile…")
- SSL is not ready, because $_SERVER["HTTPS"] is not supported in fast-cgi
PROPER FLOW:
if HOST = *.wdupload.wikidotsyndication.com:
URL = http[s]://[site].wdupload.wikidotsyndication.com/files--upload/[file]
send = 1
else:
URL = http[s]://[domain]/files--upload/[file]
if file is text/html or xml+html:
301 to http[s]://[site].wdupload.wikidotsyndication.com/files--upload/[file]
else
send=1
if send:
check permissions
set mime type
send file
Comments: 1
PingBacks To Come To Wikidot
tags: back blog dev ping pingback wikidot work
06 Jun 2008 15:52
I'm currently working on PingBack implementation (both server and client) for current Wikidot software.
The documentation for PingBack is located here: http://hixie.ch/specs/pingback/pingback
The changes will be available on the wiki farm www.wikidot.com and will be incorporated in the open-sourced version www.wikidot.org
We've noticed there are many posts on Wordpress about Wikidot, bunch of them:
- http://docudork.wordpress.com/2008/02/10/wikidot-platform-released-as-open-source-under-affero-gplv3-license/
- http://joeos.wordpress.com/english-education/wikidot/
- http://compmatsci.wordpress.com/2007/12/29/wikidot-ing/
- http://jonnyengland.wordpress.com/2007/05/08/wikidot/
and we want to make a smart move to let people from both services (and many more) know what happens on the other.
PingBack is also known to work for many many other services than just WordPress.
Comments: 1
Ubuntu Server 7.10 Wikidot Clean Install
tags: blog dev machine server ubuntu virtual wikidot
12 Mar 2008 21:10
After creating-a-space-for-virtual-machines-host it's time to prepare a very first productional Wikidot installation on a virtual disk image.
The problems I've encountered:
1. Compiling the PCRE not gave me the expected results (using heap for recursion matches).
More to come…
Comments: 2
Creating a space for Virtual Machines host
tags: blog dev farm machine virtual virtualbox wiki
11 Mar 2008 22:43
Look at this:
http://dev.wikidot.com/farm-hosting
We want to make some Virtual hosting
I prepare the environment for it.
At first, it'll be the same server like the wikidot.com. In order to install VirtualBox i needed to:
yum install SDL.x86_64
yum install qt.x86_64
ldconfig
rpm -ihv VirtualBox-1.5.6_28266_rhel5-1.x86_64.rpm
(got from here: http://www.virtualbox.org/download/1.5.6/)
then:
/etc/init.d/vboxdrv setup
I added user vbuser with
- the group vboxusers (added by the RPM installation) — group of users that can run VirtualBox
- home: /vol/disk1/home-vbuser
- /home/vbuser links to /vol/disk1/home-vbuser
I started the VNC session with some gnome-panel and metacity for the user.
To do this again (in order one killed that) do:
vncserver
To stop:
killall Xvnc (this will probably kill all running virtual machines).
To connect to it just forward 5903 (this is :3 session of VNC) to localhost, in ssh:
ssh -L 5903:localhost:5903
and connect with a VNC client to the localhost:3
this way you don't transfer the plain password via the network. (the plain password goes through the SSH tunnel).
I created some test machine with a UbuntuServer on it (version 7.10 Gutsy Gibbon i386!!) and needed pkgs for wikidot.com (and the source from svn).
- RAM: 750MB
- disk: 20 GB auto-resize, LVM, guided partition scheme
- network: NAT — change to tun interface
NOTE
This does not work out of the box, we must exchange the kernel like described here: http://tombuntu.com/index.php/2007/09/05/making-ubuntu-server-work-in-virtualbox/
Rescue the system, go to sheel and then:
mount /boot
apt-get remove linux-server
apt-get install linux-generic
then boot from the disk and press ESC when GRUB boots, select generic.
TODO
install OSE version.