{"id":869,"date":"2023-01-15T21:17:22","date_gmt":"2023-01-15T15:47:22","guid":{"rendered":"https:\/\/lazytourer.com\/in\/?p=869"},"modified":"2024-03-06T12:52:37","modified_gmt":"2024-03-06T07:22:37","slug":"self-hosted-home-lab-server-in-india-with-cloudflare-tunnel-for-external-internet-access","status":"publish","type":"post","link":"https:\/\/lazytourer.com\/in\/self-hosted-home-lab-server-in-india-with-cloudflare-tunnel-for-external-internet-access\/","title":{"rendered":"Self-Hosted Home Lab Server in India with CloudFlare Tunnel for external Internet Access"},"content":{"rendered":"\n<p>In this guide, we will show you how to build a personal home cloud server in India using low-powered, inexpensive, and old hardware. The server will be accessible from the internet and cost almost nothing to set up.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Why Build a Home Lab Self Hosted Cloud Server?<\/strong><\/p>\n\n\n\n<p>It can be for work, study or simply enjoyment purpose. You may have your own reason. But generally speaking, a server is meant to perform some specific duties and it is built based on that requirement.<\/p>\n\n\n\n<p>For me, I wanted to have a self-hosted cloud backup server to replace my reliance on Google Drive \/ Google Photos or Microsoft One Drive or Apple iCloud or such large companies. I want to make sure that my server can automatically backup my phone videos or photos and I can free up space in my phone and view them directly from my server via Internet. Furthermore, I want to stream media, like Prime Video or Netflix, where I can put my movies \/ videos and stream them in my TVs, iPads or any other device.<\/p>\n\n\n\n<p>We have already shared couple of articles and tutorial guides in this same topic. Like for example, how to create a <a href=\"https:\/\/lazytourer.com\/in\/how-to-install-setup-use-nextcloud-as-google-photo-alternative-for-local-backup\/\" target=\"_blank\" rel=\"noreferrer noopener\">NextCloud Backup Server using Virtual Machine<\/a> at home for backing up your phone media, photos and videos. Furthermore, we have shared a detailed tutorial on <a href=\"https:\/\/lazytourer.com\/in\/how-to-setup-nextcloud-self-hosted-home-backup-internet-server\/\" target=\"_blank\" rel=\"noreferrer noopener\">how setup a nextcloud backup server at home in India and use AWS based VPS VPN<\/a> setup to make it accessible from external internet.<\/p>\n\n\n\n<p>In this tutorial, we will not only build a personal home cloud server, but we will also perform three additional tasks on a single server setup.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>What is a SERVER?<\/strong><\/p>\n\n\n\n<p>This tutorial will show you that you don&#8217;t need expensive rack-mounted equipment or enterprise-level hardware to build a personal home cloud server. In fact, a regular laptop or desktop computer can be used as a server. We will demonstrate this by using low-cost hardware in our setup.<\/p>\n\n\n\n<p>A server is a computer, having same major components as your laptop or PC. CPU \/ GPU \/ RAM \/ HDD \/ Network \/ HDD connected to a motherboard with a power supply. However, dedicated server components are built with tougher materials for non-stop 24&#215;7 operations under high load. There is no stopping us from converting our laptop or Desktop PC into a fully functional server since it&#8217;s just the Operating System &amp; Software or apps that are different compared to PC and Server.<\/p>\n\n\n\n<p>That is exactly what we are going to do in this tutorial.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Requirements &#8211; Minimum Prerequisites<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>One Spare Computer -&gt; To make a server<\/strong><br><br>It can be an old Laptop or Desktop or a dedicated server. Any computer with a LAN Port will do. Bare minimum you need to have an Intel Core 2 Duo or AMD Dual Core processor or higher along with 2GB of RAM. You can use any ARM based system boards like Raspberry Pi too. You would only need Display \/ Keyboard \/ Mouse for setup process as after that, everything can be done &amp; controlled via network access and server will run in Headless mode.<br><\/li>\n\n\n\n<li><strong>Switch or Router -&gt; For Remote operation<\/strong><br><br>The Server needs to be connected to a local network with Internet access for internet access &amp; remote operation.<br><\/li>\n\n\n\n<li><strong>Internet Connection<\/strong><br><br>Any Indian ISP will work. Regardless of the speed and network type like Wireless 4G\/5G connection or ADSL or Fiber networks. -&gt; No, you don&#8217;t need any Static public IP. It will work even with CG-NAT type connections too.<br><\/li>\n\n\n\n<li><strong>One Top Level Domain Name<\/strong><br><br>Any domain name will do. Not sub domain, you need Fully Qualified TLD. Any extension will do, so you can purchase the cheapest domain name available. Whatever DOT it is.<br><\/li>\n\n\n\n<li><strong>Cloudflare FREE Account<\/strong><br><br>One Cloudflare free account.<br><\/li>\n\n\n\n<li><strong>One Credit or Debit Card<\/strong><br><br>For purchase of domain name &amp; although the Cloudflare account is free but for verification purpose, you need that Debit or Credit Card. Don&#8217;t worry, there are no auto bill charging. Card will be used only once for verification.<br><\/li>\n\n\n\n<li><strong>One USB Pen Drive 4GB or higher<\/strong><br><br>For bootable installation disc making purpose.<br><\/li>\n\n\n\n<li><strong>List of Software needed<\/strong><br><br>Ubuntu 22 LTS Server \/ Rufus \/ Docker \/ Docker Compose \/ Nextcloud (Snap) \/ Photo Prism \/ Jellyfin Server \/ Cloudflare Secure Tunnel -&gt; All of these are FREE &amp; Legal software and most of them are open source.<br><\/li>\n\n\n\n<li><strong>Your Primary Computer<\/strong><br><br>You need your primary computer for prepping the installation ISO USB drive and then operate the server via network remote access. This can be a laptop, desktop, Windows PC, MAC or anything connected to the same local network (via Wireless or LAN) as the server.<\/li>\n<\/ul>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Selection of Server<\/strong> Hardware<\/p>\n\n\n\n<p>I am going to use a 15-year-old Desktop PC with some modern hardware, like SSD and HDD added to it. It is one of my very OLD PC.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>Components<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\"><strong>Description<\/strong><\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>CPU (Processor)<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Intel Core 2 Quad Q6600 @ 2.4GHz<br>Quad Core \/ LGA775 \/ 8MB L2<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>CPU Cooler \/ FAN<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Silverstone KR03 Krypton<br><a href=\"https:\/\/amzn.to\/3ZCvaka\" target=\"_blank\" rel=\"noreferrer noopener\">Amazon Product link<\/a><\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>GPU<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Motherboard Integrated GPU<br>Intel G41 Chipset<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>RAM<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">6 (4+2) GB DDR3<br><a href=\"https:\/\/amzn.to\/3ivEmGe\" target=\"_blank\" rel=\"noreferrer noopener\">Amazon Product Link<\/a><\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>Motherboard<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Zebronics G41 Generic Board<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>Storage SSD (Boot Drive)<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Consistent 256GB SATA SSD<br><a href=\"https:\/\/youtu.be\/bzdOVCiaFIA\" target=\"_blank\" rel=\"noreferrer noopener\">Our Review<\/a> \/ <a href=\"https:\/\/amzn.to\/3iygPnV\" target=\"_blank\" rel=\"noreferrer noopener\">Amazon Product link<\/a><\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>Storage HDD (Data Drive)<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">WD 500 GB 7200 SATA<br>Desktop 3.5inch HDD<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>PCi-E LAN Card<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">TP-Link PCI-E 1G LAN Card<br>RJ45 \/ <a href=\"https:\/\/amzn.to\/3Qsj5K5\" target=\"_blank\" rel=\"noreferrer noopener\">Amazon Product Link<\/a><\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>PSU (SMPS)<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Consistent (generic) 400W<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>Cabinet<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Old Generic HCL Cabinet<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\"><strong>UPS<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">Cheap UPS<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"488\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Server_Front_End.jpg\" alt=\"\" class=\"wp-image-981\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Server_Front_End.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Server_Front_End-300x225.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/C2Q_Q6600_BIOS_01.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"600\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/C2Q_Q6600_BIOS_01.jpg\" alt=\"\" class=\"wp-image-877\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/C2Q_Q6600_BIOS_01.jpg 800w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/C2Q_Q6600_BIOS_01-300x225.jpg 300w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/C2Q_Q6600_BIOS_01-768x576.jpg 768w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>You can use any thing that is available with you. However, if you are considering purchasing an old 2nd hand PC for this purpose, try to buy Intel Core i5\/i7 3rd generation or higher for better performance result.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Domain Purchase \/ CloudFlare Acc Settings<\/strong><\/p>\n\n\n\n<p><strong>Step 1 -&gt; Buying a Domain Name<\/strong><\/p>\n\n\n\n<p>Domain names are usually priced based on their extension. Like .com \/ .org or .in and so on. If you search for cheap domain names, you may find some lesser known and uncommon extension like .pw or such at dirt cheap price. For example, for this project, at the time of writing this article, I found online domains are sold at USD 1.25.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/domain-purchase-receipt-01.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"712\" height=\"575\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/domain-purchase-receipt-01.jpg\" alt=\"\" class=\"wp-image-880\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/domain-purchase-receipt-01.jpg 712w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/domain-purchase-receipt-01-300x242.jpg 300w\" sizes=\"auto, (max-width: 712px) 100vw, 712px\" \/><\/a><\/figure>\n\n\n\n<p>I have registered <strong>Hunky.Online<\/strong> domain for one year by paying USD 1.25 only. For yourself, you can register anything that you want, and which is available at lowest cost. Offers vary, choose any extension since that too doesn&#8217;t affect the functionality of setup. It just needs to be a TLD or ccTLD.<\/p>\n\n\n\n<p><strong>Step 2 -&gt; Creating CloudFlare Account<\/strong><\/p>\n\n\n\n<p>Visit Cloudflare website @ https:\/\/www.cloudflare.com\/ and create your own FREE account. You may need your debit \/ credit card for activating domain adding feature. Don&#8217;t worry, it may charge a few rupees for verification but that too is given refund within couple of days. There are many videos in YouTube on the step-by-step process of creating this account. If you need, you can search and follow them. But generally speaking, it&#8217;s very simple. Just liking creating an email account or amazon account.<\/p>\n\n\n\n<p><strong>Step 3 -&gt; Adding your Domain into Cloudflare Account<\/strong><\/p>\n\n\n\n<p>Once logged, at the Cloudflare dashboard page, click the left hard side bar option &#8220;Websites&#8221; and add your domain name there. It may generate error or warn you that name servers aren&#8217;t matching, ignore and continue the adding process. DO NOT allow it to copy any existing DNS records, add this domain with fresh \/ empty DNS records.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"895\" height=\"713\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_01a.jpg\" alt=\"\" class=\"wp-image-885\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_01a.jpg 895w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_01a-300x239.jpg 300w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_01a-768x612.jpg 768w\" sizes=\"auto, (max-width: 895px) 100vw, 895px\" \/><\/figure>\n\n\n\n<p>Process won&#8217;t be completed till the DNS records are updated so Cloudflare will generate following message for you.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"527\" height=\"559\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_02.jpg\" alt=\"\" class=\"wp-image-883\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_02.jpg 527w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_02-283x300.jpg 283w\" sizes=\"auto, (max-width: 527px) 100vw, 527px\" \/><\/figure>\n\n\n\n<p>Time to go back to that website from where you can bought &amp; registered the domain. There under your domain control DNS panel, change the &#8220;Name Server \/ NS Records&#8221; to Cloudflare given one. After that return here and click that Done, Check nameservers. It may take a few hours for things update and reflect back here.<\/p>\n\n\n\n<p>Within few hours of these updates, system should show your domain is added to the Cloudflare dashboard (network). Here is mine, and there click your domain &amp; visit the DNS section to ensure that no DNS entry is present, it is showing empty apart from NS Records.<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_03.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"519\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_03.jpg\" alt=\"\" class=\"wp-image-888\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_03.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_03-300x240.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"543\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_04a.jpg\" alt=\"\" class=\"wp-image-890\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_04a.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_04a-300x251.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p><strong>Step 4 -&gt; Creating tunnel code &amp; Sub domains<\/strong><\/p>\n\n\n\n<p>Once the domain is active in your Cloudflare account, it is time to generate the code for tunnel and creating the subsequent sub-domains to run the services.<\/p>\n\n\n\n<p>Under your Cloudflare dashboard page left hand side, you may find an option called &#8220;Zero Trust&#8221;. Click that to open the Zero Trust dashboard. There, click &#8220;Tunnels&#8221; at the LHS menu items.<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_05.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"292\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_05.jpg\" alt=\"\" class=\"wp-image-906\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_05.jpg 400w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_05-300x219.jpg 300w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_06.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"331\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_06.jpg\" alt=\"\" class=\"wp-image-907\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_06.jpg 400w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_06-300x248.jpg 300w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>Click Create Tunnel -&gt; Provide a name -&gt; Click Save Tunnel -&gt; This will generate the installation code. You need the Debian x64 code, so copy that code to a notepad (save it) and click next to proceed toward creating host name (sub domains)<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_07.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"295\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_07.jpg\" alt=\"\" class=\"wp-image-908\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_07.jpg 400w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_07-300x221.jpg 300w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_08.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"387\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_08.jpg\" alt=\"\" class=\"wp-image-909\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_08.jpg 400w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_08-300x290.jpg 300w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_09.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"353\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_09.jpg\" alt=\"\" class=\"wp-image-910\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_09.jpg 400w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_09-300x265.jpg 300w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>Do not create any Host Name \/ Sub domain as of now, just save the tunnel and exit. We will come back here after our local server is ready for host name \/ sub domain creation.<\/p>\n\n\n\n<p><strong>Step 5 -&gt; Enabling SSL Certificate Encryption<\/strong><\/p>\n\n\n\n<p>Go back to the main dashboard page of Cloudflare and click option SSL\/TLS -&gt; There select Flexible to turn on the SSL Certificate and Encryption.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"375\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_10.jpg\" alt=\"\" class=\"wp-image-913\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_10.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_10-300x173.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/figure>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Ubuntu Server &#8211; Installation \/ Configuration<\/strong><\/p>\n\n\n\n<p><strong>Step 1 -&gt; Ubuntu Server 22 LTS Installation Disk (USB)<\/strong><\/p>\n\n\n\n<p>Task is simple. Visiting Ubuntu Website and downloading the Server Installation ISO for latest LTS release. As of writing this article, it is 22 LTS. Once the image is downloaded in your primary PC, download a small program called Rufus from their website @ https:\/\/rufus.ie and run it to create your Ubuntu Installation USB. There are hundreds of videos and article on how to do this, it&#8217;s really simple but if you still want to, you can search Google or YouTube &amp; follow any of those step-by-step instructions.<\/p>\n\n\n\n<p><strong>Step 2 -&gt; Installing Ubuntu Server 22 LTS<\/strong><\/p>\n\n\n\n<p>Connect your monitor &amp; keyboard \/ mouse to the PC you intend to use as server, in case you are reusing a laptop then you can proceed directly since it has its own built-in display \/ keyboard \/ mouse. In my case, since I have multiple Disks in my server, just for safety, I am only connecting the SSD and leaving the HDD unplugged for the installation.<\/p>\n\n\n\n<p>Installation process is simple. You just need to boot into the USB by changing the BIOS to allow the system boot from USB and then proceed with the installation prompts. Once again, you can find tons of step-by-step guide via Google or YouTube searching for any help you require.<\/p>\n\n\n\n<p><strong>Pro-tip -&gt;<\/strong> While you are in the installation wizard, everything needs to be default except couple of things that you need to do. First, note down the &#8220;MAC Address&#8221; of your server Network Card. Secondly, Ubuntu by default doesn&#8217;t allocate the entire disc so at partition prompt, just change one entry under ubuntu-lv and edit that value to change it to maximum available. Thirdly, ensure to check box the option for OpenSSH Server installation.<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Ubuntu_Install_01.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"289\" height=\"301\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Ubuntu_Install_01.jpg\" alt=\"\" class=\"wp-image-892\"\/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2021\/12\/Ubuntu_Install_03.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"728\" height=\"487\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2021\/12\/Ubuntu_Install_03.jpg\" alt=\"\" class=\"wp-image-494\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2021\/12\/Ubuntu_Install_03.jpg 728w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2021\/12\/Ubuntu_Install_03-300x201.jpg 300w\" sizes=\"auto, (max-width: 728px) 100vw, 728px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Ubuntu_Install_02.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"417\" height=\"260\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Ubuntu_Install_02.jpg\" alt=\"\" class=\"wp-image-893\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Ubuntu_Install_02.jpg 417w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/Ubuntu_Install_02-300x187.jpg 300w\" sizes=\"auto, (max-width: 417px) 100vw, 417px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p><strong>Step 3 -&gt; Static Local NAT LAN IP for the Ubuntu Server<\/strong><\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:66.66%\">\n<p>Although it is not mandatory in this setup, but for ease of use (remote access), it is better to setup a Static Lan IP in your server. There are two ways of doing it. Either you can setup the Static IP directly in Ubuntu or use your router to send a specific static IP to this server. I prefer the second method. So, log into your home router and look for option called DHCP and there you can use that MAC address (remember, something you noted down while installing Ubuntu) to assign the server a Static LAN NAT IP.<br><br>In my case, it is set to 192.168.1.30 -&gt; for my installation.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:33.33%\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/LAN_IP_Static.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"349\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/LAN_IP_Static.jpg\" alt=\"\" class=\"wp-image-895\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/LAN_IP_Static.jpg 450w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/LAN_IP_Static-300x233.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p><strong>Step 4 -&gt; Updating the Server<\/strong><\/p>\n\n\n\n<p>Once you have set the Static IP for your server, it is time for first remote login. You can use a tool called Putty or you can simply start Widows Command Prompt or Terminal (by typing CMD in Start Search Bar) &amp; type following command to log in,<\/p>\n\n\n\n<p class=\"has-black-color has-text-color\"><code><strong>ssh user-name@IP-Address<\/strong><\/code> -&gt; Replace the username and IP with your own.<\/p>\n\n\n\n<p>Enter Password when prompted to login. Once you have a successful login, then run following commands to update the system.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo su<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo timedatectl set-timezone Asia\/Kolkata<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo apt update &amp;&amp; sudo apt upgrade -y<\/mark><\/code><\/strong><\/p>\n\n\n\n<p>After the update the finishes, run following command to reboot the system.<\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo reboot<\/code><\/strong><\/p>\n\n\n\n<p><strong>Step 5 -&gt; Docker \/ Docker Compose Installation<\/strong><\/p>\n\n\n\n<p>Run the following command one by one for docker installation,<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo su<\/mark><\/code><\/strong><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo apt install lsb-release ca-certificates apt-transport-https software-properties-common -y<\/code><\/strong><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><code><strong>sudo curl -fsSL https:\/\/download.docker.com\/linux\/ubuntu\/gpg | sudo gpg --dearmor -o \/usr\/share\/keyrings\/docker-archive-keyring.gpg<\/strong><\/code><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo echo \"deb [arch=$(dpkg --print-architecture) signed-by=\/usr\/share\/keyrings\/docker-archive-keyring.gpg] https:\/\/download.docker.com\/linux\/ubuntu $(lsb_release -cs) stable\" | sudo tee \/etc\/apt\/sources.list.d\/docker.list &gt; \/dev\/null<\/code><\/strong><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo apt update &amp;&amp; sudo apt install docker-ce -y<\/code><\/strong><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo mkdir -p ~\/.docker\/cli-plugins\/<\/code><\/strong><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo curl -SL https:\/\/github.com\/docker\/compose\/releases\/download\/v2.23.3\/docker-compose-linux-x86_64 -o ~\/.docker\/cli-plugins\/docker-compose<\/code><\/strong><\/p>\n\n\n\n<p>Pro-Tip -&gt; For the above command, visit <a href=\"https:\/\/github.com\/docker\/compose\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/github.com\/docker\/compose<\/a> and replace version number with the latest release. At the time of writing this article, the latest version is v2.15.1 but it will change to newer release when you would be reading this article.<\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color\"><strong><code>sudo chmod +x ~\/.docker\/cli-plugins\/docker-compose<\/code><\/strong><\/p>\n\n\n\n<p><strong>Step 6 -&gt; Adding \/ Formatting \/ Mounting the Data HDD<\/strong><\/p>\n\n\n\n<p>This is optional and only applies to someone who has setup like me with multiple HDDs \/ SSDs in their server. If you remember, at the time of installation, I only connected and SSD SATA Cable and now it is time to shut down the server &amp; connect the second disk, my 500GB HDD. Unlike Windows Linux will not automatically mount or load a drive and show it to you. You have to manually mount it.<\/p>\n\n\n\n<p>If you are using converting a PC \/ Laptop as server with single disc, they you can skip this process but since I have a sperate data drive of 500GB Hard Disk, so here is how it is formatted at mounted on to Ubuntu.<\/p>\n\n\n\n<p>First is to ensure that Ubuntu has detected the drive. Run command <code><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo lsblk<\/mark><\/strong><\/code> to check second HDD showing. It should now be visible as <strong><mark style=\"background-color:#000000\" class=\"has-inline-color has-pale-cyan-blue-color\">sdb &#8211; 500 GB<\/mark><\/strong>. If not, you need to shutdown the server and check your hardware \/ physical connections. Once you see it is showing via that command, then proceed towards the next step to format and mounting by running following commands one by one.<\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo mkdir \/media\/500GB<\/code><\/mark><\/strong> -&gt; It will create a mount point for drive loading with name 500GB<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo mkfs.ext4 -j -L 500GB \/dev\/sdb<\/mark><\/code><\/strong> -&gt; This will format the HDD with a single partition with EXT4 file system<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo blkid \/dev\/sdb<\/mark><\/code><\/strong> -&gt; It will show UUID output like below screenshot of my system. You need to use your mouse to select that UUID string and press enter to copy it. Then go to note pad and paste it there.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"656\" height=\"320\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/HDD_Mounting_02.jpg\" alt=\"\" class=\"wp-image-902\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/HDD_Mounting_02.jpg 656w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/HDD_Mounting_02-300x146.jpg 300w\" sizes=\"auto, (max-width: 656px) 100vw, 656px\" \/><\/figure>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo nano \/etc\/fstab<\/code><\/mark><\/strong> -&gt; It will open a Linux configuration file in CLI text editor. Use your keyboard arrow keys to get down to the last line. Here you need to paste (right click to paste) following -&gt; <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-green-cyan-color\">\/dev\/disk\/by-uuid\/4006fe68-879a-41ed-b4da-cc0e6bc6b4bb \/media\/500GB auto nosuid,nodev,nofail,x-gvfs-show,x-gvfs-name=NewHDD 0 0<\/mark><\/code><\/strong> -&gt; Remember to replace the UUID with the one you have got. DO NOT change or modify anything else on this file. After pasting, press CTRL + X, then type Y and &#8220;enter&#8221; to save and exit the file.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo mount -a<\/mark><\/code><\/strong> -&gt; This will mount the drive. If something is wrong, it will through an error.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Nextcloud installation \/ Configuration<\/strong><\/p>\n\n\n\n<p>Run the following commands one by one to install \/ configure Nextcloud snap version and (optional) move the storage from boot disk to data disk.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo su<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo snap install nextcloud<\/code><\/mark><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo nextcloud.manual-install user password<\/mark><\/code><\/strong> -&gt; replace the username and password with your own.<\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo snap connect nextcloud:network-observe<\/code><\/mark><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo snap connect nextcloud:removable-media<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo nextcloud.occ config:system:set trusted_domains 1 --value=192.168.1.30<\/code><\/mark><\/strong> -&gt; Replace the IP address with your own Server IP.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo nextcloud.occ config:system:set trusted_domains 2 --value=nextcloud.hunky.online<\/mark><\/code><\/strong> -&gt; Replace the sub-domain name with your own (the one you wish to create at Cloudflare)<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo nextcloud.enable-https self-signed<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo snap set nextcloud ports.http=880 ports.https=1444<\/code><\/mark><\/strong> -&gt; This is to change Nextcloud from default web ports to some non-standard free ports.<\/p>\n\n\n\n<p>This is optional to my setup. This is to move user data from SSD boot drive to my HDD data drive. Run command, <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo nano \/var\/snap\/nextcloud\/current\/nextcloud\/config\/config.php<\/code><\/mark><\/strong> -&gt; This will open up Nextcloud configuration file in a CLI text editor. Be very careful, DO NOT change or modify it in anyway apart from one line called &#8220;DataDirectory&#8221; change the value to -&gt; <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-green-cyan-color\">\/media\/500GB\/ncdata\/data<\/mark><\/code><\/strong> Press CTRL + X then type Y and press enter to save and exit.<\/p>\n\n\n\n<p><code><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo mkdir \/media\/500GB\/ncdata<\/mark><\/strong><\/code> then run, <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo mv \/var\/snap\/nextcloud\/common\/nextcloud\/data \/media\/500GB\/ncdata\/<\/mark><\/code><\/strong> then run <code><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo chown -R root:root \/media\/500GB\/ncdata<\/mark><\/strong><\/code> and <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo chmod 0770 \/media\/500GB\/ncdata<\/mark><\/code><\/strong><\/p>\n\n\n\n<p>Reboot the system -&gt; <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo reboot<\/mark><\/code><\/strong><\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Jellyfin Server Installation<\/strong><\/p>\n\n\n\n<p>We are going to use Docker and Docker compose for Jellyfin installation. We have already installed both Docker and Docker Compose with our ubuntu server installation. All it remains is to create the configuration file to start the container. In my case, since I have a separate data disc, so I am creating it there. If you have single disk server configuration, you can run it in your boot disc user directory. Just create a directory for that.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo su<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\"><code>sudo mkdir \/media\/500GB\/jellyfin<\/code><\/mark><\/strong><\/p>\n\n\n\n<p><code><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo nano \/media\/500GB\/jellyfin\/docker-compose.yml<\/mark><\/strong><\/code><strong> <\/strong>-&gt; This will create an open an empty configuration file in a CLI text editor. Paste (Right mouse click) the following,<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>version: '3.5'\nservices:\n  jellyfin:\n    image: jellyfin\/jellyfin\n    container_name: jellyfin\n    network_mode: 'host'\n    volumes:\n      - .\/config:\/config\n      - .\/cache:\/cache\n      - .\/media:\/media\n      - .\/media2:\/media2:ro\n    restart: 'unless-stopped'\n    # Optional - alternative address used for autodiscovery\n    environment:\n      - JELLYFIN_PublishedServerUrl=http:\/\/example.com\n    # Optional - may be necessary for docker healthcheck to pass if running in host network mode\n    extra_hosts:\n      - \"host.docker.internal:host-gateway\"<\/code><\/pre>\n\n\n\n<p>After pasting, in your keyboard, press CTRL+X then SHIFT+Y and press ENTER to save and exit.<\/p>\n\n\n\n<p>We are not yet starting this server container since there is a small change that we need to make for Nextcloud integration before staring it. This to allow Jellyfin use a Nextcloud upload folder as it&#8217;s media library.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>PhotoPrism Installation<\/strong><\/p>\n\n\n\n<p>Photo Prism is going to run via Docker &amp; docker compose. We have already installed both Docker and Docker Compose with our ubuntu server installation. All it remains is to create the configuration file to start the container. In my case, since I have a separate data disc, so I am creating it there. If you have single disk server configuration, you can run it in your boot disc user directory. Just create a directory for that.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo su<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo mkdir \/media\/500GB\/photoprism<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo nano \/media\/500GB\/photoprism\/docker-compose.yml<\/mark><\/code><\/strong> -&gt; This will create an open an empty configuration file in a CLI text editor. Paste the following, but make sure to change the user name and passwords. For better understanding, all passwords are here written as &#8220;ChangeMe&#8221; -&gt; Make sure to enter your own.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>version: '3.5'\n\n# Example Docker Compose config file for PhotoPrism (Linux \/ AMD64)\n#\n# Note:\n# - Hardware transcoding is only available for sponsors due to the high maintenance and support effort.\n# - Running PhotoPrism on a server with less than 4 GB of swap space or setting a memory\/swap limit can cause unexpected\n#   restarts (\"crashes\"), for example, when the indexer temporarily needs more memory to process large files.\n# - If you install PhotoPrism on a public server outside your home network, please always run it behind a secure\n#   HTTPS reverse proxy such as Traefik or Caddy. Your files and passwords will otherwise be transmitted\n#   in clear text and can be intercepted by anyone, including your provider, hackers, and governments:\n#   https:\/\/docs.photoprism.app\/getting-started\/proxies\/traefik\/\n#\n# Setup Guides:\n# - https:\/\/docs.photoprism.app\/getting-started\/docker-compose\/\n# - https:\/\/docs.photoprism.app\/getting-started\/raspberry-pi\/\n#\n# Troubleshooting Checklists:\n# - https:\/\/docs.photoprism.app\/getting-started\/troubleshooting\/\n# - https:\/\/docs.photoprism.app\/getting-started\/troubleshooting\/docker\/\n# - https:\/\/docs.photoprism.app\/getting-started\/troubleshooting\/mariadb\/\n#\n# CLI Commands:\n# - https:\/\/docs.photoprism.app\/getting-started\/docker-compose\/#command-line-interface\n#\n# All commands may have to be prefixed with \"sudo\" when not running as root.\n# This will point the home directory shortcut ~ to \/root in volume mounts.\n\nservices:\n  photoprism:\n    ## Use photoprism\/photoprism:preview for testing preview builds:\n    image: photoprism\/photoprism:latest\n    depends_on:\n      - mariadb\n    ## Don't enable automatic restarts until PhotoPrism has been properly configured and tested!\n    ## If the service gets stuck in a restart loop, this points to a memory, filesystem, network, or database issue:\n    ## https:\/\/docs.photoprism.app\/getting-started\/troubleshooting\/#fatal-server-errors\n    restart: unless-stopped\n    security_opt:\n      - seccomp:unconfined\n      - apparmor:unconfined\n    ports:\n      - \"2342:2342\" # HTTP port (host:container)\n    environment:\n      PHOTOPRISM_ADMIN_USER: \"admin\"                 # superadmin username\n      PHOTOPRISM_ADMIN_PASSWORD: \"Change@Me\"          # initial superadmin password (minimum 8 characters)\n      PHOTOPRISM_AUTH_MODE: \"password\"               # authentication mode (public, password)\n      PHOTOPRISM_SITE_URL: \"http:\/\/localhost:2342\/\"  # server URL in the format \"http(s):\/\/domain.name(:port)\/(path)\"\n      PHOTOPRISM_ORIGINALS_LIMIT: 5000               # file size limit for originals in MB (increase for high-res video)\n      PHOTOPRISM_HTTP_COMPRESSION: \"gzip\"            # improves transfer speed and bandwidth utilization (none or gzip)\n      PHOTOPRISM_LOG_LEVEL: \"info\"                   # log level: trace, debug, info, warning, error, fatal, or panic\n      PHOTOPRISM_READONLY: \"false\"                   # do not modify originals directory (reduced functionality)\n      PHOTOPRISM_EXPERIMENTAL: \"false\"               # enables experimental features\n      PHOTOPRISM_DISABLE_CHOWN: \"false\"              # disables updating storage permissions via chmod and chown on startup\n      PHOTOPRISM_DISABLE_WEBDAV: \"false\"             # disables built-in WebDAV server\n      PHOTOPRISM_DISABLE_SETTINGS: \"false\"           # disables settings UI and API\n      PHOTOPRISM_DISABLE_TENSORFLOW: \"false\"         # disables all features depending on TensorFlow\n      PHOTOPRISM_DISABLE_FACES: \"false\"              # disables face detection and recognition (requires TensorFlow)\n      PHOTOPRISM_DISABLE_CLASSIFICATION: \"false\"     # disables image classification (requires TensorFlow)\n      PHOTOPRISM_DISABLE_RAW: \"false\"                # disables indexing and conversion of RAW files\n      PHOTOPRISM_RAW_PRESETS: \"false\"                # enables applying user presets when converting RAW files (reduces performance)\n      PHOTOPRISM_JPEG_QUALITY: 85                    # a higher value increases the quality and file size of JPEG images and thumbnails (25-100)\n      PHOTOPRISM_DETECT_NSFW: \"false\"                # automatically flags photos as private that MAY be offensive (requires TensorFlow)\n      PHOTOPRISM_UPLOAD_NSFW: \"true\"                 # allows uploads that MAY be offensive (no effect without TensorFlow)\n      # PHOTOPRISM_DATABASE_DRIVER: \"sqlite\"         # SQLite is an embedded database that doesn't require a server\n      PHOTOPRISM_DATABASE_DRIVER: \"mysql\"            # use MariaDB 10.5+ or MySQL 8+ instead of SQLite for improved performance\n      PHOTOPRISM_DATABASE_SERVER: \"mariadb:3306\"     # MariaDB or MySQL database server (hostname:port)\n      PHOTOPRISM_DATABASE_NAME: \"photoprism\"         # MariaDB or MySQL database schema name\n      PHOTOPRISM_DATABASE_USER: \"photoprism\"         # MariaDB or MySQL database user name\n      PHOTOPRISM_DATABASE_PASSWORD: \"Change@Me\"       # MariaDB or MySQL database user password\n      PHOTOPRISM_SITE_CAPTION: \"AI-Powered Photos App\"\n      PHOTOPRISM_SITE_DESCRIPTION: \"\"                # meta site description\n      PHOTOPRISM_SITE_AUTHOR: \"\"                     # meta site author\n      ## Run\/install on first startup (options: update https gpu tensorflow davfs clitools clean):\n      # PHOTOPRISM_INIT: \"https gpu tensorflow\"\n      ## Hardware Video Transcoding:\n      # PHOTOPRISM_FFMPEG_ENCODER: \"software\"        # FFmpeg encoder (\"software\", \"intel\", \"nvidia\", \"apple\", \"raspberry\")\n      # PHOTOPRISM_FFMPEG_BITRATE: \"32\"              # FFmpeg encoding bitrate limit in Mbit\/s (default: 50)\n      ## Run as a non-root user after initialization (supported: 0, 33, 50-99, 500-600, and 900-1200):\n      # PHOTOPRISM_UID: 1000\n      # PHOTOPRISM_GID: 1000\n      # PHOTOPRISM_UMASK: 0000\n    ## Start as non-root user before initialization (supported: 0, 33, 50-99, 500-600, and 900-1200):\n    # user: \"1000:1000\"\n    ## Share hardware devices with FFmpeg and TensorFlow (optional):\n    # devices:\n    #  - \"\/dev\/dri:\/dev\/dri\"                         # Intel QSV\n    #  - \"\/dev\/nvidia0:\/dev\/nvidia0\"                 # Nvidia CUDA\n    #  - \"\/dev\/nvidiactl:\/dev\/nvidiactl\"\n    #  - \"\/dev\/nvidia-modeset:\/dev\/nvidia-modeset\"\n    #  - \"\/dev\/nvidia-nvswitchctl:\/dev\/nvidia-nvswitchctl\"\n    #  - \"\/dev\/nvidia-uvm:\/dev\/nvidia-uvm\"\n    #  - \"\/dev\/nvidia-uvm-tools:\/dev\/nvidia-uvm-tools\"\n    #  - \"\/dev\/video11:\/dev\/video11\"                 # Video4Linux Video Encode Device (h264_v4l2m2m)\n    working_dir: \"\/photoprism\" # do not change or remove\n    ## Storage Folders: \"~\" is a shortcut for your home directory, \".\" for the current directory\n    volumes:\n      # \"\/host\/folder:\/photoprism\/folder\"                # Example\n      - \".\/Pictures:\/photoprism\/originals\"               # Original media files (DO NOT REMOVE)\n      # - \"\/example\/family:\/photoprism\/originals\/family\" # *Additional* media folders can be mounted like this\n      # - \"~\/Import:\/photoprism\/import\"                  # *Optional* base folder from which files can be imported to originals\n      - \".\/storage:\/photoprism\/storage\"                  # *Writable* storage folder for cache, database, and sidecar files (DO NOT REMOVE)\n\n  ## Database Server (recommended)\n  ## see https:\/\/docs.photoprism.app\/getting-started\/faq\/#should-i-use-sqlite-mariadb-or-mysql\n  mariadb:\n    ## If MariaDB gets stuck in a restart loop, this points to a memory or filesystem issue:\n    ## https:\/\/docs.photoprism.app\/getting-started\/troubleshooting\/#fatal-server-errors\n    restart: unless-stopped\n    image: mariadb:10.10\n    security_opt: # see https:\/\/github.com\/MariaDB\/mariadb-docker\/issues\/434#issuecomment-1136151239\n      - seccomp:unconfined\n      - apparmor:unconfined\n    command: mysqld --innodb-buffer-pool-size=512M --transaction-isolation=READ-COMMITTED --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --max-connections=512 --innodb-rollback-on-timeout=OFF --innodb-lock-wait-timeout=120\n    ## Never store database files on an unreliable device such as a USB flash drive, an SD card, or a shared network folder:\n    volumes:\n      - \".\/database:\/var\/lib\/mysql\" # DO NOT REMOVE\n    environment:\n      MARIADB_AUTO_UPGRADE: \"1\"\n      MARIADB_INITDB_SKIP_TZINFO: \"1\"\n      MARIADB_DATABASE: \"photoprism\"\n      MARIADB_USER: \"photoprism\"\n      MARIADB_PASSWORD: \"Change@Me\"\n      MARIADB_ROOT_PASSWORD: \"Change@Me\"\n\n  ## Watchtower upgrades services automatically (optional)\n  ## see https:\/\/docs.photoprism.app\/getting-started\/updates\/#watchtower\n  ## activate via \"COMPOSE_PROFILES=update docker compose up -d\"\n  watchtower:\n    restart: unless-stopped\n    image: containrrr\/watchtower\n    profiles: &#91;\"update\"]\n    environment:\n      WATCHTOWER_CLEANUP: \"true\"\n      WATCHTOWER_POLL_INTERVAL: 7200 # checks for updates every two hours\n    volumes:\n      - \"\/var\/run\/docker.sock:\/var\/run\/docker.sock\"\n      - \"~\/.docker\/config.json:\/config.json\" # optional, for authentication if you have a Docker Hub account\n<\/code><\/pre>\n\n\n\n<p>Press CTRL+X then type SHIFT+Y and ENTER to save and exit.<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">cd \/media\/500GB\/photoprism<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo docker compose up -d<\/mark><\/code><\/strong> -&gt; This will spin up the container and start it.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Setting up CloudFlare Tunnel in Local Server<br>Creating Host Name \/ Sub-Domains<\/strong><\/p>\n\n\n\n<p>Remember the tunnel code we had generated from Cloudflare panel and saved that into a notepad file for later use? <\/p>\n\n\n\n<p>Well now is the time.<\/p>\n\n\n\n<p>So in your local server, first run <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo su<\/mark><\/code><\/strong>, then just copy paste that code and run it.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"221\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_11.jpg\" alt=\"\" class=\"wp-image-916\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_11.jpg 450w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_11-300x147.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n\n\n\n<p>Once it is done and your server is connected to the Cloudflare Network. You can now open Cloudflare account dashboard again and visit the Zero Trust section. There under tunnels, it should now show the tunnel is up and healthy.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"290\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_12.jpg\" alt=\"\" class=\"wp-image-917\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_12.jpg 450w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_12-300x193.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/figure>\n\n\n\n<p>Click Configure -&gt; Then click Public Host Name -&gt; Then click Add a Public Host Name. This should bring up the page to enter domains about your sub domains and their respective service locations. <\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_13.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"403\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_13.jpg\" alt=\"\" class=\"wp-image-918\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_13.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_13-300x186.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_14a.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"467\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_14a.jpg\" alt=\"\" class=\"wp-image-920\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_14a.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_14a-300x216.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>Enter the host name \/ public sub domains as per this format. Make sure to select your domain name that you have added into Cloudflare. In my case, it is hunky.online. You can have any subdomain value as per your liking. For me, my setup looks like this.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td><strong>Options<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\"><strong>Nextcloud<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\"><strong>PhotoPrism<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\"><strong>Jellyfin<\/strong><\/td><\/tr><tr><td><strong>Subdomain<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">nextcloud<\/td><td class=\"has-text-align-center\" data-align=\"center\">gallery<\/td><td class=\"has-text-align-center\" data-align=\"center\">movie<\/td><\/tr><tr><td><strong>Domain<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">hunky.online<\/td><td class=\"has-text-align-center\" data-align=\"center\">hunky.online<\/td><td class=\"has-text-align-center\" data-align=\"center\">hunky.online<\/td><\/tr><tr><td><strong>Path<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">nothing \/ blank<\/td><td class=\"has-text-align-center\" data-align=\"center\">nothing \/ blank<\/td><td class=\"has-text-align-center\" data-align=\"center\">nothing \/ blank<\/td><\/tr><tr><td><strong>Type<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">HTTPS<\/td><td class=\"has-text-align-center\" data-align=\"center\">HTTP<\/td><td class=\"has-text-align-center\" data-align=\"center\">HTTP<\/td><\/tr><tr><td><strong>URL<\/strong><\/td><td class=\"has-text-align-center\" data-align=\"center\">localhost:1444<\/td><td class=\"has-text-align-center\" data-align=\"center\">localhost:2342<\/td><td class=\"has-text-align-center\" data-align=\"center\">localhost:8096<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>For nextcloud there is one additional step needed for end to end encryption to work. Under &#8220;Application Additional Settings&#8221;, go to TLS option, and there turn on &#8220;No TLS Verify&#8221; and &#8220;HTTP2 Connection&#8221;. Then click &#8220;Save Hostname&#8221;.<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_001.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"237\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_001.jpg\" alt=\"\" class=\"wp-image-1015\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_001.jpg 450w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_001-300x158.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_002.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"450\" height=\"412\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_002.jpg\" alt=\"\" class=\"wp-image-1016\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_002.jpg 450w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_002-300x275.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_003.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"387\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_003.jpg\" alt=\"\" class=\"wp-image-1017\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_003.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/CloudFlare_A_003-300x179.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>Our setup is now complete. Server is now under full auto mode. You can reboot, restart the server and everything should load automatically and be ready for use.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Accessing Individual Services<\/strong><\/p>\n\n\n\n<p>Server is now online and accessible from anywhere from the world via Internet. There is no need for CLI as everything can now be accessed via browser or respective apps. Following are the three addresses for this example setup,<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td class=\"has-text-align-center\" data-align=\"center\">nextcloud.hunky.online<\/td><td class=\"has-text-align-center\" data-align=\"center\">gallery.hunky.online<\/td><td class=\"has-text-align-center\" data-align=\"center\">movie.hunky.online<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\">Our Nextcloud Server<\/td><td class=\"has-text-align-center\" data-align=\"center\">The PhotoPrism <br>Online Gallery<\/td><td class=\"has-text-align-center\" data-align=\"center\">Jellyfin<br>Streaming Server<\/td><\/tr><tr><td class=\"has-text-align-center\" data-align=\"center\">192.168.1.30:880<\/td><td class=\"has-text-align-center\" data-align=\"center\">192.168.1.30:2342<\/td><td class=\"has-text-align-center\" data-align=\"center\">192.168.1.30:8096<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>You can access the server and respective services via local IP and port when you are accessing via your local LAN Network.<\/p>\n\n\n\n<p class=\"has-text-align-left\"><strong>Configurations -&gt; NextCloud + Jellyfin Integration<\/strong><\/p>\n\n\n\n<p>We can now open up the browser and access Nextcloud via the access URL address. Either via the Internet address or by using local LAN address. Sign in using the username and password you used for installation of Nextcloud. Once inside, click the file icon in upper left corner and click the plus sign to create a new folder called &#8220;Jellyfin_data&#8221;.<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"559\" height=\"325\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/nextcloud_01.jpg\" alt=\"\" class=\"wp-image-924\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/nextcloud_01.jpg 559w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/nextcloud_01-300x174.jpg 300w\" sizes=\"auto, (max-width: 559px) 100vw, 559px\" \/><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"558\" height=\"413\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/nextcloud_02.jpg\" alt=\"\" class=\"wp-image-925\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/nextcloud_02.jpg 558w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/nextcloud_02-300x222.jpg 300w\" sizes=\"auto, (max-width: 558px) 100vw, 558px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>Now Login to your Ubuntu Server using SSH via CMD. Run following commands,<\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">cd \/media\/500GB\/jellyfin\/<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo nano docker-compose.yml<\/mark><\/code><\/strong> -> This will open the Jellyfin server configuration file in CLI text editor. We need to edit one line, &#8220;<code><strong>.\/media:\/media<\/strong><\/code>&#8221; -> delete <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-green-cyan-color\">.\/media<\/mark><\/code><\/strong> and write <code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-green-cyan-color\"><strong>\/media\/500GB\/ncdata\/data\/username\/files\/Jellyfin_data\/<\/strong><\/mark><\/code> -> Press CTRL+X then type SHIFT+Y and press ENTER to save and exit. Dont forget to replace this &#8220;username&#8221; with the user name of your nextcloud account.<\/p>\n\n\n\n<p>Start the Jellyfin -&gt; <strong><code><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-red-color\">sudo docker compose up -d<\/mark><\/code><\/strong><\/p>\n\n\n\n<p><strong>Jellyfin Server Setup \/ Configuration<\/strong><\/p>\n\n\n\n<p>Visit the address of Jellyfin via Internet or via local LAN IP. On first opening, it will ask you to create admin user account and password. Do it. Now there are various guide and videos in internet on how to do media management. You can refer there. Basically, anything you upload into that Jellyfin_data Folder of your Nextcloud will be accessible to Jellyfin for streaming. You need to create a Library name and add those into it.<\/p>\n\n\n\n<p>Jellyfin has app for any device you can think of. Android Phone, Tablets, TVs, iOS, iPad OS, iPhone and everything else. You can sign in using the URL or LAN IP if that device is within your local network. You can certainly access Jellyfin Server via any browser too.<\/p>\n\n\n\n<p><strong>Configuring Nextcloud Mobile App for Auto Upload<\/strong><\/p>\n\n\n\n<p>We have already covered the same in one of our previous guides about Nextcloud here -&gt; <a href=\"https:\/\/lazytourer.com\/in\/how-to-install-setup-use-nextcloud-as-google-photo-alternative-for-local-backup\/\" target=\"_blank\" rel=\"noreferrer noopener\">Nextcloud Server as VM<\/a>. You can refer there for details and step by step instructions.<\/p>\n\n\n\n<p><strong>Configuring PhotoPrism<\/strong><\/p>\n\n\n\n<p>You can access it via web URL using any browser. Specially in Mobile. Log into it by using username &#8220;admin&#8221; and password as you have entered in that configuration file.<\/p>\n\n\n\n<p>On the left-hand side, click settings, then at the upper right tab menu, click services. That will open up a dialog box to enter your Nextcloud user account credential details. Click OK to add it for integration.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"650\" height=\"351\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/PP_01.jpg\" alt=\"\" class=\"wp-image-928\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/PP_01.jpg 650w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/PP_01-300x162.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/figure>\n\n\n\n<p>Now select the auto upload folder of yours and set interval to 1 hour and click ok to start building the Photo Prism database of your images.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"498\" height=\"297\" src=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/PP_02.jpg\" alt=\"\" class=\"wp-image-929\" srcset=\"https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/PP_02.jpg 498w, https:\/\/lazytourer.com\/in\/wp-content\/uploads\/2023\/01\/PP_02-300x179.jpg 300w\" sizes=\"auto, (max-width: 498px) 100vw, 498px\" \/><\/figure>\n\n\n\n<p><strong>Install PhotoPrism Mobile Web App for Gallery Viewing<\/strong><\/p>\n\n\n\n<p>Here is the simple guide by Photo Prism team on how to easily install their viewing \/ Galley web app in your mobile (iOS \/ Android) -&gt; <a href=\"https:\/\/docs.photoprism.app\/user-guide\/pwa\/\" rel=\"noopener\">Mobile App (PWA) &#8211; PhotoPrism<\/a><\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-cyan-blue-background-color has-text-color has-background has-large-font-size\"><strong>Afterthoughts<\/strong><\/p>\n\n\n\n<p>Setup is now active and running in headless mode. That means you don&#8217;t have to use any more CLI and just keep using it via browser and apps. However, there are some things you should know about this particular setup of mine.<\/p>\n\n\n\n<p><strong>Great Performance &#8211; But it is old hardware<\/strong><\/p>\n\n\n\n<p>Users won&#8217;t even notice the age of the server hardware since at front end with browser access or via app access and movie streaming, performance is excellent. However, it is a very old hardware. In a server environment, number of active and simultaneous users matters. More there are, higher the processing power required. So, if in case number of users grow in my setup, this hardware won&#8217;t be enough. I have to get better CPU and more RAM. But for now, with handful of users, like me and my family members, this is sufficient. On the brighter side, I have just recycled and saved some E-Waste by making it useful and without throwing it to the landfill dustbin.<\/p>\n\n\n\n<p><strong>Backup needs backup too<\/strong><\/p>\n\n\n\n<p>Server may have older hardware but being a desktop, it is very easy to repair by simply replacing the failed part. But when it comes to your data, replacing the HDD won&#8217;t bring it back. So ideally speaking, data disks should always be in mirror RAID \/ parity setup. If one HDD fails, another will always have your data ready for use. My setup doesn&#8217;t have it yet. Planning to add 2 x 2TB HDDs in near future to increase the storage with redundancy.<\/p>\n\n\n\n<p><strong>Power Consumption<\/strong><\/p>\n\n\n\n<p>Although most of the time a home server stays idle, no heavy power-hungry CPU \/ GPU usage but being such old hardware, it is much higher than a newer CPU\/GPU setup. This Q6600 based setup is consuming around Rs. 350-400\/- per month of electricity for 24&#215;7 operation. If you are using some modern hardware, they can lower it much further since modern hardware is much more energy efficient.<\/p>\n\n\n\n<p class=\"has-text-align-center has-white-color has-vivid-red-background-color has-text-color has-background has-large-font-size\"><strong>Any Problem?<br>Feel free to Ask<\/strong><\/p>\n\n\n\n<p>If you have any questions, feel free to drop a comment below. We shall try our best to help out.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this guide, we will show you how to build a personal home cloud server&#8230;<\/p>\n","protected":false},"author":1,"featured_media":981,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[14],"tags":[],"class_list":["post-869","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/posts\/869","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/comments?post=869"}],"version-history":[{"count":80,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/posts\/869\/revisions"}],"predecessor-version":[{"id":1157,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/posts\/869\/revisions\/1157"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/media\/981"}],"wp:attachment":[{"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/media?parent=869"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/categories?post=869"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lazytourer.com\/in\/wp-json\/wp\/v2\/tags?post=869"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}