Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This is probably my longest standing action item in TERENA (wink): implement  implement a federated version of Confluence.

Below is the recipe for getting this to work . Ingredients:with Ubuntu 12.04

...

Confluence 5.1

...

Apache

...

, and modmellon.

I choose modmellon because it seemed like a cleaner solution than mod_shib, requiring no additional daemons and much simpler configuration.

 

Apache web server

Prerequisites

Before you start, make sure you have these bits:

  • A SAML Identity Provider (IdP).
  • An account on that IdP.
  • An attribute that can be used as username in Confluence (for example eduPersonPrincipalName). Attributes for full name and e-mail are optional but recommended.
  • The user name of the to-be administrator account. So, if you choose eduPersonPrincipalName as the attribute for username, you need to know your own value (for instance 'dvisser@surfnet.nl'.

Modmellon

Modmellon is an apache module. To get this working I recompiled the For modmellon to work, I recompiled Debian source packages from the University of Tilburg for Ubuntu 12.04 and made them available in our own APT repository.

...

Code Block
apt-get install apache2-mpm-worker libapache2-mod-auth-mellon 

 

Create a directory /etc/apache/mellon, and store the Identity Provider metadata in XML format to a file called idp.xml.

Code Block
openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 -keyout core.key -out core.crt


Create a 

  • sp.crt - X509 certificate
  • sp.key 

 

 

PostgreSQL

Code Block
apt-get install postgresql

Create a dedicated database user, and a database:

Code Block
sudo su - postgres
createuser -S -d -r -P -E confuser
createdb -O confuser confluence

 

 

Confluence 

Install OpenJDK:

Code Block
apt-get --no-install-recommends install openjdk-7-jdk

 

Download the source http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-5.1.tar.gz and unpack it to /opt/confluence.

Edit /opt/confluence/conflue

Once installed, use this upstart script to have start on boot:

 

Code Block
themeMidnight
languagebash
# Upstart script for confluence
description     "Atlassian Confluence"
start on runlevel [2345]
stop on runlevel [!2345]
kill timeout 30
env RUN_AS_USER=root
env BASEDIR=/opt/confluence
script
    LOGFILE=$BASEDIR/logs/catalina.out
    exec su - $RUN_AS_USER -c "$BASEDIR/bin/catalina.sh run" >> $LOGFILE 2>&1
end script

Once this is there, you can simply issue "start confluence", "stop confluence", "restart confluence".