Blog Theme
tags: blog blue nice template theme wikidot
26 Jun 2008 12:59
I've managed to create a draft of blog theme for wikidot.
I've applied it to my dev blog to test it and show off.
It's based on this template by Open Source Web Design.
Comments: 2
Mirror Server
tags: blog dev lighttpd mirror php wikidot
24 Jun 2008 12:55
Today I've (almost) managed to create a mirror server for wikidot.com service.
Features:
- CentOS distribution
- almost live Wikidot read only mirror
- database is replicated from the original service in real time to this server
- user uploaded files are replicated in real time to this server using FS mirror
- avatars are to be mirrored with rsync every now and then
- uses Portable IP address: 67.228.37.27
- lighttpd serves ALL content with FastCGI PHP
- database is read-only (as being replication slave)
- CVS configured to use SSH keys (no password asking)
- Wikidot PHP source mainly from the current production server
- Improvements (from CVS): uploaded files served like in OpenSource version
Problems:
- FS mirror is not 100% exact, it may not synchronize some (little fraction of) files every now and then, so we must rsync them additionally, to make sure nothing's lost
- if you were logged in to Wikidot before, it'll complain about not being able to write to ozone_session (because it's read only)
- Flickr Gallery not working and causing the whole page to display just nothing
- magic file recognition not working (it may be a problem in PHP configuration or an extension):
PHP Warning: finfo_open(): Failed to load magic database at '/usr/share/misc/magic'. in /var/www/www.wikidot.com/wikidot/php/utils/- on line 3
PHP Warning: finfo_file(): supplied argument is not a valid file_info resource in /var/www/www.wikidot.com/wikidot/php/utils/- on line 4
PHP Warning: finfo_close(): supplied argument is not a valid file_info resource in /var/www/www.wikidot.com/wikidot/php/utils/- on line 5
UPDATE: Flickr problem solution:
- yum install php-pear-HTTP-Request
- chgrp lighttpd /var/lib/php/session
Remember:
- when switching to mirror, we must restart memcached (or force to invalidate every item in it)
Comments: 2
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.