Home > Blog > Programming > Mounting Dropbox into ownCloud

Mounting Dropbox into ownCloud

June 13th, 2012

I just finished adding support for mounting Dropbox and Google Drive in the external storage user interface. These took a while longer than the other storage backends because both require OAuth authentication. It is a fairly simple process to configure both in the user interface, but Dropbox has one extra step. Dropbox requires that developers create an ‘app’ that is registered with Dropbox in order to access their API. Unfortunately, ownCloud can’t take care of this part because the app must be approved by Dropbox and the app key distributed with the source. This would allow someone to potentially violate Dropbox’s policies acting as ownCloud. No worries though, mounting your free 2 GB of storage at Dropbox is still possible. It requires that you create an app with Dropbox and then provide the app key and secret to the external storage configuration user interface. Go to My apps at Dropbox and create an app. Select ‘Full Dropbox’ for access level.

Now grab the app key and secret and paste these into the corresponding fields for the Dropbox storage (please don’t attempt to apply for production status). Click the ‘Grant access’ button and you will be redirected to the Dropbox website to give ownCloud permission to access your account.

Your username and password at Dropbox is not stored on your ownCloud, instead a token and token secret are stored that represent your account.

Your Dropbox files should now be available through ownCloud! The last step only applies to mounting Google Drive, no app key or secret is necessary. Have fun with your free 7 GB of storage space!

Categories: Programming Tags:
  1. pushpop
    June 13th, 2012 at 14:07 | #1

    Just want to say thank you for your hard work on this. This feature alone drew me to OwnCloud. – pushpop

  2. avlas
    June 14th, 2012 at 11:50 | #2

    It sounds great! is there any way to get this done in ownCloud 4.0.2?

  3. June 14th, 2012 at 12:44 | #3

    @avlas You can either start using the master branch at gitorious or download the files inside the folder apps/files_external. You’ll also need 3rdparty/Dropbox and 3rdparty/Google. There’s a few issues with the file cache with the external storage, so I recommend you use a WebDAV client to access the files for the time being.

  4. Papak
    June 21st, 2012 at 08:54 | #4

    I just try to mount Dropbox and Google Drive but nothing happen. After allow access the page reload, is back to owncloud and under External Storage is nothing. All disapeared. I created order for mountpoint and entered app key and app secret for Dropbox. In website’s apache error_log is nothing. Have PHP any additional requirements?
    Any help would be appreciated.

  5. June 21st, 2012 at 10:05 | #5

    @Papak Can you check your browser’s javascript console. Most of these external storage backends require cURL.

  6. Reinhard
    June 21st, 2012 at 11:51 | #6

    Thanks for all the cool work! Gdrive mounting works fine for me, Dropbox, however, not. Do you have any idea how I could find out why?

  7. Papak
    June 21st, 2012 at 12:48 | #7

    Probably I’m not clear. Trying to add Dropbox or Google Drive as user after allow acces By Dropbox/Google is nothing added in mount.conf and I can’t see Dropbox or Google Drive as External Storage. For any reason is nothing configured under ownCloud. It’s not problem to connect but to configure.

  8. June 21st, 2012 at 17:26 | #8

    @Reinhard & @Papak It’s a little difficult to debug in the comments. Stop by IRC and ping me (MTGap). I’ll try to help get everything working.

  9. Markus
    June 26th, 2012 at 09:23 | #9

    Hi Michael,

    i also try to get Dropbox working on my owncloud but i always will get this error in apache error log:

    [Tue Jun 26 15:15:28 2012] [error] [client x.x.x.x] PHP Notice: Undefined index: modified in /var/customers/webs/web1/ocdev/apps/files_external/lib/dropbox.php on line 93, referer: http://ocdev.xxxx.de/?app=files
    [Tue Jun 26 15:15:33 2012] [error] [x.x.x.x] PHP Notice: Undefined index: modified in /var/customers/webs/web1/ocdev/apps/files_external/lib/dropbox.php on line 93, referer: http://ocdev.xxxx.de/?app=files

    Perhaps it will help you!

    Regards

  10. June 28th, 2012 at 12:30 | #10

    @Markus Thanks, I’ve made some fixes in the Dropbox backend that should resolve these issues. Please try using the master branch. I also discovered some bugs in the library I was using for Dropbox that I’ve also corrected.

  11. Matt
    July 6th, 2012 at 06:54 | #11

    I am missing something:

    1) Make App
    2) Get key
    3) “Now grab the app key and secret and paste these into the corresponding fields for the Dropbox storage ”
    3.1) How/Where?
    X) ??? Ok, so I give my app access to my account, how does that magically make it where my owncloud has access to the dropbox info. Where/What do I need to do tell ownCloud to grab that data.
    4)”Your Dropbox files should now be available through ownCloud!”

    This all looks great, but if you could write an actually step by step, that doesn’t assume I actually know what I am doing, that’d be great!

  12. July 6th, 2012 at 20:24 | #12

    @Matt I think you might be confused because you didn’t read this post: Configuring External Storage for ownCloud

Comments are closed.