{"id":132,"date":"2021-04-22T15:49:01","date_gmt":"2021-04-22T13:49:01","guid":{"rendered":"https:\/\/cimalink.eu\/blog\/?p=132"},"modified":"2021-04-22T15:49:01","modified_gmt":"2021-04-22T13:49:01","slug":"mount-dropbox-as-network-drive-under-linux","status":"publish","type":"post","link":"https:\/\/cimalink.eu\/blog\/mount-dropbox-as-network-drive-under-linux\/","title":{"rendered":"Mount dropbox as network drive under linux"},"content":{"rendered":"\n<p>First install python3 and python3-pip<\/p>\n\n\n\n<p>Check if python3 is installed:<\/p>\n\n\n\n<p>python3 &#8211;version<\/p>\n\n\n\n<p>If not install python3:<\/p>\n\n\n\n<p>apt install python3-pip<\/p>\n\n\n\n<p>Install python3-pip<\/p>\n\n\n\n<p>apt install python3-pip<\/p>\n\n\n\n<p>Check if pip3 is installed:<\/p>\n\n\n\n<p>pip3 &#8211;version<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Install dbxfs in Linux<\/h2>\n\n\n\n<p>The dbxfs officially supports Linux and Mac OS. However, it should work on any POSIX system that provides a\u00a0<strong>FUSE-compatible library<\/strong>\u00a0or has the ability to mount\u00a0<strong>SMB<\/strong>\u00a0shares. Since it is written for Python 3.5, it can installed using\u00a0<strong>pip3<\/strong>\u00a0package manager.<\/p>\n\n\n\n<p>And, install FUSE library as well.<\/p>\n\n\n\n<p>On Debian-based systems, run the following command to install FUSE:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo apt install libfuse2<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Mount Dropbox folder locally Using Dbxfs In Linux<\/h2>\n\n\n\n<p>Create a mount point to mount your dropbox folder in your local file system.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ mkdir ~\/mydropbox<\/pre>\n\n\n\n<p>Then, mount the dropbox folder locally using dbxfs utility as shown below:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ dbxfs ~\/mydropbox<\/pre>\n\n\n\n<p>You will be asked to generate an access token:<\/p>\n\n\n\n<p>To generate an access token, just navigate to the URL given in the above output from your web browser and click\u00a0<strong>Allow<\/strong>\u00a0to authenticate Dropbox access. You need to log in to your dropbox account to complete authorization process.<\/p>\n\n\n\n<p>A new authorization code will be generated in the next screen. Copy the code and head back to your Terminal and paste it into&nbsp;cli-dbxfs&nbsp;prompt to finish the process.<\/p>\n\n\n\n<p>You will be then asked to save the credentials for future access. Type&nbsp;<strong>Y<\/strong>&nbsp;or&nbsp;<strong>N<\/strong>&nbsp;whether you want to save or decline. And then, you need to enter a passphrase twice for the new access token.<\/p>\n\n\n\n<p>Finally, click\u00a0<strong>Y<\/strong>\u00a0to accept\u00a0<strong>&#8220;\/home\/username\/mydropbox&#8221;<\/strong>\u00a0as the default mount point. If you want to set different path, type\u00a0<strong>N<\/strong>\u00a0and enter the location of your choice.<\/p>\n\n\n\n<p>All done! From now on, you can see your Dropbox folder is locally mounted in your filesystem.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Change Access Token Storage Path<\/h3>\n\n\n\n<p>By default, the dbxfs application will store your Dropbox access token in the system keyring or an encrypted file. However, you might want to store it in a\u00a0<strong>gpg<\/strong>\u00a0encrypted file or something else. If so, get an access token by creating a personal app on the\u00a0<a rel=\"noreferrer noopener\" href=\"https:\/\/dropbox.com\/developers\/apps\" target=\"_blank\">Dropbox developers app console<\/a>.<\/p>\n\n\n\n<p><a href=\"https:\/\/ostechnix.com\/wp-content\/uploads\/2018\/10\/access-token.png\"><\/a><\/p>\n\n\n\n<p id=\"caption-attachment-14860\">Create a new app on the DBX Platform<\/p>\n\n\n\n<p>Once the app is created, click&nbsp;<strong>Generate<\/strong>&nbsp;button in the next button. This access token can be used to access your Dropbox account via the API. Don\u2019t share your access token with anyone.<a href=\"https:\/\/ostechnix.com\/wp-content\/uploads\/2018\/10\/Create-a-new-app.png\"><\/a><\/p>\n\n\n\n<p id=\"caption-attachment-14865\">Generate access token<\/p>\n\n\n\n<p>Once you created an access token, encrypt it using any encryption tools of your choice, such as&nbsp;<a href=\"https:\/\/ostechnix.com\/cryptomator-open-source-client-side-encryption-tool-cloud\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Cryptomater<\/strong><\/a>,&nbsp;<a href=\"https:\/\/ostechnix.com\/how-to-encrypt-your-personal-foldersdirectories-in-linux-mint-ubuntu-distros\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Cryptkeeper<\/strong><\/a>,&nbsp;<a href=\"https:\/\/ostechnix.com\/cryptogo-easy-way-encrypt-password-protect-files\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>CryptGo<\/strong><\/a>,&nbsp;<a href=\"https:\/\/ostechnix.com\/cryptr-simple-cli-utility-encrypt-decrypt-files\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Cryptr<\/strong><\/a>,&nbsp;<a href=\"https:\/\/ostechnix.com\/tomb-file-encryption-tool-protect-secret-files-linux\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Tomb<\/strong><\/a>,&nbsp;<a href=\"https:\/\/ostechnix.com\/toplip-strong-file-encryption-decryption-cli-utility\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Toplip<\/strong><\/a>&nbsp;and&nbsp;<a href=\"https:\/\/ostechnix.com\/an-easy-way-to-encrypt-and-decrypt-files-from-commandline-in-linux\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>GnuPG<\/strong><\/a>&nbsp;etc., and store it in your preferred location.<\/p>\n\n\n\n<p>Next edit the dbxfs configuration file and add the following line in it:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">\"access_token_command\": [\"gpg\", \"--decrypt\", \"\/path\/to\/access\/token\/file.gpg\"]<\/pre>\n\n\n\n<p>You can find the dbxfs configuration file by running the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ dbxfs --print-default-config-file<\/pre>\n\n\n\n<p>For more details, refer dbxfs help section:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ dbxfs -h<\/pre>\n\n\n\n<p>As you can see, mounting Dropfox folder locally in your file system using Dbxfs utility is no big deal. As far tested, dbxfs just works fine as expected. Give it a try if you&#8217;re interested to see how it works and let us know about your experience in the comment section below.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>First install python3 and python3-pip Check if python3 is installed: python3 &#8211;version If not install python3: apt install python3-pip Install python3-pip apt install python3-pip Check if pip3 is installed: pip3 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":81,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[67,8,14,69,68],"class_list":["post-132","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","tag-dropbox","tag-linux","tag-mint","tag-mount","tag-network-drive"],"_links":{"self":[{"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/posts\/132","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/comments?post=132"}],"version-history":[{"count":1,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/posts\/132\/revisions"}],"predecessor-version":[{"id":133,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/posts\/132\/revisions\/133"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/media\/81"}],"wp:attachment":[{"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/media?parent=132"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/categories?post=132"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cimalink.eu\/blog\/wp-json\/wp\/v2\/tags?post=132"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}