Archive:Website documentation

Revision as of 02:28, 3 March 2011 by Gameguy43 (talk | contribs)
Jump to: navigation, search

Mailing lists

We use Mailman to manage our lists.

I just want to subscribe to mailing list X

(For illustrated instructions, see the page about our Fc-discuss listserv!)

  • Go here
  • Find mailing list X
  • Click on it
  • Enter your email address and name in the "Subscribing to X" section
  • Press "Subscribe"
  • That's it.

I want to do something that's more like list management

General Credentials

The password is usually listed in /home/freecult/passwords/mailman You can access that file by connecting through SSH or SFTP. If that doesn't work or you don't know how to access that, contact User:Gameguy43 to get the right password.

I want to make a new mailing list

Do that here The last field, called "List creator's (authentication) password" is where you enter the password described above

I want to do something else, AKA Generally Useful Links

I want to subscribe someone easily, from the command line

create a script that looks something like this:

ssh "cd /usr/lib/mailman/bin ; echo $1 | sudo python /usr/lib/mailman/bin/add_members -r - -w y -a y discuss"

Email Forwarding

  • $ adduser username (if the user doesn't already exist)
  • edit ~username/.procmailrc to read something like this:

The "c" stands for copy. That's key - they stay in the IMAP box.

We have a secret gmail account, at gmail dot com, that receives copies of the email sent to freedom, newgroup, and media. This was built to solve [1]. The password for this secret account can be found in ~freecult/passwords, like most other passwords.

Because each of those email addresses is a separate account, they have a .procmailrc in their $HOME that reads:


Chapter hosting

Chapter Blogs

Chapter blogs are hosted on our WordpressMU install (which is now just called Wordpress). These files live here:


So that means that the themes live here:


Where is the admin interface?


Making a new blog

To create a new blog, you need a "site admin" account.

For that to happen, someone who has one needs to add your username to: In the field "Site Admins" at the very bottom of the page.

How do I know I'm a site admin?

When you log in here, you'll see a widget in your sidebar called "Site Admin."

So how do I do it already?

  • Fill in the form here. Put the chapter leader's contact info (or whoever it is that you're interfacing with to make their website) in the "Admin Email" field.
But the site won't be visible until you do this:
  • Edit /etc/apache2/conf.d/400-wpmu.conf. Probably you'll want to enter a command like this:
sudo nano /etc/apache2/conf.d/400-wpmu.conf

Add a line like this:


Where chaptername is the blog subdomain, as you entered it when you created the blog

  • run this:
sudo /etc/init.d/apache2 reload


We should document this.

There are a bunch of Deprecated chapter hosting notes, including stuff about chapter wikis

The Chapter Database

It lives in a google spreadsheet. A python script runs nightly (or so) and slurps out the data and drops it in to to run this script on demand, do this:

python /home/freecult/software/fco-svn/googledoc-chapterdb-scripts/trunk/

The Chapter News Feed (and the personal Planet)

The planet program lives in ~/planet-prog/. It outputs to ~/public_html/planet/ via an every-30m cron job.


There are two planets. They share the same Python code; they just have different config.ini directories:

  • ~/planet/personal-planet/config.ini
  • ~/planet/chapters-planet/config.ini

Add people's RSS feeds to those config files according to the comments you'll find inside. For the people Planet, add people's mini-photos in ~/domains/ and adjust the config.ini as appropriate. For the chapters Planet, I have no idea.

You might consider backing up all of the files to the .backup directory before making changes.

Upgrading "planet"

You could try upgrading it using "bzr". I wouldn't try it without backing up ~/planet-prog/. I expect it to clobber ~/planet-prog/examples/fancy/config.ini.


LiveJournal, for example, has broken RSS feeds that sometimes give the wrong Last-Modified-Date. So you might need to ask Planet to redownload the whole feed.

According to ~/planet-prog/examples/fancy/config.ini , Planet stores its cache in ~/planet-prog/cache/ . So to delete the whole cache:

rm ~/planet-prog/cache/*

In that directory, you can choose to remove just a single cached feed. The names make it clear which one is which.

The Front Page

How does the actual homepage get produced? What does everyone see when they visit ?

Since we have moved the site into Wordpress, most of our code can be found in the Wordpress theme "fco-wordpress-theme" in "~/domains/". The skeleton for the front page is found in "front_page.php", which gets the content from functions found in "fco-wordpress-theme/front_page/". For instance, the "blurb" at the top of the front page (currently "Students for Free Culture is an international chapter-based student organization that promotes the public interest in intellectual property and information & communications technology policy.") can be found in "fco-wordpress-theme/front_page/front_page_code.php".

The content for the "Current Campaign" box does not come from the theme, it is what you see if you try to open the front page in the Wordpress page editor... it is intended to be easily edited and updated through the GUI just like any other blog page.


We use cron to run tasks every once in a while. To see the current list of jobs that run, do:

crontab -l

To edit them:

crontab -e

To see what the file format is, read this reference.




  • You can not use PHPMyAdmin to view our databases.


Checking out


  • Just do "svn commit"!
    • But you must be a registered user first, see below!

Adding users

  • Log in to the server, and do:
htpasswd /home/freecult/subversion-repository/conf/htpasswd YOUR_USERNAME
    • Your password will not be encrypted when sent across the Internet, so keep that in mind when picking the password.



Asheesh set up 'dirvish' and configured his work desktop to pull the backups from the fco vserver.


Every night, a cron job runs that saves all the databases to separate files in /home/freecult/backups/databases/. These are then copied as regular files during the nightly dirvish backup job.

To get a database in on this super fun backup party (everyone's doing it), add it to /home/freecult/passwords/mysql_passwords


We have monitoring by Parker gets the emails. This should probably change.


Data privacy on this wiki

We ask users to store personal information in this wiki. Here are all the ways we restrict access to it:

  • TODO: Non-includable namespaces: NS_USER should be blocked from being transcluded.
  • DONE: Semantic MediaWiki currently does not store properties whose names begin with secret_.
    • FIXME: It should store the data and just not show it unless you're an admin.
  • TODO: Choose some MW extension to prevent people from reading source of NS_USER pages.
    • In practice, the "read" right allows viewing the source. Therefore, we will have to:
      1. Prevent non-owners of an NS_USER page from changing that user's page, and
      2. Around line 1077, change the $source to a message indicating data has been hidden from view for privacy reasons, and
      3. Prevent the DifferenceEngine from showing these pages.
        • Main call is Article.php:661, but just grep for new.*DifferenceEngine

Review of UserCan extensions

Which MW extension can easily prevent people from writing each others' NS_USER pages?

Hmm. From #mediawiki moments ago:

<paulproteus> I want pages that people can read but can't view the source of, to be clear.
<Simetrical> paulproteus, it controls all view permissions, including view source.
<paulproteus> I see.
<Simetrical> You can't have that.

Upgrading Semantic MediaWiki

If you feel motivated to upgrade Semantic MediaWiki or Semantic Forms, you should be sure to update the SMW data set. Here's how:

$ cd domains/
$ php SMW_refreshData.php -pv
$ php SMW_refreshData.php -v


DEPRECATED: Every domain we own or run is listed at Domains.

Calendar publishing

DEPRECATED--as far as I know, we don't do this anymore --Parker, oct 16th 2010.

We use phpicalendar. If everyone working on the national level shares their calendars with each other, it becomes much easier to schedule meetings at mutually convenient times (instead of playing calendar battleship... "are you free at 3pm?" "No." "How about 4pm?" "You sunk my battleship! You bastard!").

As a user

  1. Set your calendar client to synchronize to
    • You will need to use a username/password pair special to the calendar stuff assigned to you by the web team
    • Be SURE you use a file with your name in it. Otherwise you run the risk of others overwriting your data, and vice-versa!
  2. Check on that your calendar appears

As a sysadmin

  • Apache2 runs the WebDAV service; its configuration is in /etc/apache2/
  • htpasswd file in ~freecult/passwords/calendar-htpasswd
  • calendar files stored in ~freecult/public_html/database/calendars/
  • to change someone's password, or create a user, do:
htpasswd  /home/freecult/passwords/calendar-htpasswd USERNAME

thesis writing service


We keep them all in ~freecult/passwords/