Selfoss : An elegant RSS reader

From Deimos.fr / Bloc Notes Informatique
Jump to: navigation, search
Selfoss

Software version 2.7
Operating System Debian 7
Website Selfoss Website
Last Update 14/06/2013
Others Nginx

1 Introduction

Selfoss[1] is a self-hosted RSS reader solution. It could be compared to Tiny Tinys RSS or Feedly.

2 Installation

First, you need to download the zip file and uncompress it to the good directory :

Command wget
mkdir /usr/share/nginx/www/selfoss
cd /usr/share/nginx/www/selfoss
wget http://selfoss.aditu.de/selfoss-2.7.zip
unzip selfoss-2.7.zip
chown -Rf www-data. .
rm -f selfoss-2.7.zip

3 Configuration

3.1 Database server

We're going to setup the MariaDB part :

Command mysql
CREATE DATABASE selfoss;
CREATE USER 'selfoss_user'@'localhost' IDENTIFIED BY 'selfoss_password';
GRANT ALL ON selfoss.* TO 'selfoss_user'@'localhost' IDENTIFIED BY 'selfoss_password';
FLUSH privileges;

Replace login and password with your needs.

3.2 Web server

We need to configure the web server :

Configuration File /etc/nginx/sites-available/feed.deimos.fr
server {
    include listen_port.conf;
 
    server_name feed.deimos.fr;
    root /usr/share/nginx/www/selfoss;
    index index.php;
 
    access_log /var/log/nginx/feed.deimos.fr_access.log;
    error_log /var/log/nginx/feed.deimos.fr_error.log;
 
    location ~* \ (gif|jpg|png) {
        expires 30d;
    }
 
    location ~ ^/favicons/.*$ {
        try_files $uri /data/$uri;
    }
 
    location ~* ^/(data\/logs|data\/sqlite|config\.ini|\.ht) {
        deny all;
    }
 
    location / {
        try_files $uri /public/$uri /index.php$is_args$args;
    }
 
    location ~ \.php$ {
        client_body_timeout 360;
        send_timeout 360;
        include fastcgi_params;
        fastcgi_pass unix:/var/run/php5-fpm.sock;
        fastcgi_intercept_errors on;
    }
 
    # Drop config
    include drop.conf;
}

Then create the symlink :

Command
ln -s /etc/nginx/sites-available/feed.deimos.fr /etc/nginx/sites-enabled/

Then add it to the www-data crontab :

Command curl
curl -L -s -k "https://rss2.deimos.fr/update"

Copy and past the default configuration :

Command
cp defaults.ini config.ini

Then modify the fields corresponding to your new database setup and remove unneeded lines, like in this example :

Configuration File
; see http://selfoss.aditu.de for more information about
; the configuration parameters
[globals]
db_type=mysql
db_host=localhost
db_database=selfoss
db_username=selfoss_user
db_password=selfoss_password
db_port=3306
logger_level=ERROR
items_perpage=50
items_lifetime=30
base_url=http://field.deimos.fr
username=deimos
password=xxxxxxxxxxxxxxxx
;salt=lkjl1289
salt=Tarn0twif
rss_title=selfoss feed
rss_max_items=10000

You can generate a password in adding "/password" at the end of the url (ex. http://feed.deimos.fr/password)

Then connect to the interface to finish the setup :-)

4 References

  1. ^ http://selfoss.aditu.de/