{"id":323,"date":"2025-12-30T21:45:22","date_gmt":"2025-12-30T13:45:22","guid":{"rendered":"https:\/\/www.985369.xyz\/?p=323"},"modified":"2025-12-31T00:14:36","modified_gmt":"2025-12-30T16:14:36","slug":"linux-vps-docker%e9%83%a8%e7%bd%b2s-ui%e5%ae%8c%e6%95%b4%e6%80%bb%e7%bb%93%ef%bc%88%e5%90%ab%e6%93%8d%e4%bd%9c%e6%ad%a5%e9%aa%a4%e3%80%81%e5%bc%af%e8%b7%af%e5%a4%8d%e7%9b%98%e3%80%81%e6%9c%80%e7%bb%88","status":"publish","type":"post","link":"https:\/\/www.985369.xyz\/index.php\/2025\/12\/30\/linux-vps-docker%e9%83%a8%e7%bd%b2s-ui%e5%ae%8c%e6%95%b4%e6%80%bb%e7%bb%93%ef%bc%88%e5%90%ab%e6%93%8d%e4%bd%9c%e6%ad%a5%e9%aa%a4%e3%80%81%e5%bc%af%e8%b7%af%e5%a4%8d%e7%9b%98%e3%80%81%e6%9c%80%e7%bb%88\/","title":{"rendered":"Linux VPS Docker\u90e8\u7f72S-UI\u5b8c\u6574\u603b\u7ed3\uff08\u542b\u64cd\u4f5c\u6b65\u9aa4\u3001\u5f2f\u8def\u590d\u76d8\u3001\u6700\u7ec8\u89e3\u51b3\u65b9\u6848\uff09"},"content":{"rendered":"<p><!DOCTYPE html><br \/>\n<html lang=\"zh-CN\"><br \/>\n<head><br \/>\n    <meta charset=\"UTF-8\"><br \/>\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"><br \/>\n    <title>Linux VPS Docker\u90e8\u7f72S-UI\u5b8c\u6574\u603b\u7ed3\uff08\u542b\u8e29\u5751\u590d\u76d8\uff09<\/title><\/p>\n<style>\n        \/* \u5168\u5c40\u6837\u5f0f\u91cd\u7f6e *\/\n        * {\n            margin: 0;\n            padding: 0;\n            box-sizing: border-box;\n        }<\/p>\n<p>        \/* \u5168\u5c40\u57fa\u7840\u6837\u5f0f *\/\n        body {\n            font-family: \"Microsoft YaHei\", \"Helvetica Neue\", Helvetica, Arial, sans-serif;\n            background-color: #f5f7fa;\n            color: #333;\n            line-height: 1.8;\n            padding: 20px;\n            max-width: 1200px;\n            margin: 0 auto;\n        }<\/p>\n<p>        \/* \u6807\u9898\u6837\u5f0f *\/\n        h1 {\n            color: #2c3e50;\n            text-align: center;\n            margin: 30px 0 40px;\n            font-size: 28px;\n            border-bottom: 3px solid #3498db;\n            padding-bottom: 15px;\n        }<\/p>\n<p>        h2 {\n            color: #2980b9;\n            margin: 35px 0 20px;\n            font-size: 22px;\n            padding-left: 10px;\n            border-left: 4px solid #3498db;\n        }<\/p>\n<p>        h3 {\n            color: #34495e;\n            margin: 30px 0 15px;\n            font-size: 18px;\n        }<\/p>\n<p>        \/* \u6bb5\u843d\u4e0e\u5217\u8868\u6837\u5f0f *\/\n        p {\n            margin: 15px 0;\n            font-size: 16px;\n            text-align: justify;\n        }<\/p>\n<p>        ul, ol {\n            margin: 15px 0 15px 30px;\n            font-size: 16px;\n        }<\/p>\n<p>        li {\n            margin: 10px 0;\n        }<\/p>\n<p>        \/* \u547d\u4ee4\u884c\u4ee3\u7801\u6837\u5f0f\uff08\u6838\u5fc3\u9ad8\u4eae\uff09 *\/\n        .code-block {\n            background-color: #2d2d2d;\n            color: #f8f8f2;\n            padding: 20px;\n            margin: 20px 0;\n            border-radius: 8px;\n            overflow-x: auto;\n            font-family: \"Consolas\", \"Monaco\", \"Courier New\", monospace;\n            font-size: 14px;\n            line-height: 1.6;\n        }<\/p>\n<p>        .code-block span.comment {\n            color: #75715e;\n        }<\/p>\n<p>        .code-block span.command {\n            color: #66d9ef;\n        }<\/p>\n<p>        .code-block span.path {\n            color: #a6e22e;\n        }<\/p>\n<p>        \/* \u5f2f\u8def\u590d\u76d8\u6837\u5f0f *\/\n        .pitfall {\n            background-color: #fff8e1;\n            border-left: 4px solid #ffc107;\n            padding: 15px 20px;\n            margin: 20px 0;\n            border-radius: 0 8px 8px 0;\n        }<\/p>\n<p>        .pitfall h4 {\n            color: #e65100;\n            margin-bottom: 10px;\n            font-size: 16px;\n        }<\/p>\n<p>        \/* \u6700\u7ec8\u7ed3\u8bba\u6837\u5f0f *\/\n        .conclusion {\n            background-color: #e8f5e9;\n            border: 1px solid #c8e6c9;\n            padding: 20px;\n            margin: 30px 0;\n            border-radius: 8px;\n        }<\/p>\n<p>        .conclusion h4 {\n            color: #2e7d32;\n            margin-bottom: 15px;\n            font-size: 18px;\n        }<\/p>\n<p>        \/* \u54cd\u5e94\u5f0f\u9002\u914d *\/\n        @media (max-width: 768px) {\n            body {\n                padding: 15px;\n            }<\/p>\n<p>            h1 {\n                font-size: 24px;\n            }<\/p>\n<p>            h2 {\n                font-size: 20px;\n            }<\/p>\n<p>            h3 {\n                font-size: 16px;\n            }<\/p>\n<p>            .code-block {\n                padding: 15px;\n                font-size: 13px;\n            }\n        }\n    <\/style>\n<p><\/head><br \/>\n<body><\/p>\n<h1>Linux VPS Docker\u90e8\u7f72S-UI\u5b8c\u6574\u603b\u7ed3\uff08\u542b\u64cd\u4f5c\u6b65\u9aa4\u3001\u5f2f\u8def\u590d\u76d8\u3001\u6700\u7ec8\u89e3\u51b3\u65b9\u6848\uff09<\/h1>\n<h2>\u4e00\u3001\u6574\u4f53\u80cc\u666f<\/h2>\n<p>\u672c\u6b21\u76ee\u6807\uff1a\u5728Linux VPS\u4e0a\u901a\u8fc7Docker\u90e8\u7f72<code>alireza7\/s-ui<\/code>\u955c\u50cf\uff0c\u5b9e\u73b0\u5916\u90e8\u6d4f\u89c8\u5668\u53ef\u8bbf\u95eeS-UI\u9762\u677f\uff0c\u7528\u4e8e\u540e\u7eed\u76f8\u5173\u914d\u7f6e\u7ba1\u7406\u3002<\/p>\n<p>\u6838\u5fc3\u73af\u5883\uff1aLinux VPS\uff08root\u6743\u9650\uff09\u3001Docker\u5df2\u9884\u88c5\u3001\u73b0\u6709\u7f51\u7ad9\u5360\u752880\u7aef\u53e3\u3002<\/p>\n<h2>\u4e8c\u3001\u5b8c\u6574\u64cd\u4f5c\u6b65\u9aa4\uff08\u53ef\u76f4\u63a5\u590d\u73b0\uff0c\u4e00\u6b65\u4e00\u547d\u4ee4\uff09<\/h2>\n<h3>\u6b65\u9aa41\uff1a\u524d\u671f\u73af\u5883\u51c6\u5907\uff08\u521b\u5efa\u5de5\u4f5c\u76ee\u5f55\uff09<\/h3>\n<div class=\"code-block\">\n        <span class=\"comment\"># 1. \u521b\u5efaS-UI\u5de5\u4f5c\u76ee\u5f55\u5e76\u8fdb\u5165<\/span><br \/>\n        <span class=\"command\">mkdir -p ~\/s-ui &#038;&#038; cd ~\/s-ui<\/span><\/p>\n<p>        <span class=\"comment\"># 2. \u521b\u5efa\u6570\u636e\u5377\u76ee\u5f55\uff08\u7528\u4e8e\u6301\u4e45\u5316S-UI\u914d\u7f6e\/\u6570\u636e\u5e93\uff09<\/span><br \/>\n        <span class=\"command\">mkdir -p s-ui-db &#038;&#038; chmod 777 s-ui-db<\/span>\n    <\/div>\n<h3>\u6b65\u9aa42\uff1a\u9996\u6b21\u90e8\u7f72S-UI\u5bb9\u5668\uff08\u521d\u59cb\u7aef\u53e32095\uff09<\/h3>\n<div class=\"code-block\">\n        <span class=\"comment\"># \u542f\u52a8S-UI\u5bb9\u5668\uff0c\u6620\u5c04VPS 2095\u7aef\u53e3\u2192\u5bb9\u56682095\u7aef\u53e3\uff0c\u6302\u8f7d\u6570\u636e\u5377<\/span><br \/>\n        <span class=\"command\">docker run -d \\<\/span><br \/>\n        <span class=\"command\">  &#8211;name s-ui \\<\/span><br \/>\n        <span class=\"command\">  &#8211;restart unless-stopped \\<\/span><br \/>\n        <span class=\"command\">  -p 2095:2095 \\<\/span><br \/>\n        <span class=\"command\">  -p 2096:2096 \\<\/span><br \/>\n        <span class=\"command\">  -v $(pwd)\/s-ui-db:\/app\/db \\<\/span><br \/>\n        <span class=\"command\">  alireza7\/s-ui<\/span>\n    <\/div>\n<h3>\u6b65\u9aa43\uff1a\u914d\u7f6e\u672c\u5730\u9632\u706b\u5899\uff08\u5148iptables\uff0c\u540e\u5b89\u88c5ufw\uff09<\/h3>\n<h4>3.1 \u521d\u59cbiptables\u653e\u884c\u7aef\u53e3<\/h4>\n<div class=\"code-block\">\n        <span class=\"comment\"># \u653e\u884c2095\u30012096\u7aef\u53e3\uff08TCP\u534f\u8bae\uff09<\/span><br \/>\n        <span class=\"command\">iptables -A INPUT -p tcp &#8211;dport 2095 -j ACCEPT<\/span><br \/>\n        <span class=\"command\">iptables -A INPUT -p tcp &#8211;dport 2096 -j ACCEPT<\/span><\/p>\n<p>        <span class=\"comment\"># \u521b\u5efaiptables\u89c4\u5219\u4fdd\u5b58\u76ee\u5f55\uff0c\u4fdd\u5b58\u89c4\u5219<\/span><br \/>\n        <span class=\"command\">mkdir -p \/etc\/iptables<\/span><br \/>\n        <span class=\"command\">iptables-save > \/etc\/iptables\/rules.v4<\/span>\n    <\/div>\n<h4>3.2 \u540e\u7eed\u5b89\u88c5ufw\u9632\u706b\u5899\uff08\u515c\u5e95\u9632\u62a4\uff0c\u66f4\u6613\u7528\uff09<\/h4>\n<div class=\"code-block\">\n        <span class=\"comment\"># 1. \u5b89\u88c5ufw<\/span><br \/>\n        <span class=\"command\">apt update &#038;&#038; apt install -y ufw<\/span><\/p>\n<p>        <span class=\"comment\"># 2. \u542f\u7528ufw\uff0c\u9ed8\u8ba4\u89c4\u5219\uff08\u62d2\u7edd\u5165\u7ad9\uff0c\u5141\u8bb8\u51fa\u7ad9\uff09<\/span><br \/>\n        <span class=\"command\">ufw enable<\/span><br \/>\n        <span class=\"command\">ufw default deny incoming<\/span><br \/>\n        <span class=\"command\">ufw default allow outgoing<\/span><\/p>\n<p>        <span class=\"comment\"># 3. \u653e\u884c\u6838\u5fc3\u7aef\u53e3\uff08SSH 22\u5fc5\u653e\uff0c\u907f\u514d\u65ad\u8fde\uff1b\u540e\u7eed\u7aef\u53e3\u540c\u6b65\u653e\u884c\uff09<\/span><br \/>\n        <span class=\"command\">ufw allow 22\/tcp<\/span><br \/>\n        <span class=\"command\">ufw allow 2095\/tcp<\/span><br \/>\n        <span class=\"command\">ufw allow 2096\/tcp<\/span><br \/>\n        <span class=\"command\">ufw allow 8888\/tcp<\/span><br \/>\n        <span class=\"command\">ufw allow 8090\/tcp<\/span><br \/>\n        <span class=\"command\">ufw allow 80\/tcp<\/span><span class=\"comment\">\uff08\u73b0\u6709\u7f51\u7ad9\uff0c\u65e0\u9700\u5220\u9664\uff09<\/span><\/p>\n<p>        <span class=\"comment\"># 4. \u91cd\u8f7dufw\uff0c\u67e5\u770b\u89c4\u5219\u72b6\u6001<\/span><br \/>\n        <span class=\"command\">ufw reload<\/span><br \/>\n        <span class=\"command\">ufw status numbered<\/span>\n    <\/div>\n<h3>\u6b65\u9aa44\uff1a\u66f4\u6362\u6620\u5c04\u7aef\u53e3\uff08\u89c4\u907f\u9690\u6027\u5c4f\u853d\uff0c\u5c1d\u8bd58888\u21928090\uff09<\/h3>\n<div class=\"code-block\">\n        <span class=\"comment\"># 1. \u505c\u6b62\u5e76\u5220\u9664\u73b0\u6709s-ui\u5bb9\u5668\uff08\u7aef\u53e3\u66f4\u6362\u9700\u91cd\u5efa\u5bb9\u5668\uff09<\/span><br \/>\n        <span class=\"command\">docker rm -f s-ui<\/span><\/p>\n<p>        <span class=\"comment\"># 2. \u91cd\u5efa\u5bb9\u5668\uff0c\u6620\u5c04VPS 8888\u7aef\u53e3\u2192\u5bb9\u56682095\u7aef\u53e3<\/span><br \/>\n        <span class=\"command\">docker run -d \\<\/span><br \/>\n        <span class=\"command\">  &#8211;name s-ui \\<\/span><br \/>\n        <span class=\"command\">  &#8211;restart unless-stopped \\<\/span><br \/>\n        <span class=\"command\">  -p 8888:2095 \\<\/span><br \/>\n        <span class=\"command\">  -p 2096:2096 \\<\/span><br \/>\n        <span class=\"command\">  -v $(pwd)\/s-ui-db:\/app\/db \\<\/span><br \/>\n        <span class=\"command\">  alireza7\/s-ui<\/span><\/p>\n<p>        <span class=\"comment\"># 3. \uff08\u540e\u7eed\u66f4\u63628090\u7aef\u53e3\uff0c\u91cd\u590d\u4e0a\u8ff0\u6b65\u9aa4\uff0c\u4ec5\u4fee\u6539\u6620\u5c04\u7aef\u53e3\uff09<\/span><br \/>\n        <span class=\"command\">docker rm -f s-ui<\/span><br \/>\n        <span class=\"command\">docker run -d \\<\/span><br \/>\n        <span class=\"command\">  &#8211;name s-ui \\<\/span><br \/>\n        <span class=\"command\">  &#8211;restart unless-stopped \\<\/span><br \/>\n        <span class=\"command\">  -p 8090:2095 \\<\/span><br \/>\n        <span class=\"command\">  -p 2096:2096 \\<\/span><br \/>\n        <span class=\"command\">  -v $(pwd)\/s-ui-db:\/app\/db \\<\/span><br \/>\n        <span class=\"command\">  alireza7\/s-ui<\/span>\n    <\/div>\n<h3>\u6b65\u9aa45\uff1a\u914d\u7f6e\u670d\u52a1\u5546\u5b89\u5168\u7ec4\uff08\u5173\u952e\u5916\u90e8\u901a\u8def\uff09<\/h3>\n<ol>\n<li>\u767b\u5f55VPS\u670d\u52a1\u5546\u63a7\u5236\u53f0\uff0c\u627e\u5230\u5bf9\u5e94VPS\u7684\u300c\u5b89\u5168\u7ec4\/\u9632\u706b\u5899\u300d\u914d\u7f6e\uff1b<\/li>\n<li>\u65b0\u589e\u300c\u5165\u7ad9\u89c4\u5219\u300d\uff0c\u4f9d\u6b21\u653e\u884c\u7aef\u53e3\uff1a2095\u30018888\u30018090\u30012096\uff08\u534f\u8bae\u5747\u4e3aTCP\uff0c\u6388\u6743\u5bf9\u8c61<code>0.0.0.0\/0<\/code>\uff0c\u89c4\u5219\u542f\u7528\uff09\uff1b<\/li>\n<li>\u4fdd\u5b58\u89c4\u5219\uff0c\u7b49\u5f851-3\u5206\u949f\u751f\u6548\uff08\u65e0\u9700\u91cd\u542fVPS\/\u5bb9\u5668\uff09\u3002<\/li>\n<\/ol>\n<h3>\u6b65\u9aa46\uff1a\u9a8c\u8bc1\u5bb9\u5668\u7aef\u53e3\u6620\u5c04\uff08\u786e\u8ba4\u6620\u5c04\u6b63\u5e38\uff09<\/h3>\n<div class=\"code-block\">\n        <span class=\"comment\"># 1. \u67e5\u770b\u6307\u5b9as-ui\u5bb9\u5668\u7aef\u53e3\u6620\u5c04<\/span><br \/>\n        <span class=\"command\">docker port s-ui<\/span><\/p>\n<p>        <span class=\"comment\"># 2. \u67e5\u770b\u6240\u6709\u8fd0\u884c\u4e2d\u5bb9\u5668\u7aef\u53e3\u6620\u5c04\uff08\u5168\u5c40\u9a8c\u8bc1\uff09<\/span><br \/>\n        <span class=\"command\">docker ps &#8211;format &#8220;table {{.Names}}\\t{{.Ports}}&#8221;<\/span><\/p>\n<p>        <span class=\"comment\"># 3. \u67e5\u770b\u672c\u5730\u7aef\u53e3\u76d1\u542c\u72b6\u6001\uff08\u786e\u8ba4docker-proxy\u8fdb\u7a0b\u6b63\u5e38\uff09<\/span><br \/>\n        <span class=\"command\">ss -tulpn | grep -E &#8220;8090|8888|2095&#8221;<\/span>\n    <\/div>\n<h3>\u6b65\u9aa47\uff1a\u6392\u67e5\u8bbf\u95ee\u8def\u5f84\uff08\u6700\u7ec8\u627e\u5230\u6709\u6548\u8def\u5f84\uff09<\/h3>\n<div class=\"code-block\">\n        <span class=\"comment\"># 1. \u672c\u5730curl\u9a8c\u8bc1\u94fe\u8def\u901a\u7545\uff08\u67e5\u770b\u670d\u52a1\u54cd\u5e94\uff09<\/span><br \/>\n        <span class=\"command\">curl -v http:\/\/127.0.0.1:8090<\/span><\/p>\n<p>        <span class=\"comment\"># 2. \u8fdb\u5165\u5bb9\u5668\u5185\u90e8\uff0c\u67e5\u627e\u53ef\u80fd\u7684\u8bbf\u95ee\u8def\u5f84\uff08\u867d\u672a\u627e\u5230\u9759\u6001\u6587\u4ef6\uff0c\u4f46\u9a8c\u8bc1\u670d\u52a1\u7c7b\u578b\uff09<\/span><br \/>\n        <span class=\"command\">docker exec -it s-ui \/bin\/sh<\/span><br \/>\n        <span class=\"command\">find \/ -name &#8220;*login*&#8221; -o -name &#8220;*index*&#8221; -o -name &#8220;*html*&#8221;<\/span><br \/>\n        <span class=\"command\">exit<\/span><span class=\"comment\">\uff08\u9000\u51fa\u5bb9\u5668\uff09<\/span>\n    <\/div>\n<h3>\u6b65\u9aa48\uff1a\u6700\u7ec8\u6210\u529f\u8bbf\u95ee\uff08\u5916\u90e8\u6d4f\u89c8\u5668\u9a8c\u8bc1\uff09<\/h3>\n<ol>\n<li>\u6d4f\u89c8\u5668\u5f00\u542f\u300c\u65e0\u75d5\u6a21\u5f0f\u300d\uff08Chrome\/Edge\uff1a<code>Ctrl+Shift+N<\/code>\uff09\uff1b<\/li>\n<li>\u8f93\u5165\u5b8c\u6574\u8bbf\u95ee\u5730\u5740\uff1a<code>http:\/\/213.210.5.42:8090\/app\/<\/code>\uff1b<\/li>\n<li>\u6309<code>Ctrl+F5<\/code>\u5f3a\u5236\u5237\u65b02-3\u6b21\uff0c\u4f18\u5148\u4f7f\u7528\u624b\u673a\u6d41\u91cf\u8bbf\u95ee\uff08\u907f\u5f00\u8def\u7531\u5668\u62e6\u622a\uff09\uff1b<\/li>\n<li>\u6210\u529f\u8fdb\u5165S-UI\u9762\u677f\uff0c\u5b8c\u6210\u90e8\u7f72\u76ee\u6807\u3002<\/li>\n<\/ol>\n<h3>\u6b65\u9aa49\uff1a\uff08\u53ef\u9009\uff09\u73af\u5883\u6e05\u7406\uff08\u82e5\u9700\u91cd\u65b0\u90e8\u7f72\uff09<\/h3>\n<div class=\"code-block\">\n        <span class=\"comment\"># 1. \u5f3a\u5236\u5220\u9664s-ui\u5bb9\u5668<\/span><br \/>\n        <span class=\"command\">docker rm -f s-ui<\/span><\/p>\n<p>        <span class=\"comment\"># 2. \u5f7b\u5e95\u5220\u9664S-UI\u5de5\u4f5c\u76ee\u5f55\uff08\u542b\u914d\u7f6e\/\u6570\u636e\u5377\uff09<\/span><br \/>\n        <span class=\"command\">rm -rf ~\/s-ui<\/span><\/p>\n<p>        <span class=\"comment\"># 3. \uff08\u53ef\u9009\uff09\u5220\u9664ufw\u5bf9\u5e94\u7aef\u53e3\u89c4\u5219\uff08\u5148\u67e5\u7f16\u53f7\uff0c\u518d\u5220\u9664\uff09<\/span><br \/>\n        <span class=\"command\">ufw status numbered<\/span><br \/>\n        <span class=\"command\">ufw delete \u5bf9\u5e94\u89c4\u5219\u7f16\u53f7<\/span>\n    <\/div>\n<h2>\u4e09\u3001\u6838\u5fc3\u5f2f\u8def\u590d\u76d8\uff08\u8e29\u5751\u70b9+\u539f\u56e0\u5206\u6790+\u89e3\u51b3\u65b9\u6848\uff09<\/h2>\n<div class=\"pitfall\">\n<h4>\u5f2f\u8def1\uff1a\u521d\u671f\u4ec5\u914d\u7f6e\u672c\u5730iptables\uff0c\u5ffd\u7565\u670d\u52a1\u5546\u5b89\u5168\u7ec4\uff08\u5916\u90e8\u8bf7\u6c42\u65e0\u6cd5\u5230\u8fbeVPS\uff09<\/h4>\n<p><strong>\u8868\u73b0<\/strong>\uff1a\u5bb9\u5668\u8fd0\u884c\u6b63\u5e38\u3001\u672c\u5730\u7aef\u53e3\u76d1\u542c\u6b63\u5e38\uff0c\u5916\u90e8\u6d4f\u89c8\u5668\u8bbf\u95ee\u8d85\u65f6\/\u65e0\u6cd5\u8fde\u63a5\uff0c\u5728\u7ebf\u7aef\u53e3\u626b\u63cf\u663e\u793a\u7aef\u53e3\u5173\u95ed\uff1b<\/p>\n<p><strong>\u539f\u56e0<\/strong>\uff1a\u670d\u52a1\u5546\u5b89\u5168\u7ec4\u662f\u300c\u5916\u90e8\u7f51\u7edc\u7b2c\u4e00\u9053\u9632\u706b\u5899\u300d\uff0c\u4f18\u5148\u7ea7\u9ad8\u4e8eVPS\u672c\u5730\u9632\u706b\u5899\uff0c\u672a\u653e\u884c\u5bf9\u5e94\u7aef\u53e3\u65f6\uff0c\u5916\u90e8\u8bf7\u6c42\u6839\u672c\u65e0\u6cd5\u5230\u8fbeVPS\uff1b<\/p>\n<p><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u672c\u5730\u9632\u706b\u5899\uff08iptables\/ufw\uff09\u653e\u884c\u7aef\u53e3\u540e\uff0c\u5fc5\u987b\u540c\u6b65\u5728\u670d\u52a1\u5546\u63a7\u5236\u53f0\u914d\u7f6e\u5b89\u5168\u7ec4\u5165\u7ad9\u89c4\u5219\uff0c\u653e\u884c\u76f8\u540c\u7aef\u53e3\uff08TCP\u534f\u8bae\uff09\u3002<\/p>\n<\/p><\/div>\n<div class=\"pitfall\">\n<h4>\u5f2f\u8def2\uff1a\u6267\u7740\u4e8e\u6839\u8def\u5f84<code>\/<\/code>\u8bbf\u95ee\uff0c\u672a\u610f\u8bc6\u5230S-UI\u6709\u6307\u5b9a\u9762\u677f\u8def\u5f84\uff08\u8fd4\u56de404\u8bef\u4ee5\u4e3a\u670d\u52a1\u6545\u969c\uff09<\/h4>\n<p><strong>\u8868\u73b0<\/strong>\uff1a\u672c\u5730curl <code>http:\/\/127.0.0.1:8090<\/code>\u8fd4\u56de<code>404 Not Found<\/code>\uff0c\u5c1d\u8bd5<code>\/login<\/code>\/<code>\/admin<\/code>\u8def\u5f84\u4ecd\u65e0\u6548\uff0c\u8bef\u4ee5\u4e3a\u5bb9\u5668\u670d\u52a1\u5f02\u5e38\uff1b<\/p>\n<p><strong>\u539f\u56e0<\/strong>\uff1aS-UI\u9762\u677f\u5e76\u975e\u90e8\u7f72\u5728\u6839\u8def\u5f84<code>\/<\/code>\uff0c\u800c\u662f\u6709\u4e13\u5c5e\u8bbf\u95ee\u8def\u5f84<code>\/app\/<\/code>\uff0c\u4e14S-UI\u4e3a\u524d\u540e\u7aef\u5206\u79bb\u670d\u52a1\uff0c\u6839\u8def\u5f84\u65e0\u6709\u6548\u9759\u6001\u9875\u9762\uff1b<\/p>\n<p><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u901a\u8fc7\u8bba\u575b\u6c42\u52a9\/\u5b98\u65b9\u6587\u6863\uff0c\u83b7\u53d6\u6709\u6548\u8bbf\u95ee\u8def\u5f84<code>\/app\/<\/code>\uff0c\u8865\u5145\u5230IP+\u7aef\u53e3\u540e\u5b8c\u6210\u8bbf\u95ee\u3002<\/p>\n<\/p><\/div>\n<div class=\"pitfall\">\n<h4>\u5f2f\u8def3\uff1a\u521d\u671f\u4f7f\u75282095\u7aef\u53e3\uff0c\u906d\u9047\u9690\u6027\u7f51\u7edc\u5c4f\u853d\uff08\u66f4\u6362\u7aef\u53e3\u540e\u94fe\u8def\u901a\u7545\uff09<\/h4>\n<p><strong>\u8868\u73b0<\/strong>\uff1a2095\u7aef\u53e3\u914d\u7f6e\u5168\u6b63\u5e38\uff08\u672c\u5730\u76d1\u542c\u3001\u9632\u706b\u5899\u3001\u5b89\u5168\u7ec4\uff09\uff0c\u4f46\u5916\u90e8\u59cb\u7ec8\u65e0\u6cd5\u8bbf\u95ee\uff0ccurl\u8fd4\u56de\u65e0\u54cd\u5e94\uff1b<\/p>\n<p><strong>\u539f\u56e0<\/strong>\uff1a\u90e8\u5206\u8fd0\u8425\u5546\/\u8def\u7531\u5668\u4f1a\u9690\u6027\u5c4f\u853d2095\u8fd9\u7c7b\u975e\u5e38\u89c4\u7aef\u53e3\uff0c\u5bfc\u81f4\u8bf7\u6c42\u88ab\u62e6\u622a\uff1b<\/p>\n<p><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u66f4\u6362\u66f4\u901a\u7528\u7684\u7aef\u53e3\uff088888\u30018090\uff09\uff0c\u91cd\u5efa\u5bb9\u5668\u6620\u5c04\uff0c\u540c\u6b65\u66f4\u65b0\u9632\u706b\u5899\/\u5b89\u5168\u7ec4\u89c4\u5219\uff0c\u89c4\u907f\u7aef\u53e3\u5c4f\u853d\u3002<\/p>\n<\/p><\/div>\n<div class=\"pitfall\">\n<h4>\u5f2f\u8def4\uff1a\u8bef\u89e3\u300c\u672c\u5730curl\u65e0\u8f93\u51fa\/404\u300d\u7684\u542b\u4e49\uff0c\u8fc7\u5ea6\u6392\u67e5\u5bb9\u5668\u670d\u52a1\uff08\u5ffd\u7565\u94fe\u8def\u901a\u7545\u6838\u5fc3\uff09<\/h4>\n<p><strong>\u8868\u73b0<\/strong>\uff1a\u672c\u5730curl\u6839\u8def\u5f84\u65e0\u8f93\u51fa\/\u8fd4\u56de404\uff0c\u8bef\u4ee5\u4e3a\u5bb9\u5668\u5185S-UI\u670d\u52a1\u672a\u542f\u52a8\uff0c\u53cd\u590d\u91cd\u542f\/\u91cd\u5efa\u5bb9\u5668\uff0c\u6d6a\u8d39\u5927\u91cf\u65f6\u95f4\uff1b<\/p>\n<p><strong>\u539f\u56e0<\/strong>\uff1a\u2460 S-UI\u662f\u540e\u7aefAPI\u670d\u52a1+\u4e13\u5c5e\u524d\u7aef\u8def\u5f84\uff0c\u6839\u8def\u5f84\u65e0\u6709\u6548\u54cd\u5e94\uff1b\u2461 <code>404 Not Found<\/code>\u662f\u6807\u51c6HTTP\u54cd\u5e94\uff0c\u8bf4\u660e\u672c\u5730\u94fe\u8def\uff08VPS\u2192Docker\u2192\u5bb9\u5668\u670d\u52a1\uff09\u5df2\u5b8c\u5168\u901a\u7545\uff0c\u4ec5\u8def\u5f84\u4e0d\u6b63\u786e\uff1b<\/p>\n<p><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a<code>curl -v<\/code>\u8fd4\u56de\u5b8c\u6574HTTP\u54cd\u5e94\uff08\u5373\u4f7f404\uff09\uff0c\u5373\u53ef\u786e\u8ba4\u672c\u5730\u94fe\u8def\u6b63\u5e38\uff0c\u65e0\u9700\u518d\u6392\u67e5\u5bb9\u5668\u670d\u52a1\uff0c\u805a\u7126\u300c\u8bbf\u95ee\u8def\u5f84\u300d\u548c\u300c\u5916\u90e8\u7f51\u7edc\u9650\u5236\u300d\u5373\u53ef\u3002<\/p>\n<\/p><\/div>\n<div class=\"pitfall\">\n<h4>\u5f2f\u8def5\uff1a\u672a\u5f00\u542f\u6d4f\u89c8\u5668\u65e0\u75d5\u6a21\u5f0f\/\u4f7f\u7528WiFi\u8bbf\u95ee\uff0c\u906d\u9047\u672c\u5730\u7f13\u5b58\/\u8def\u7531\u5668\u62e6\u622a\uff08\u8bef\u4ee5\u4e3a\u914d\u7f6e\u65e0\u6548\uff09<\/h4>\n<p><strong>\u8868\u73b0<\/strong>\uff1a\u914d\u7f6e\u5168\u90e8\u6b63\u786e\uff0c\u8bbf\u95ee<code>http:\/\/213.210.5.42:8090\/app\/<\/code>\u4ecd\u65e0\u6cd5\u6253\u5f00\uff0c\u663e\u793a\u300c\u65e0\u6cd5\u8bbf\u95ee\u300d\uff1b<\/p>\n<p><strong>\u539f\u56e0<\/strong>\uff1a\u2460 \u6d4f\u89c8\u5668\u7f13\u5b58\u65e7\u8bf7\u6c42\u7ed3\u679c\uff0c\u672a\u53d1\u8d77\u65b0\u8bf7\u6c42\uff1b\u2461 \u5bb6\u5ead\/\u516c\u53f8\u8def\u7531\u5668\u4f1a\u62e6\u622a8090\u8fd9\u7c7b\u975e\u9ed8\u8ba4\u7aef\u53e3\uff0880\/443\uff09\uff0c\u5bfc\u81f4\u8bf7\u6c42\u65e0\u6cd5\u4f20\u51fa\uff1b<\/p>\n<p><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u2460 \u5f00\u542f\u6d4f\u89c8\u5668\u65e0\u75d5\u6a21\u5f0f\uff0c\u907f\u514d\u7f13\u5b58\/\u63d2\u4ef6\u5e72\u6270\uff1b\u2461 \u4f18\u5148\u4f7f\u7528\u624b\u673a\u6d41\u91cf\u8bbf\u95ee\uff0c\u907f\u5f00\u8def\u7531\u5668\u62e6\u622a\uff0c\u5feb\u901f\u9a8c\u8bc1\u914d\u7f6e\u6709\u6548\u6027\u3002<\/p>\n<\/p><\/div>\n<h2>\u56db\u3001\u6700\u7ec8\u7ed3\u8bba\u4e0e\u7ecf\u9a8c\u603b\u7ed3<\/h2>\n<div class=\"conclusion\">\n<h4>\u6838\u5fc3\u603b\u7ed3\u4e0e\u590d\u7528\u7ecf\u9a8c<\/h4>\n<ol>\n<li><strong>\u90e8\u7f72\u6838\u5fc3\u4e09\u8981\u7d20<\/strong>\uff1a\u5bb9\u5668\u670d\u52a1\u6b63\u5e38\uff08\u8fd0\u884c+\u7aef\u53e3\u6620\u5c04\uff09\u3001\u672c\u5730\u9632\u706b\u5899\u653e\u884c\u3001\u670d\u52a1\u5546\u5b89\u5168\u7ec4\u653e\u884c\uff0c\u4e09\u8005\u7f3a\u4e00\u4e0d\u53ef\uff0c\u5916\u90e8\u901a\u8def\u624d\u80fd\u6253\u901a\uff1b<\/li>\n<li><strong>\u8bbf\u95ee\u5173\u952e\u4e24\u8981\u70b9<\/strong>\uff1a\u6b63\u786e\u7684\u300cIP+\u7aef\u53e3+\u8bbf\u95ee\u8def\u5f84\u300d\u3001\u89c4\u907f\u672c\u5730\u7f51\u7edc\u9650\u5236\uff08\u65e0\u75d5\u6a21\u5f0f+\u624b\u673a\u6d41\u91cf\uff09\uff0c\u89e3\u51b3\u8def\u5f84\u95ee\u9898\u548c\u672c\u5730\u62e6\u622a\u95ee\u9898\uff0c\u5373\u53ef\u6210\u529f\u8bbf\u95ee\uff1b<\/li>\n<li><strong>\u6392\u969c\u4f18\u5148\u7ea7<\/strong>\uff1a\u5148\u9a8c\u8bc1\u672c\u5730\u94fe\u8def\uff08<code>docker port<\/code>+<code>curl -v<\/code>\uff09\u2192 \u518d\u6392\u67e5\u5916\u90e8\u901a\u8def\uff08\u5b89\u5168\u7ec4+\u7aef\u53e3\u5c4f\u853d\uff09\u2192 \u6700\u540e\u805a\u7126\u8bbf\u95ee\u7ec6\u8282\uff08\u8def\u5f84+\u672c\u5730\u7f51\u7edc\uff09\uff0c\u907f\u514d\u672c\u672b\u5012\u7f6e\uff0c\u6d6a\u8d39\u6392\u969c\u65f6\u95f4\uff1b<\/li>\n<li><strong>\u7ecf\u9a8c\u590d\u7528<\/strong>\uff1a\u540e\u7eed\u90e8\u7f72\u540c\u7c7bDocker\u670d\u52a1\u65f6\uff0c\u53ef\u76f4\u63a5\u590d\u7528\u672c\u6b21\u6b65\u9aa4\uff08\u76ee\u5f55\u521b\u5efa\u2192\u5bb9\u5668\u90e8\u7f72\u2192\u53cc\u9632\u706b\u5899\u914d\u7f6e\u2192\u8def\u5f84\u9a8c\u8bc1\uff09\uff0c\u6709\u6548\u89c4\u907f\u540c\u7c7b\u8e29\u5751\u3002<\/li>\n<\/ol>\n<p style=\"margin-top: 20px;\">\u672c\u6b21\u90e8\u7f72\u4ece\u8e29\u5751\u5230\u6210\u529f\uff0c\u6838\u5fc3\u5728\u4e8e\u9010\u6b65\u6392\u67e5\u300c\u901a\u8def\u300d\u548c\u300c\u7ec6\u8282\u300d\uff0c\u660e\u786e\u6bcf\u4e00\u6b65\u7684\u9a8c\u8bc1\u6807\u51c6\uff0c\u6700\u7ec8\u901a\u8fc7\u66f4\u6362\u7aef\u53e3\u3001\u627e\u5230\u6709\u6548\u8def\u5f84\u3001\u89c4\u907f\u672c\u5730\u9650\u5236\uff0c\u5b9e\u73b0\u4e86S-UI\u9762\u677f\u7684\u5916\u90e8\u6210\u529f\u8bbf\u95ee\u3002<\/p>\n<\/p><\/div>\n<p><\/body><br \/>\n<\/html><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Linux VPS Docker\u90e8\u7f72S-UI\u5b8c\u6574\u603b\u7ed3\uff08\u542b\u8e29\u5751\u590d\u76d8\uff09 Linux VPS Docker\u90e8\u7f72S-U [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[44,39,22],"class_list":["post-323","post","type-post","status-publish","format-standard","hentry","category-6","tag-docker","tag-nginx","tag-vps"],"_links":{"self":[{"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/posts\/323","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/comments?post=323"}],"version-history":[{"count":1,"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/posts\/323\/revisions"}],"predecessor-version":[{"id":324,"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/posts\/323\/revisions\/324"}],"wp:attachment":[{"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/media?parent=323"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/categories?post=323"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.985369.xyz\/index.php\/wp-json\/wp\/v2\/tags?post=323"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}