Diaspora on FreeBSD
PLEASE NOTE: This content contains outdated and possibly irrelevant information.
This is my collection of notes and specs for installing a Diaspora project pod instance on FreeBSD 8.2, which is the setup I was using at the create-o-plex pod before I stopped operating it.

I refer to these notes along with the Diaspora* installation instructions to get set up and running.
Install prerequisite ports
You should update and install these ports before you clone the Diaspora GitHub repository:
- git
- ImageMagick
- libxml2
- mysql51-server
- www/nginx
- redis
- ruby19
- sqlite3
Install bundler
You need Ruby bundler for use with Diaspora, so install it.
sudo gem install bundler
Example Configuration
These are examples and snippets based on the configuration files I use in my FreeBSD based setup. Please note that my setup was experimental, and although it ran in production mode, it supported a limited number of users, and ran on a server with modest resources.
These examples are just that. YMMV, etc. ;)
Example /usr/local/etc/redis.conf
daemonize yes
pidfile /var/run/redis/redis.pid
bind 127.0.0.1
port 6379
timeout 300
loglevel verbose
logfile /path_to_log_dir/redis/redis.log
databases 16
save 900 1
save 300 10
save 60 10000
rdbcompression yes
dbfilename dump.rdb
dir /home/db/redis/
appendonly no
appendfsync everysec
vm-enabled no
vm-swap-file /tmp/redis.swap
vm-max-memory 0
vm-page-size 32
vm-pages 134217728
vm-max-threads 4
glueoutputbuf yes
hash-max-zipmap-entries 64
hash-max-zipmap-value 512
Example script_server.yml
script_server:
# Choose database. Currently supported: mysql, postgres
db: "mysql"
# Enable thin as application server
enable_thin: true
# Port on which thin should listen
thin_port: 3000
# We're running our Thin instances on sockets instead of ports
default_thin_args: "--servers 3 --socket /tmp/thin.sock"
# Possibilities are development, production
rails_env: "production"
Example nginx.conf
Relevant snippet from the nginx.conf showing sockets for Thin:
upstream thin_cluster {
server unix:/tmp/thin.0.sock;
server unix:/tmp/thin.1.sock;
server unix:/tmp/thin.2.sock;
}
Notes
Bundle install notes
Include the path to the SQLite3 library so that the gem install finds it during the bundle install:
export CONFIGURE_ARGS="with-sqlite3-include=/usr/local/include"