Personal tools
You are here: Home GNU / Linux Debian 4.0 Etch Install Tiny Tiny RSS on Debian 4.0 Etch
Document Actions
  • Send this page to somebody
  • Print this page
  • Add Bookmarklet

Install Tiny Tiny RSS on Debian 4.0 Etch

by Pierre-Yves Landuré last modified 2012-12-19 22:04

Tiny Tiny RSS is a online feed reader written in PHP and using heavily AJAX technologies. It is a good solution to read your RSS feeds on any computer connected to the Internet without any local configuration. I've discovered this tool because one of my visitors use this software.

This page is outdated. Please use the newest version of this guide on Biapy Help Desk:

 Install Tiny Tiny RSS feed reader on Debian

Install

First, you need a HTTP serveur with PHP enabled. You can for example use Lighttpd as described in my howto Install Lighttpd and PHP 5 on Debian 4.0 Etch.

We then install PHP modules needed by Tiny Tiny RSS :

/usr/bin/apt-get install php5-mysql php5-xmlrpc mysql-client-5.0

You need to download the last Tiny Tiny RSS version. In order to do this, enter the version you want to download :

VERSION=1.2.19

And launch the download :

/usr/bin/wget http://tt-rss.org/download/tt-rss-$VERSION.tar.gz \
    --output-document=/tmp/tt-rss-$VERSION.tar.gz

Once the download ended, untar the file to the target directory :

/bin/tar --directory=/opt -xzf /tmp/tt-rss-$VERSION.tar.gz

And rename the created folder :

/bin/mv /opt/tt-rss-$VERSION /opt/tt-rss

Create a symbolic link to /var/www:

 

/bin/ln -s /opt/tt-rss /var/www/

 

Once this done, you can remove the downloaded archive :

/bin/rm /tmp/tt-rss-$VERSION.tar.gz

Set up

We will now set up our Tiny Tiny RSS. First, we create the configuration file :

/bin/cp /opt/tt-rss/config.php-dist /opt/tt-rss/config.php

Once this done, we create the database that will be used by Tiny Tiny RSS. In order to do this, i recommend you to follow my howto MySQL for Debian 4.0 Etch.

Warning : If you have followed my guide, you can ignore these command lines. Otherwise, remplace bold text by the connection parameters to your MySQL database :

MYSQL_DB=TTRSS_DATABASE
MYSQL_USERNAME=ttrss_username
MYSQL_USERPWD=ttrss_password

Once the database created, you need to create the tables. This is done by the following command line :

/usr/bin/mysql --user=$MYSQL_USERNAME --password=$MYSQL_USERPWD $MYSQL_DB \
    < /opt/tt-rss/schema/ttrss_schema_mysql.sql

You now need to edit the Tiny Tiny RSS configuration. This is done by running :

/bin/sed -i \
    -e "s/\(define('DB_TYPE', \).*/\1'mysql');/" \
    -e "s/\(define('DB_NAME', \).*/\1'$MYSQL_DB');/" \
    -e "s/\(define('DB_USER', \).*/\1'$MYSQL_USERNAME');/" \
    -e "s/\(define('DB_PASS', \).*/\1'$MYSQL_USERPWD');/" \
    /opt/tt-rss/config.php

Your Tiny Tiny RSS install should now be available at the URL :

Your are free to edit this default configuration.

Updating feeds

You probably want your feeds to be updated even if you don't login often to Tiny Tiny RSS. In order to do this, install the PHP command line interface :

/usr/bin/apt-get install php5-cli

Edit the configuration in order to enable updating feeds by a daemon :

/bin/sed -i \
    -e "s/\(define('ENABLE_UPDATE_DAEMON', \).*/\1true);/" \
    /opt/tt-rss/config.php

Change the lock files location :

/bin/sed -i \
    -e "s/\(define('LOCK_DIRECTORY', \).*/\1'\/var\/run\/tt-rss');/" \
    /opt/tt-rss/config.php

And create the folder that will be used to store these lock files :

/bin/mkdir /var/run/tt-rss

Download the Tiny Tiny RSS init.d script configuration file :

/usr/bin/wget http://howto.landure.fr/gnu-linux/debian-4-0-etch/installer-tiny-tiny-rss-sur-debian-4-0-etch/tt-rss-default \
    --output-document=/etc/default/tt-rss

Download the Tiny Tiny RSS init.d script :

/usr/bin/wget http://howto.landure.fr/gnu-linux/debian-4-0-etch/installer-tiny-tiny-rss-sur-debian-4-0-etch/tt-rss-initd \
    --output-document=/etc/init.d/tt-rss

Set it as runnable :

/bin/chmod +x /etc/init.d/tt-rss

You can now run the update script with the command :

/etc/init.d/tt-rss start

And stop it with :

/etc/init.d/tt-rss stop

If you want the update script to be run at your computer startup, use this command line :

/usr/sbin/update-rc.d tt-rss defaults

Before version 1.2.20, the update daemon is not very stable. It is recommanded to use a cron script to restart it regularly :

/bin/echo '#!/bin/sh
# Start tt-rss udpate daemon if necessary :

if [ -x /etc/init.d/tt-rss ]; then
        /etc/init.d/tt-rss start
fi'  | /usr/bin/tee /etc/cron.hourly/tt-rss
/bin/chmod +x /etc/cron.hourly/tt-rss

The daemon is only launched if it is not started, due to lock files presence. This cron script is not a problem.

Use SimplePie instead of Magpie to parse RSS feeds

SimplePie is a RSS feed parser more powerfull than Magpie. But it needs curl to read HTTPS feeds or feeds protected by password.

First, install the curl PHP extension :

/usr/bin/apt-get install php5-curl

And configure Tiny Tiny RSS to use SimplePie :

/bin/sed -i \
    -e "s/\(define('ENABLE_SIMPLEPIE', \).*/\1true);/" \
    /opt/tt-rss/config.php

Note : Do not forget to restart you HTTP server.

If SimplePie does not fit your needs, you can use this command line to switch back to Magpie :

/bin/sed -i \
    -e "s/\(define('ENABLE_SIMPLEPIE', \).*/\1false);/" \
    /opt/tt-rss/config.php

Enabling the login mecanism

In order to have a login protected the feeds you are subscribed to, you need to enable the multi-user mode :

/bin/sed -i \
    -e "s/\(define('SINGLE_USER_MODE', \).*/\1false);/" \
    /opt/tt-rss/config.php

You can then use this login to connect to Tiny Tiny RSS :

  • Login : admin
  • Password : password

Enable experimental translations support

If you want to use Tiny Tiny RSS in french (for example), you need to enable this. But it is still in development and can create problems. I'm currently using it and i have encountered no problems. To enable the translations support, run this command line :

/bin/sed -i \
    -e "s/\(define('ENABLE_TRANSLATIONS', \).*/\1true);/" \
    /opt/tt-rss/config.php

 

Change the location of icons cache

By default, feed icons are cached in the icons folder. If you want to change this behaviour (for example, if Tiny Tiny RSS is installed on a read only partition), follow these steps:

First, create the folder where to cache icons:

/bin/mkdir --parent /var/lib/tt-rss/icons

Change its permissions:

/bin/chown -R www-data:www-data /var/lib/tt-rss/icons

Delete the current Tiny Tiny RSS icons folder:

/bin/rm -r /opt/tt-rss/icons

And replace it by a symbolic link to your new icons folder:

/bin/ln -s /var/lib/tt-rss/icons /opt/tt-rss/icons

If you want, you can also change the Tiny Tiny RSS configuration:

/bin/sed -i \
    -e "s/\(define('ICONS_DIR', \).*/\1'\/var\/lib\/tt-rss\/icons');/" \
    /opt/tt-rss/config.php

 

Tiny Tiny RSS upgrade

If a new version of Tiny Tiny RSS is available, and that you are willing to upgrade your install, here are the steps to do this. First, install the needed software :

/usr/bin/apt-get install patch

Change to your Tiny Tiny RSS install patch :

cd /opt/tt-rss

Create a diff file to backup your configuration :

/usr/bin/diff -Nru config.php-dist config.php > /tmp/tt-rss-config-diff.patch

Enter the new version of Tiny Tiny RSS :

VERSION=1.2.19

Download the new version :

/usr/bin/wget http://tt-rss.org/download/tt-rss-$VERSION.tar.gz \
    --output-document=/tmp/tt-rss-$VERSION.tar.gz

Once the download ended, untar the file to the target folder :

/bin/tar --directory=/opt -xzf /tmp/tt-rss-$VERSION.tar.gz

Create the configuration file :

/bin/cp /opt/tt-rss-$VERSION/config.php-dist /opt/tt-rss-$VERSION/config.php

And patch it in order to have your configuration :

patch --directory=/opt/tt-rss-$VERSION --strip=0 < /tmp/tt-rss-config-diff.patch

Now, backup your old Tiny Tiny RSS installation :

/bin/mv /opt/tt-rss /opt/tt-rss.old

And use the new version :

/bin/mv /opt/tt-rss-$VERSION /opt/tt-rss

 

Now, we get the icons cache from the previous version:

/bin/rm -r /opt/tt-rss/icons
/bin/cp -a /opt/tt-rss.old/icons /opt/tt-rss/

Login as admin to update the database if necessary. Check that everything work fine.

Once this done, restart the feed update daemon:

/etc/init.d/tt-rss restart
You can now remove the downloaded file and the backup of your old installation :

 

/bin/rm /tmp/tt-rss-$VERSION.tar.gz
/bin/rm -r /opt/tt-rss.old

Setup your user account

Here are the options i've changed for my user account :

  • Purge old posts after this number of days (0 - disables) : 0 (i disable old news articles deletion)
  • Enable feed categories : Yes (I enable the categories to sort my feeds)
  • Enable search toolbar : Yes (I enable the search inside feeds contents)
  • Confirm marking feed as read : No (I disable the alert box when i want to mark all a feed as read)
  • Strip unsafe tags from articles : No (I disable the HTML source code simplification. It is less secure, but allow to keep <code> tags)

Firefox integration

Tiny Tiny RSS is perfectly interfaced with Mozilla Firefox. This is done by 2 ways :

  • You can use Tiny Tiny RSS as default feed manager in Mozilla Firefox. This is configured from the feeds settings page in Tiny Tiny RSS.
  • You can install a plugin that check regularly the availability of news : Tiny Tiny RSS Notifier.

Thanks

  • Thanks to Tiny Tiny RSS developers (with a special one to Fox that handle this perfectly :D).
  • Thanks to Mdrolo that subscribed to this site RSS feed with it Tiny Tiny RSS, and made me discover it.
Attachments

And I didnt even know it existed before!

Posted by DanielS at 2008-09-05 08:02
What a perfect answer to a problem I had!
Being I own about 5 laptops I've always had the problem of syncing my information. Most of it is streamlined now, and sync's across the board, everything except for my rss feeds.
I had been using the sage firefox add-on and foxmarks sync to keep my feeds (kinda) all in one place, but now, I just host them all from my server (yes running off of one of the older laptops) and sign in!

Really I didn't even know that this program existed! I'm so glad I found your site, you've been a GREAT help in getting all this working together so nicely.

broken link

Posted by lenod at 2012-12-19 15:51
Link to "Tiny Tiny RSS Notifier." is broken.

Outdated article

Posted by Pierre-Yves Landuré at 2012-12-19 16:09
Hi,

thank you for your report. This extension is not compatible with recent versions of Firefox.

This guide is old and outdated. Please refer to its new version at : https://howto.biapy.com/en/debian-gnu-linux/web-applications/content-syndication/install-tiny-tiny-rss-feed-reader-on-debian

Sincerely yours,
Pierre-Yves Landuré

BlogBang
Navigation
 

Powered by Plone CMS, the Open Source Content Management System

This site conforms to the following standards:

Wikio