Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
1 of 6
http://projects.nicholaslessley.com/2012/10/owncloud-on-raspberry-pi.html
ABOUT ME
ownCloud on a Raspberry Pi
This is a project that I have wanted to do for quite a while now. I finally got a free day this previous
weekend, so I thought I would dedicate a little time to playing with the Raspberry Pi. The Raspberry Pi,
for those not in the know, is a $35 ARM powered computer that is about the size of an Altoids Tin. I
only had a day for my project and decided that setting up ownCloud would be interesting. ownCloud is
an alternative to many different cloud services, such as file storage (Dropbox, Google Drive, SkyDrive,
etc.), calendars (Google Calendar, etc.), music player (Google Music), personal picture viewer (Picasa,
flickr,etc), and others. It has quite a few interesting features and is very actively developed.
SETTING UP THE RASPBERRY PI
The Raspberry Pi is surprisingly easy to set up with Raspbian, and I was off and running in no time. I
would go through the details, but I followed the Raspberry Pi Wiki article on SD card setup. I was able
to use SSH to login after the first boot, so I did not even have to plug it into my TV. I did not do
anything special with the configuration of my Pi, but I plan on activating the turbo setting in the
firmware, so I can get the processor speed up to 1Ghz.
CATEGORIES
Random
Dragon*Con
University
Projects
Steampunk
Engineering
rPi
Helicopter
BLOG ARCHIVE
Apr 2013 (1)
Oct 2012 (3)
Sep 2012 (2)
In order to run ownCloud, you need a webserver and PHP. Apache can be a bit big for the Pi which only
has 256MB of RAM (they now come with 512MB), so I chose to install nginx and PHP-FPM.
# enforce https
# owncloud (ssl/tls)
server {
#listen 443 ssl;
listen 80;
#ssl_certificate /etc/nginx/certs/server.crt;
#ssl_certificate_key /etc/nginx/certs/server.key;
#server_name localhost;
root /usr/share/nginx/www/owncloud;
index index.php;
client_max_body_size 1000M; # set maximum upload size
# deny direct access
location ~ ^/(data|config|\.ht|db_structure\.xml|README) {
deny all;
}
# default try order
location / {
try_files $uri $uri/ @webdav;
}
# owncloud WebDAV
3/31/2014 1:05 AM
2 of 6
http://projects.nicholaslessley.com/2012/10/owncloud-on-raspberry-pi.html
I actually got the majority of this file from ownCloud.org. Then create a soft link to /etc/nginx
/sites-enabled:
ln -s /etc/nginx/sites-available/owncloud.vhost /etc/nginx/sites-enabled/
Note: I removed the default server in sites-enabled.
I then modified /etc/php5/fpm/php.ini to include the following:
1
2
3
4
5
6
extension=sqlite.so
extension=zip.so
extension=json.so
extension=xmlrpc.so
extension=curl.so
extension=gd.so
INSTALLING OWNCLOUD
I downloaded the gzipped tar of ownCloud 4.5 from ownCloud.org, then decompressed it and copied it
to /usr/share/nginx/www/owncloud.
Then,
sudo chown -R www-data:www-data /usr/share/nginx/www/owncloud
You should now be able to start nginx and php-fpm, then using your web browser to go to the IP
address of your Pi, and BOOM! ownCloud!
at 1:46 PM
Categories: Random, rPi
23 comments:
ill13 November 3, 2012 at 7:31 PM
Thanks! I've been messing around with 6 different ways of installing ownCloud with Apache and now,
nginx [Apache being too heavy for the RPi]. Your nginx/php install has been the most straight forward
and easy.
Reply
3/31/2014 1:05 AM
3 of 6
http://projects.nicholaslessley.com/2012/10/owncloud-on-raspberry-pi.html
I have updated the link command to be more specific. You have to link the individual sites
from one directory to the other. Also, I don't have default in my sites-enabled.
Reply
3/31/2014 1:05 AM
4 of 6
http://projects.nicholaslessley.com/2012/10/owncloud-on-raspberry-pi.html
3/31/2014 1:05 AM
5 of 6
http://projects.nicholaslessley.com/2012/10/owncloud-on-raspberry-pi.html
Reply
3/31/2014 1:05 AM
6 of 6
http://projects.nicholaslessley.com/2012/10/owncloud-on-raspberry-pi.html
Comment as:
Publish
Newer Post
Home
Older Post
3/31/2014 1:05 AM