How I got it running on my RaspberryPi

by derschmidt, Wednesday, March 20, 2013, 01:48 (4047 days ago)

I'm fairly new to servers as this was my first project and I just want to share my way of getting selfoss to run on my RaspberryPi to make it easier for everyone else.

On my journey to get it up and running I encountered some problems that made my head spin as I couldn't explain some strange behavior. At the end and after extensive research about apache config and the .htaccess file everything was fairly simple to fix. Thanks to this forum.

Now if you are equally new to the topic and just want to set it up on your pi, just follow this simple steps:

I assume you have Raspbian “wheezy” running on your pi and you did not change your username.
1. Create a folder selfoss in your homefolder (mkdir selfoss) and download the file
http://selfoss.aditu.de/selfoss-2.3.zip into it (wget does it if on console).
2. Unzip the file via "unzip selfoss-2.3.zip"
3. Make sure your .htaccess file has "RewriteEngine On" and "RewriteBase /selfoss"
(double check there's no "#" at the beginning of the line)
4. Change permissions via
"chmod a+w data/cache data/favicons data/logs data/thumbnails data/sqlite public/"
5. Now install apache2 with php:
sudo apt-get update && sudo apt-get upgrade (this is not necessary, but seems good anyway)
sudo apt-get install apache2 php5 sqlite libapache2-mod-php5 php5-sqlite php5-gd
6. Configure apache2:
6.1 Enable rewrite and headers:
sudo a2enmod rewrite
sudo a2enmod headers
sudo a2enmod php5
sudo service apache2 restart
6.2 Change rewrite-settings in "/etc/apache2/sites-available/default" by setting
"AllowOverride All" (I did it everywhere because it fixed my problem)
7. Change directory to "/var/www" and create a link to your installation of selfoss via
"sudo ln -s /home/pi/selfoss"

Now everything should be working just fine if you visit http://<your-ip>/selfoss.
If however you encounter a message about write only database while updating, manually add write permissions to your database with "chmod a+w /home/pi/selfoss/data/sqlite/selfoss.db"

This is the end. I hope this is useful to someone. If you find anything that I shouldn't have done this way, I would be glad to receive your feedback.

How I got it running on my RaspberryPi

by robkurzd, Thursday, March 28, 2013, 02:17 (4039 days ago) @ derschmidt

Thanks!

I got mine running so that when I access http://myurl/selfoss, I see a page that says
"mark as read
newest 0
unread 0
starred 0
Tags

all tags
"

I believe this is working however I cannot access http://myurl/opml to import feeds. I can follow your instructions pretty well and can maneuver around the file system but not sure how I can do this.

Also, my site looks like a plain HTML site. Once feeds come in, does it change? It doesn't look like the screenshots on the site.

Thanks!

How I got it running on my RaspberryPi

by derschmidt, Thursday, March 28, 2013, 08:09 (4039 days ago) @ robkurzd

I had the same problem at first. I figured out, that the page is not loaded correctly, because the rewrite of the urls does not work. Check the apache logs to see if your browser tries to load stuf, that apache can't find. Be sure rewrite is allowed by your apache config ( "/etc/apache2/sites-available/default") by setting "AllowOverride All". There are multiple points in this file, where this can be changed. As I did not know exactly what all this means, I just changed AllowOverride everytime it occures.

Now that this config allows overrides, your .htaccess must specify the correct override rule.
This should be done by just changing the line after RewriteEngine On at the top to "RewriteBase /selfoss". Check again, that this line is not commented out by a #.

Good luck.

How I got it running on my RaspberryPi

by daysofgreen, Wednesday, April 17, 2013, 04:14 (4019 days ago) @ robkurzd

I believe this is working however I cannot access http://myurl/opml to import feeds. I can follow your instructions pretty well and can maneuver around the file system but not sure how I can do this.

Thanks!

I was having the same problem. I eventually figure out that the link was http://myurl/selfoss/opml. The other quirk I was encountered was, http://myurl/selfoss/update wouldn't work but http://myurl/selfoss/Update with the uppercase 'u' would.

How I got it running on my RaspberryPi

by daysofgreen, Wednesday, April 17, 2013, 04:09 (4019 days ago) @ derschmidt

Extremely helpful guide. Huge amounts of appreciation to you sir. After searching for a week, these are literally the only working instructions I could find for getting selfoss up and running on a raspberry pi.

RSS Feed of thread
powered by my little forum