0694.html 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. <!DOCTYPE html>
  2. <html lang="en" xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <title>Running File Browser in Docker</title>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  6. <meta charset="UTF-8">
  7. <meta name="keywords" content="Browser Based,Docker Made Easy,Home Lab,Home Lab Ideas,Install Guide,Self-Hosted,Web Based,Web Based Tools,Containerize,Containers,Docker,Docker Container,Docker Host,Docker How To,Docker Made Simple,Docker Setup Tutorial,Docker Simplified,FOSS,Linux,Ubuntu,File Browser,Web Based File Management,Manage Files From A Browser,How To,Tutorial,i12bretro">
  8. <meta name="author" content="i12bretro">
  9. <meta name="description" content="Running File Browser in Docker">
  10. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  11. <meta name="revised" content="12/11/2022 10:25:40 AM" />
  12. <link rel="icon" type="image/x-icon" href="includes/favicon.ico">
  13. <script type="text/javascript" src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
  14. <script type="text/javascript" src="includes/js/steps.js"></script>
  15. <link href="css/steps.css" rel="stylesheet" type="text/css" />
  16. </head>
  17. <body>
  18. <div id="gridContainer">
  19. <div class="topMargin"></div>
  20. <div id="listName" class="topMargin">
  21. <h1>Running File Browser in Docker</h1>
  22. </div>
  23. <div></div>
  24. <div id="content">
  25. <h2>What is File Browser?</h2>
  26. <blockquote><em>filebrowser provides a file managing interface within a specified directory and it can be used to upload, delete, preview, rename and edit your files. It allows the creation of multiple users and each user can have its own directory. It can be used as a standalone app or as a middleware. -<a href="https://github.com/filebrowser/filebrowser" target="_blank">https://github.com/filebrowser/filebrowser</a></em></blockquote>
  27. <h2>Installing Docker</h2>
  28. <ol>
  29. <li>Log into the Linux based device</li>
  30. <li>Run the following commands in the terminal
  31. <div class="codeBlock"># install prerequisites<br />
  32. sudo apt install apt-transport-https ca-certificates curl software-properties-common gnupg-agent -y<br />
  33. # add docker gpg key<br />
  34. curl -fsSL https://download.docker.com/linux/$(awk -F&#39;=&#39; &#39;/^ID=/{ print $NF }&#39; /etc/os-release)/gpg | sudo apt-key add -<br />
  35. # add docker software repository<br />
  36. sudo add-apt-repository &quot;deb [arch=$(dpkg --print-architecture)] https://download.docker.com/linux/$(awk -F&#39;=&#39; &#39;/^ID=/{ print $NF }&#39; /etc/os-release) $(lsb_release -cs) stable&quot;<br />
  37. # install docker<br />
  38. sudo apt install docker-ce docker-compose containerd.io -y<br />
  39. # enable and start docker service<br />
  40. sudo systemctl enable docker &amp;&amp; sudo systemctl start docker<br />
  41. # add the current user to the docker group<br />
  42. sudo usermod -aG docker $USER<br />
  43. # reauthenticate for the new group membership to take effect<br />
  44. su - $USER</div>
  45. </li>
  46. </ol>
  47. <h2>Running File Browser</h2>
  48. <ol>
  49. <li>Now that Docker is installed, run the following commands to setup the File Browser Docker container and run it
  50. <div class="codeBlock"># create working directories<br />
  51. mkdir ~/docker/filebrowser -p<br />
  52. # set owner of working directories<br />
  53. sudo chown &quot;$USER&quot;:&quot;$USER&quot; ~/docker -R<br />
  54. # create db placeholder file<br />
  55. touch ~/docker/filebrowser/filebrowser.db<br />
  56. # run the file browser docker container<br />
  57. # change the first volume to the path you&#39;d like to share<br />
  58. # i&#39;ll be sharing out my home directory in this example<br />
  59. docker run -d --name=filebrowser -v ~/:/srv -v ~/docker/filebrowser/filebrowser.db:/database.db -e PGID=$(id -g) -e PUID=$(id -u) -p 8092:80 --restart=unless-stopped filebrowser/filebrowser</div>
  60. </li>
  61. <li>Open a web browser and navigate to http://DNSorIP:8092</li>
  62. <li>Login with username admin and password admin</li>
  63. <li>Select Settings from the left navigation menu</li>
  64. <li>Scroll to the bottom of the page and enter and confirm a new password for the admin user &gt; Click the Update button</li>
  65. <li>Select Global Settings at the top of the page</li>
  66. <li>Scroll down and set the theme to Dark &gt; Click the Update button at the bottom of the page</li>
  67. <li>Select Logout from the left navigation menu</li>
  68. <li>Login with username admin and the new password set earlier</li>
  69. <li>Welcome to File Browser</li>
  70. </ol>
  71. <p>Documentation: <a href="https://filebrowser.org/installation#docker" target="_blank">https://filebrowser.org/installation#docker</a></p> </div>
  72. </div>
  73. </body>
  74. </html>