{"id":34281,"date":"2025-12-06T21:40:53","date_gmt":"2025-12-06T14:40:53","guid":{"rendered":"https:\/\/dps.media\/?p=34281"},"modified":"2025-12-06T21:40:55","modified_gmt":"2025-12-06T14:40:55","slug":"installation-guide-docker-portainer-on-fastpanel-using-reverse-proxy-ubuntu-24-04","status":"publish","type":"post","link":"https:\/\/dps.media\/en\/installation-guide-docker-portainer-on-fastpanel-using-reverse-proxy-ubuntu-24-04\/","title":{"rendered":"Installation Guide for Docker &amp; Portainer on Fastpanel using Reverse Proxy (Ubuntu 24.04)"},"content":{"rendered":"<?xml encoding=\"utf-8\" ?><p>If you are using <strong>Fastpanel<\/strong> to manage a VPS, you will find it great for PHP\/WordPress websites. However, if you want to run other modern applications (such as n8n, Nextcloud, Node.js\u2026) then <strong>Docker<\/strong> is the best solution.<\/p><p>The only issue is that Fastpanel has occupied ports 80 and 443. So how to access the Docker management interface (Portainer) using a standard SSL domain name (e.g.: <code>portainer.dps.media<\/code>) without typing <code>IP:9443<\/code>?<\/p><p>This article will guide you from A-Z on how to install Docker, Portainer and configure <strong>Reverse Proxy directly on Fastpanel<\/strong> (Native) on Ubuntu 24.04 platform.<\/p><hr class=\"wp-block-separator has-alpha-channel-opacity\"><h2 class=\"wp-block-heading\">Step 1: Install Docker on VPS<\/h2><p>First, you need to SSH into the VPS with <code>root<\/code> privileges and run the official Docker installation command.<\/p><p><strong>1. Update system:<\/strong><\/p><p>Bash<\/p><pre class=\"wp-block-code\"><code>apt update &amp;&amp; apt upgrade -y\n<\/code><\/pre><p><strong>2. Install Docker (Automatic script):<\/strong><\/p><p>Bash<\/p><pre class=\"wp-block-code\"><code>curl -fsSL https:\/\/get.docker.com -o get-docker.sh\nsh get-docker.sh\n<\/code><\/pre><p>After installation, you can check if Docker is running with the command <code>docker -v<\/code>.<\/p><hr class=\"wp-block-separator has-alpha-channel-opacity\"><h2 class=\"wp-block-heading\">Step 2: Install Portainer (Docker management interface)<\/h2><p>Instead of typing commands, we will install <strong>Portainer CE<\/strong> to manage containers through an intuitive web interface.<\/p><p><strong>1. Create data storage space (Volume):<\/strong><\/p><p>Bash<\/p><pre class=\"wp-block-code\"><code>docker volume create portainer_data\n<\/code><\/pre><p><strong>2. Run Portainer container:<\/strong><\/p><p>Bash<\/p><pre class=\"wp-block-code\"><code>docker run -d -p 8000:8000 -p 9443:9443 --name portainer --restart=always -v \/var\/run\/docker.sock:\/var\/run\/docker.sock -v portainer_data:\/data portainer\/portainer-ce:latest\n<\/code><\/pre><p>At this point, Portainer is running on port <code>9443<\/code> (HTTPS).<\/p><hr class=\"wp-block-separator has-alpha-channel-opacity\"><h2 class=\"wp-block-heading\">Step 3: Configure Reverse Proxy on Fastpanel<\/h2><p>This is the most important step to expose Portainer to the internet using your domain name.<\/p><ol start=\"1\" class=\"wp-block-list\">\n<li>Log in to <strong>Fastpanel<\/strong>.<\/li>\n\n\n\n<li>Click the <strong>\u201cCreate Site\u201d<\/strong> (Create website).<\/li>\n\n\n\n<li>Select website type as <strong>\u201cReverse Proxy\u201d<\/strong>.<\/li>\n\n\n\n<li>Fill in the information:\n<ul class=\"wp-block-list\">\n<li><strong>Domain:<\/strong> Enter your subdomain (e.g.: <code>ptn266.dpsmedia.vn<\/code>).<\/li>\n\n\n\n<li><strong>Upstream address (Target):<\/strong> Enter <code>https:\/\/127.0.0.1:9443<\/code><\/li>\n\n\n\n<li><em>Note: Must have <code>https:\/\/<\/code> because Portainer runs securely by default.<\/em><\/li>\n<\/ul>\n<\/li>\n<\/ol><h3 class=\"wp-block-heading\">\u26a0\ufe0f Important Note (Do not skip)<\/h3><p>After creating the site, the Portainer interface may have display errors (white page or missing icons). You need to fix it as follows:<\/p><ol start=\"1\" class=\"wp-block-list\">\n<li>Go to the settings of the newly created site (Settings).<\/li>\n\n\n\n<li>Find the section <strong>\u201cStatic Content\u201d<\/strong>.<\/li>\n\n\n\n<li><strong>TURN OFF<\/strong> (Disable) the line: <strong>\u201cUse NGINX for static files\u201d<\/strong>.\n<ul class=\"wp-block-list\">\n<li><em>Reason: Fastpanel by default will look for images\/css on the server hard drive instead of fetching from the Docker container, so we need to disable it so that all requests go through Docker.<\/em><\/li>\n<\/ul>\n<\/li>\n<\/ol><p>After that, go to the section <strong>SSL Certificates<\/strong> and install free Let's Encrypt SSL as usual.<\/p><hr class=\"wp-block-separator has-alpha-channel-opacity\"><h2 class=\"wp-block-heading\">Step 4: Fixing \u201cInstance timed out\u201d error (If encountered)<\/h2><p>When accessing the domain name for the first time, if you see the message:<\/p><blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p><em>\u201cYour Portainer instance timed out for security purposes\u2026\u201d<\/em><\/p>\n<\/blockquote><p>Don't worry, this is a Portainer security feature if you don't create an Admin account within 5 minutes after installation.<\/p><p><strong>How to fix:<\/strong> Go back to SSH and run the restart command:<\/p><p>Bash<\/p><pre class=\"wp-block-code\"><code>docker restart portainer\n<\/code><\/pre><p>Then immediately F5 the browser and create an Admin account.<\/p><hr class=\"wp-block-separator has-alpha-channel-opacity\"><h2 class=\"wp-block-heading\">Conclusion<\/h2><p>Done! Now you have a powerful system <strong>Fastpanel<\/strong> that can run traditional web as well as the ecosystem <strong>Docker<\/strong> through the interface <strong>Portainer<\/strong> extremely professional.<\/p><p><strong>Advantages of this method:<\/strong><\/p><ul class=\"wp-block-list\">\n<li>No need to install additional Nginx Proxy Manager (since Fastpanel has handled it).<\/li>\n\n\n\n<li>Utilize Fastpanel's free SSL certificates.<\/li>\n\n\n\n<li>More secure because no need to open port 9443 outside the firewall.<\/li>\n<\/ul><p>Wish you success! If you have any questions, please leave a comment below.<\/p><hr class=\"wp-block-separator has-alpha-channel-opacity\"><p><em>Source: Compiled from real practical experience from <a class=\"wpil_keyword_link\" href=\"https:\/\/dps.media\/en\/\" title=\"DPS.MEDIA JSC\" data-wpil-keyword-link=\"linked\" data-wpil-monitor-id=\"587\">dps.media<\/a><\/em><\/p>\n<style>\r\n.lwrp.link-whisper-related-posts{\r\n            \r\n            margin-top: 40px;\nmargin-bottom: 30px;\r\n        }\r\n        .lwrp .lwrp-title{\r\n            \r\n            \r\n        }.lwrp .lwrp-description{\r\n            \r\n            \r\n\r\n        }\r\n        .lwrp .lwrp-list-container{\r\n        }\r\n        .lwrp .lwrp-list-multi-container{\r\n            display: flex;\r\n        }\r\n        .lwrp .lwrp-list-double{\r\n            width: 48%;\r\n        }\r\n        .lwrp .lwrp-list-triple{\r\n            width: 32%;\r\n        }\r\n        .lwrp .lwrp-list-row-container{\r\n            display: flex;\r\n            justify-content: space-between;\r\n        }\r\n        .lwrp .lwrp-list-row-container .lwrp-list-item{\r\n            width: calc(33% - 20px);\r\n        }\r\n        .lwrp .lwrp-list-item:not(.lwrp-no-posts-message-item){\r\n            \r\n            max-width: 150px;\r\n        }\r\n        .lwrp .lwrp-list-item img{\r\n            max-width: 100%;\r\n            height: auto;\r\n            object-fit: cover;\r\n            aspect-ratio: 1 \/ 1;\r\n        }\r\n        .lwrp .lwrp-list-item.lwrp-empty-list-item{\r\n            background: initial !important;\r\n        }\r\n        .lwrp .lwrp-list-item .lwrp-list-link .lwrp-list-link-title-text,\r\n        .lwrp .lwrp-list-item .lwrp-list-no-posts-message{\r\n            \r\n            \r\n            \r\n            \r\n        }@media screen and (max-width: 480px) {\r\n            .lwrp.link-whisper-related-posts{\r\n                \r\n                \r\n            }\r\n            .lwrp .lwrp-title{\r\n                \r\n                \r\n            }.lwrp .lwrp-description{\r\n                \r\n                \r\n            }\r\n            .lwrp .lwrp-list-multi-container{\r\n                flex-direction: column;\r\n            }\r\n            .lwrp .lwrp-list-multi-container ul.lwrp-list{\r\n                margin-top: 0px;\r\n                margin-bottom: 0px;\r\n                padding-top: 0px;\r\n                padding-bottom: 0px;\r\n            }\r\n            .lwrp .lwrp-list-double,\r\n            .lwrp .lwrp-list-triple{\r\n                width: 100%;\r\n            }\r\n            .lwrp .lwrp-list-row-container{\r\n                justify-content: initial;\r\n                flex-direction: column;\r\n            }\r\n            .lwrp .lwrp-list-row-container .lwrp-list-item{\r\n                width: 100%;\r\n            }\r\n            .lwrp .lwrp-list-item:not(.lwrp-no-posts-message-item){\r\n                \r\n                max-width: initial;\r\n            }\r\n            .lwrp .lwrp-list-item .lwrp-list-link .lwrp-list-link-title-text,\r\n            .lwrp .lwrp-list-item .lwrp-list-no-posts-message{\r\n                \r\n                \r\n                \r\n                \r\n            };\r\n        }<\/style>\r\n<div id=\"link-whisper-related-posts-widget\" class=\"link-whisper-related-posts lwrp\">\r\n            <div class=\"lwrp-title\">Related Posts<\/div>    \r\n        <div class=\"lwrp-list-container\">\r\n                                <div class=\"lwrp-list lwrp-list-row-container lwrp-list-double-row\">\r\n                <div class=\"lwrp-list-item\"><a href=\"https:\/\/dps.media\/en\/the-magical-power-of-the-integrated-media-advertising-company\/\" class=\"lwrp-list-link\"><span class=\"lwrp-list-link-title-text\">The \u201cMagical\u201d Power of a Comprehensive Advertising and Media Company<\/span><\/a><\/div><div class=\"lwrp-list-item\"><a href=\"https:\/\/dps.media\/en\/29381-2\/\" class=\"lwrp-list-link\"><span class=\"lwrp-list-link-title-text\"><\/span><\/a><\/div><div class=\"lwrp-list-item\"><a href=\"https:\/\/dps.media\/en\/announcement-of-the-2025-lunar-new-year-holiday-schedule\/\" class=\"lwrp-list-link\"><span class=\"lwrp-list-link-title-text\">2025 Lunar New Year Holiday Announcement<\/span><\/a><\/div>                <\/div>\r\n                            <div class=\"lwrp-list lwrp-list-row-container lwrp-list-double-row\">\r\n                <div class=\"lwrp-list-item\"><a href=\"https:\/\/dps.media\/en\/types-of-layouts-in-graphic-design\/\" class=\"lwrp-list-link\"><span class=\"lwrp-list-link-title-text\">Types of Layouts in Graphic Design<\/span><\/a><\/div><div class=\"lwrp-list-item\"><a href=\"https:\/\/dps.media\/en\/check-qr-code-agribank-and-create-qr-code-for-free-with-gratis-generator\/\" class=\"lwrp-list-link\"><span class=\"lwrp-list-link-title-text\">Check Agribank QR Code and create free QR Code with Generator Gratis<\/span><\/a><\/div><div class=\"lwrp-list-item\"><a href=\"https:\/\/dps.media\/en\/free-catalog-design-software-that-creates-beautiful-catalogs-without-any-cost\/\" class=\"lwrp-list-link\"><span class=\"lwrp-list-link-title-text\">Free catalogue design software \u2013 Create beautiful catalogues without any cost<\/span><\/a><\/div>                <\/div>\r\n                <\/div>\r\n<\/div>","protected":false},"excerpt":{"rendered":"<p>N\u1ebfu b\u1ea1n \u0111ang s\u1eed d\u1ee5ng Fastpanel \u0111\u1ec3 qu\u1ea3n l\u00fd VPS, b\u1ea1n s\u1ebd th\u1ea5y n\u00f3 r\u1ea5t tuy\u1ec7t v\u1eddi cho c\u00e1c website PHP\/WordPress. Tuy nhi\u00ean, n\u1ebfu b\u1ea1n mu\u1ed1n ch\u1ea1y th\u00eam c\u00e1c \u1ee9ng d\u1ee5ng hi\u1ec7n \u0111\u1ea1i kh\u00e1c (nh\u01b0 n8n, Nextcloud, Node.js\u2026) th\u00ec Docker l\u00e0 gi\u1ea3i ph\u00e1p t\u1ed1t nh\u1ea5t.V\u1ea5n \u0111\u1ec1 duy nh\u1ea5t l\u00e0 Fastpanel \u0111\u00e3 chi\u1ebfm d\u1ee5ng c\u1ed5ng 80 [&hellip;]<\/p>","protected":false},"author":1,"featured_media":34282,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1,1621],"tags":[],"class_list":["post-34281","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","category-fastpanel"],"acf":[],"rankmath_keywords":{"primary":"","secondary":[""]},"yoast_keywords":{"primary":"","secondary":[]},"yoast_focuskw":"","rankmath_focuskw":"","seo_keywords":{"primary":"","secondary":[""]},"_links":{"self":[{"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/posts\/34281","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/comments?post=34281"}],"version-history":[{"count":2,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/posts\/34281\/revisions"}],"predecessor-version":[{"id":34284,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/posts\/34281\/revisions\/34284"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/media\/34282"}],"wp:attachment":[{"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/media?parent=34281"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/categories?post=34281"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dps.media\/en\/wp-json\/wp\/v2\/tags?post=34281"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}