How to move owncloud from www.mysite.com to www.mysite.com/owncloud

March 9, 2016 1.6k views
Apache One-Click Install Apps Ubuntu


I fired up an ubuntu 14.04 owncloud droplet and, after playing around for a while, I'd like to move owncloud from being the default landing of my site. eg: I'd like:


My apache knowledge is weak and while this seems very simple I've so far been unable to achieve much beyond breaking things.

I've also tried a couple of how-to's and walkthroughs I found in other forums but none seemed to help with the default DigitalOcean owncloud droplet setup.

I was hoping that someone had already done this. I'd be more than happy to post contents of files if needed.

Thanks for any help anyone can provide.

2 Answers

Usually all you have to do is create a new folder/directory named "OwnCloud" and go to your domain.com/owncloud and that should work


On Debian, Ubuntu, and their derivatives, Apache installs with a useful configuration so all you have to do is create a /etc/apache2/sites-available/owncloud.conf file with these lines in it, replacing the Directory and other filepaths with your own filepaths:

Alias / "/var/www/owncloud/"

<Directory /var/www/owncloud/>
  Options +FollowSymlinks
  AllowOverride All

 <IfModule mod_dav.c>
  Dav off

 SetEnv HOME /var/www/owncloud
 SetEnv HTTP_HOME /var/www/owncloud


Then create a symlink to /etc/apache2/sites-enabled:

ln -s /etc/apache2/sites-available/owncloud.conf /etc/apache2/sites-enabled/owncloud.conf

Then restart apache

service apache2 restart

Then ownCloud is accessible via the domain yourdomain.com

Have another answer? Share your knowledge.