{"id":42,"date":"2026-06-25T08:16:14","date_gmt":"2026-06-25T08:16:14","guid":{"rendered":"https:\/\/jyy7998.tk\/?p=42"},"modified":"2026-09-18T00:57:21","modified_gmt":"2026-09-18T00:57:21","slug":"%e4%bb%8e%e9%9b%b6%e5%88%b0%e4%b8%80%ef%bc%9a%e5%9c%a8-cloudflare-workers-%e4%b8%8a%e9%83%a8%e7%bd%b2-moontvplus-%e5%bd%b1%e8%a7%86%e8%81%9a%e5%90%88%e7%ab%99","status":"publish","type":"post","link":"https:\/\/wp.jyy7998.tk\/?p=42","title":{"rendered":"\u4ece\u96f6\u5230\u4e00\uff1a\u5728 Cloudflare Workers \u4e0a\u90e8\u7f72 MoonTVPlus \u5f71\u89c6\u805a\u5408\u7ad9"},"content":{"rendered":"<div class=\"doc\" style=\"--doc-accent:#0969da;--doc-accent-soft:#ebf3fc\">\n<div class=\"doc-meta\">\n            <strong>\u6700\u7ec8\u65b9\u6848\uff1a<\/strong>Cloudflare Workers\uff08\u514d\u8d39\u90e8\u7f72\uff09+ Upstash Redis\uff08\u514d\u8d39\u6570\u636e\u5e93\uff09+ LunaTV-config\uff08\u6bcf\u65e5\u81ea\u52a8\u66f4\u65b0\u7684\u5f71\u89c6\u6e90\uff09\n        <\/div>\n<h2>\u4e00\u3001\u51c6\u5907\u5de5\u4f5c<\/h2>\n<p>\u4f60\u9700\u8981\u51c6\u5907\u597d\u4ee5\u4e0b\u4e09\u6837\u4e1c\u897f\uff1a<\/p>\n<table class=\"doc-table\">\n<thead>\n<tr>\n<th>\u9879\u76ee<\/th>\n<th>\u8bf4\u660e<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><strong>GitHub \u8d26\u53f7<\/strong><\/td>\n<td>\u7528\u6765 Fork \u4ee3\u7801\u4ed3\u5e93<\/td>\n<\/tr>\n<tr>\n<td><strong>Cloudflare \u8d26\u53f7<\/strong><\/td>\n<td>\u7528\u6765\u90e8\u7f72 Worker\uff08\u514d\u8d39\uff09<\/td>\n<\/tr>\n<tr>\n<td><strong>Upstash \u8d26\u53f7<\/strong><\/td>\n<td>\u7528\u6765\u521b\u5efa\u514d\u8d39\u7684 Redis \u6570\u636e\u5e93\uff08\u652f\u6301 GitHub \u4e00\u952e\u767b\u5f55\uff09<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2>\u4e8c\u3001Fork \u9879\u76ee\u4ed3\u5e93<\/h2>\n<ol>\n<li>\n<p>\u6253\u5f00 MoonTVPlus \u4ed3\u5e93\u5730\u5740\uff1a<\/p>\n<pre class=\"prettyprint linenums\" ><code>https:\/\/github.com\/mtvpls\/MoonTVPlus<\/code><\/pre>\n<\/li>\n<li>\n<p>\u70b9\u51fb\u9875\u9762\u53f3\u4e0a\u89d2\u7684 <strong>\u300cFork\u300d<\/strong> \u6309\u94ae\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u5f39\u51fa\u7a97\u53e3\u4e2d\uff0c<strong>Owner<\/strong> \u9009\u62e9\u4f60\u81ea\u5df1\u7684 GitHub \u8d26\u53f7\uff0c\u7136\u540e\u70b9\u51fb <strong>\u300cCreate fork\u300d<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p>\u7b49\u5f85\u9875\u9762\u8df3\u8f6c\u5230\u4f60 Fork \u540e\u7684\u4ed3\u5e93\uff1a<\/p>\n<pre class=\"prettyprint linenums\" ><code>https:\/\/github.com\/\u4f60\u7684\u7528\u6237\u540d\/MoonTVPlus<\/code><\/pre>\n<\/li>\n<\/ol>\n<div class=\"doc-note doc-note--ok\">\n            <strong>\u2705 \u5b8c\u6210\u6807\u5fd7\uff1a<\/strong> \u4f60\u7684 GitHub \u8d26\u53f7\u4e0b\u591a\u4e86\u4e00\u4e2a\u540d\u4e3a <code>MoonTVPlus<\/code> \u7684\u4ed3\u5e93\u3002\n        <\/div>\n<h2>\u4e09\u3001\u83b7\u53d6 Cloudflare Account ID<\/h2>\n<ol>\n<li>\n<p>\u6253\u5f00\u6d4f\u89c8\u5668\uff0c\u8bbf\u95ee <a href=\"https:\/\/dash.cloudflare.com\/\" target=\"_blank\">Cloudflare \u63a7\u5236\u53f0<\/a>\uff0c\u767b\u5f55\u4f60\u7684\u8d26\u53f7\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u5173\u952e\u8def\u5f84\uff1a<\/strong> \u5728\u5de6\u4fa7\u83dc\u5355\u680f\u4e2d\uff0c\u627e\u5230 <strong>\u300c\u8ba1\u7b97\u300d<\/strong>\uff08Compute\uff09\u5206\u7c7b \u2192 \u70b9\u51fb <strong>\u300cWorkers &amp; Pages\u300d<\/strong>\u3002<\/p>\n<div class=\"doc-note doc-note--info\">\n                    \ud83d\udccd <strong>\u4f4d\u7f6e\u63d0\u793a\uff1a<\/strong> \u5de6\u4fa7\u83dc\u5355\u4ece\u4e0a\u5230\u4e0b\u4f9d\u6b21\u662f\uff1a\u8d26\u6237\u4e3b\u9875 \u2192 \u57df\u540d \u2192 Observe \u2192 Investigate \u2192 \u6570\u636e\u5206\u6790 \u2192 \u6784\u5efa \u2192 <strong>\u300c\u8ba1\u7b97\u300d\uff08Workers &amp; Pages \u5728\u8fd9\u91cc\uff09<\/strong> \u2192 AI \u2192 \u5b58\u50a8\u548c\u6570\u636e\u5e93 \u2192 \u2026\u2026\n                <\/div>\n<\/li>\n<li>\n<p>\u8fdb\u5165 <strong>Workers &amp; Pages<\/strong> \u9875\u9762\u540e\uff0c<strong>\u4e0d\u8981\u521b\u5efa\u4efb\u4f55\u4e1c\u897f<\/strong>\uff0c\u76f4\u63a5\u770b\u9875\u9762\u53f3\u4fa7\u6216\u9876\u90e8\u4fe1\u606f\u680f\u3002<\/p>\n<\/li>\n<li>\n<p>\u627e\u5230 <strong>\u300c\u8d26\u6237 ID\u300d<\/strong>\uff08Account ID\uff09\uff0c\u5b83\u662f\u4e00\u4e32\u7531\u5b57\u6bcd\u548c\u6570\u5b57\u7ec4\u6210\u7684\u5b57\u7b26\u4e32\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u590d\u5236\u5e76\u4fdd\u5b58\u8fd9\u4e2a Account ID<\/strong>\uff0c\u4e0b\u4e00\u6b65\u8981\u7528\u3002<\/p>\n<\/li>\n<\/ol>\n<div class=\"doc-note doc-note--ok\">\n            <strong>\u2705 \u793a\u4f8b\uff1a<\/strong> <code>358829b2d79a593ba1efa5ff7de3993a<\/code>\n        <\/div>\n<h2>\u56db\u3001\u521b\u5efa Cloudflare API Token<\/h2>\n<ol>\n<li>\n<p>\u5728 Cloudflare \u63a7\u5236\u53f0\uff0c\u70b9\u51fb\u53f3\u4e0a\u89d2\u7684 <strong>\u5934\u50cf\u56fe\u6807<\/strong>\uff08\u4f60\u7684\u8d26\u6237\u5934\u50cf\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u4e0b\u62c9\u83dc\u5355\u4e2d\uff0c\u9009\u62e9 <strong>\u300c\u6211\u7684\u4e2a\u4eba\u8d44\u6599\u300d<\/strong>\uff08My Profile\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u4e2a\u4eba\u8d44\u6599\u9875\u9762\uff0c\u5207\u6362\u5230\u9876\u90e8\u7684 <strong>\u300cAPI \u4ee4\u724c\u300d<\/strong>\uff08API Tokens\uff09\u9009\u9879\u5361\u3002<\/p>\n<\/li>\n<li>\n<p>\u70b9\u51fb <strong>\u300c\u521b\u5efa\u4ee4\u724c\u300d<\/strong>\uff08Create token\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u4ee4\u724c\u6a21\u677f\u5217\u8868\u4e2d\uff0c\u627e\u5230 <strong>\u300c\u7f16\u8f91 Cloudflare Workers\u300d<\/strong>\uff0c\u70b9\u51fb\u53f3\u4fa7\u7684 <strong>\u300c\u4f7f\u7528\u6a21\u677f\u300d<\/strong>\uff08Use template\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u201c\u8d26\u6237\u8d44\u6e90\u201d\u5904\uff0c<strong>\u786e\u4fdd\u9009\u62e9\u7684\u662f\u4f60\u7684\u8d26\u6237<\/strong>\uff08\u4e0d\u662f\u5177\u4f53\u67d0\u4e2a\u57df\u540d\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u70b9\u51fb\u9875\u9762\u5e95\u90e8\u7684 <strong>\u300c\u7ee7\u7eed\u4ee5\u663e\u793a\u6458\u8981\u300d<\/strong> \u2192 \u518d\u70b9\u51fb <strong>\u300c\u521b\u5efa\u4ee4\u724c\u300d<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u26a0\ufe0f \u7acb\u5373\u590d\u5236\u5e76\u4fdd\u5b58<\/strong> \u751f\u6210\u7684\u4ee4\u724c\u5b57\u7b26\u4e32\uff08\u5b83\u53ea\u663e\u793a\u8fd9\u4e00\u6b21\uff01\uff09\u3002<\/p>\n<div class=\"doc-note doc-note--warn\">\n                    <strong>\ud83d\udd10 \u683c\u5f0f\u7c7b\u4f3c\uff1a<\/strong> <code>cfut_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx<\/code>\n                <\/div>\n<\/li>\n<\/ol>\n<h2>\u4e94\u3001\u521b\u5efa Upstash Redis \u6570\u636e\u5e93<\/h2>\n<ol>\n<li>\n<p>\u6253\u5f00 <a href=\"https:\/\/console.upstash.com\/\" target=\"_blank\">Upstash Console<\/a>\u3002<\/p>\n<\/li>\n<li>\n<p>\u70b9\u51fb <strong>\u300cSign Up\u300d<\/strong> \u6ce8\u518c\uff0c\u63a8\u8350\u4f7f\u7528 <strong>\u300cSign in with GitHub\u300d<\/strong> \u4e00\u952e\u767b\u5f55\u3002<\/p>\n<\/li>\n<li>\n<p>\u767b\u5f55\u6210\u529f\u540e\uff0c\u70b9\u51fb <strong>\u300cCreate Database\u300d<\/strong>\uff08\u521b\u5efa\u6570\u636e\u5e93\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u586b\u5199\u4ee5\u4e0b\u4fe1\u606f\uff1a<\/p>\n<ul>\n<li><strong>Name\uff1a<\/strong> \u968f\u4fbf\u8d77\u4e00\u4e2a\uff0c\u4f8b\u5982 <code>moontv<\/code><\/li>\n<li><strong>Region\uff1a<\/strong> \u9009\u62e9 <code>us-east-1<\/code>\uff08\u7f8e\u4e1c\uff09\u6216 <code>eu-west-1<\/code>\uff08\u6b27\u6d32\uff09<\/li>\n<li>\u5176\u4ed6\u9009\u9879\u4fdd\u6301\u9ed8\u8ba4<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u70b9\u51fb\u5e95\u90e8\u7684 <strong>\u300cCreate\u300d<\/strong> \u6309\u94ae\u3002<\/p>\n<\/li>\n<li>\n<p>\u521b\u5efa\u5b8c\u6210\u540e\uff0c<strong>\u70b9\u51fb\u6570\u636e\u5e93\u540d\u79f0<\/strong> \u8fdb\u5165\u8be6\u60c5\u9875\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u8be6\u60c5\u9875\u7684 <strong>REST API<\/strong> \u533a\u57df\uff0c\u627e\u5230\u4e24\u4e2a\u5173\u952e\u4fe1\u606f\uff1a<\/p>\n<ul>\n<li><strong>UPSTASH_URL\uff1a<\/strong> \u7c7b\u4f3c <code>https:\/\/xxx.upstash.io<\/code><\/li>\n<li><strong>UPSTASH_TOKEN\uff1a<\/strong> \u88ab\u661f\u53f7 <code>**********<\/code> \u9690\u85cf\uff0c<strong>\u70b9\u51fb\u53f3\u4fa7\u7684\u773c\u775b\u56fe\u6807 \ud83d\udc41\ufe0f<\/strong> \u663e\u793a\u5b8c\u6574\u5185\u5bb9\uff0c\u7136\u540e\u590d\u5236\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<div class=\"doc-note doc-note--info\">\n            <strong>\u26a0\ufe0f \u6ce8\u610f\uff1a<\/strong> \u9875\u9762\u4e0a\u663e\u793a\u7684\u662f <code>UPSTASH_REDIS_REST_URL<\/code> \u548c <code>UPSTASH_REDIS_REST_TOKEN<\/code>\uff0c<strong>\u914d\u7f6e GitHub Secrets \u65f6\u8981\u53bb\u6389 <code>_REDIS_REST<\/code> \u90e8\u5206<\/strong>\uff0c\u53ea\u4fdd\u7559 <code>UPSTASH_URL<\/code> \u548c <code>UPSTASH_TOKEN<\/code>\u3002\n        <\/div>\n<h2>\u516d\u3001\u5728 GitHub \u4ed3\u5e93\u4e2d\u914d\u7f6e Secrets<\/h2>\n<ol>\n<li>\n<p>\u6253\u5f00\u4f60 Fork \u540e\u7684\u4ed3\u5e93\uff1a<\/p>\n<pre class=\"prettyprint linenums\" ><code>https:\/\/github.com\/\u4f60\u7684\u7528\u6237\u540d\/MoonTVPlus<\/code><\/pre>\n<\/li>\n<li>\n<p>\u70b9\u51fb\u9876\u90e8\u7684 <strong>\u300cSettings\u300d<\/strong>\uff08\u8bbe\u7f6e\uff09\u9009\u9879\u5361\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u5de6\u4fa7\u83dc\u5355\u4e2d\uff0c\u627e\u5230 <strong>\u300cSecrets and variables\u300d<\/strong> \u2192 \u70b9\u51fb\u5c55\u5f00 \u2192 \u9009\u62e9 <strong>\u300cActions\u300d<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p>\u70b9\u51fb\u7eff\u8272\u7684 <strong>\u300cNew repository secret\u300d<\/strong> \u6309\u94ae\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u4f9d\u6b21\u6dfb\u52a0\u4ee5\u4e0b 7 \u4e2a Secret<\/strong>\uff08\u540d\u79f0\u5fc5\u987b <strong>\u5b8c\u5168\u4e00\u81f4<\/strong>\uff0c\u533a\u5206\u5927\u5c0f\u5199\uff09\uff1a<\/p>\n<table class=\"doc-table\">\n<thead>\n<tr>\n<th>Secret \u540d\u79f0<\/th>\n<th>\u503c\uff08\u4ece\u54ea\u91cc\u83b7\u53d6\uff09<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><code>CLOUDFLARE_API_TOKEN<\/code><\/td>\n<td>\u7b2c\u56db\u6b65\u83b7\u53d6\u7684 API Token<\/td>\n<\/tr>\n<tr>\n<td><code>CLOUDFLARE_ACCOUNT_ID<\/code><\/td>\n<td>\u7b2c\u4e09\u6b65\u83b7\u53d6\u7684 Account ID<\/td>\n<\/tr>\n<tr>\n<td><code>UPSTASH_URL<\/code><\/td>\n<td>\u7b2c\u4e94\u6b65\u83b7\u53d6\u7684 UPSTASH_URL<\/td>\n<\/tr>\n<tr>\n<td><code>UPSTASH_TOKEN<\/code><\/td>\n<td>\u7b2c\u4e94\u6b65\u83b7\u53d6\u7684 UPSTASH_TOKEN<\/td>\n<\/tr>\n<tr>\n<td><code>USERNAME<\/code><\/td>\n<td>\u4f60\u81ea\u5df1\u8bbe\u7f6e\u7684\u7ba1\u7406\u5458\u7528\u6237\u540d\uff08\u5982 <code>admin<\/code>\uff09<\/td>\n<\/tr>\n<tr>\n<td><code>PASSWORD<\/code><\/td>\n<td>\u4f60\u81ea\u5df1\u8bbe\u7f6e\u7684\u7ba1\u7406\u5458\u5bc6\u7801\uff08\u52a1\u5fc5\u4f7f\u7528\u5f3a\u5bc6\u7801\uff09<\/td>\n<\/tr>\n<tr>\n<td><code>NEXT_PUBLIC_STORAGE_TYPE<\/code><\/td>\n<td>\u56fa\u5b9a\u586b\u5199 <code>upstash<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/li>\n<li>\n<p>\u6bcf\u6dfb\u52a0\u4e00\u4e2a\uff0c\u70b9\u51fb <strong>\u300cAdd secret\u300d<\/strong> \u4fdd\u5b58\u3002\u5168\u90e8\u6dfb\u52a0\u5b8c\u6210\u540e\uff0c\u5217\u8868\u5e94\u8be5\u663e\u793a 7 \u4e2a Secret\u3002<\/p>\n<\/li>\n<\/ol>\n<h2>\u4e03\u3001\u89e6\u53d1\u81ea\u52a8\u90e8\u7f72<\/h2>\n<ol>\n<li>\n<p>\u5728 GitHub \u4ed3\u5e93\u9875\u9762\uff0c\u70b9\u51fb\u9876\u90e8\u7684 <strong>\u300cActions\u300d<\/strong>\uff08\u64cd\u4f5c\uff09\u9009\u9879\u5361\u3002<\/p>\n<\/li>\n<li>\n<p>\u5de6\u4fa7 Workflows \u5217\u8868\u4e2d\uff0c\u70b9\u51fb <strong>\u300cDeploy to Cloudflare\u300d<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p>\u5982\u679c\u5de6\u4fa7\u6ca1\u6709 <code>Deploy to Cloudflare<\/code>\uff0c\u800c\u662f\u663e\u793a <strong>\u201cWorkflows aren&#8217;t being run on this forked repository\u201d<\/strong>\uff1a<\/p>\n<div class=\"doc-note doc-note--warn\">\n                    \u70b9\u51fb\u84dd\u8272\u7684 <strong>\u300cI understand my workflows, go ahead and enable them\u300d<\/strong> \u6309\u94ae\u542f\u7528 Actions\uff0c\u7136\u540e\u518d\u91cd\u590d\u8fd9\u4e00\u6b65\u3002\n                <\/div>\n<\/li>\n<li>\n<p>\u70b9\u51fb\u53f3\u4fa7\u7684 <strong>\u300cRun workflow\u300d<\/strong> \u6309\u94ae\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728\u5f39\u51fa\u7684\u4e0b\u62c9\u6846\u4e2d\uff0c\u76f4\u63a5\u70b9\u51fb\u7eff\u8272\u7684 <strong>\u300cRun workflow\u300d<\/strong> \u6309\u94ae\u3002<\/p>\n<\/li>\n<li>\n<p>\u9875\u9762\u4f1a\u5237\u65b0\uff0c\u51fa\u73b0\u4e00\u4e2a\u65b0\u7684\u8fd0\u884c\u4efb\u52a1\uff08\u9ec4\u8272\u5706\u70b9\u8868\u793a\u8fdb\u884c\u4e2d\uff09\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u70b9\u51fb\u8fd9\u4e2a\u4efb\u52a1<\/strong>\uff0c\u53ef\u4ee5\u67e5\u770b\u5b9e\u65f6\u90e8\u7f72\u65e5\u5fd7\u3002<\/p>\n<\/li>\n<li>\n<p>\u7b49\u5f85\u7ea6 <strong>2~3 \u5206\u949f<\/strong>\uff0c\u72b6\u6001\u53d8\u4e3a\u7eff\u8272 \u2705 \u5373\u8868\u793a\u90e8\u7f72\u6210\u529f\u3002<\/p>\n<\/li>\n<\/ol>\n<h2>\u516b\u3001\u8bbf\u95ee\u4f60\u7684\u7ad9\u70b9<\/h2>\n<ol>\n<li>\n<p>\u6253\u5f00 Cloudflare \u63a7\u5236\u53f0\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u5173\u952e\u8def\u5f84\uff1a<\/strong> \u5de6\u4fa7\u83dc\u5355 \u2192 <strong>\u300c\u8ba1\u7b97\u300d<\/strong>\uff08Compute\uff09\u2192 <strong>\u300cWorkers &amp; Pages\u300d<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728 Worker \u5217\u8868\u4e2d\uff0c\u4f60\u4f1a\u770b\u5230\u4e00\u4e2a\u65b0\u521b\u5efa\u7684 Worker\uff08\u540d\u79f0\u7c7b\u4f3c <code>moontvplus<\/code> \u6216 <code>montv-plus<\/code>\uff09\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u70b9\u51fb\u8fd9\u4e2a Worker \u540d\u79f0<\/strong> \u8fdb\u5165\u8be6\u60c5\u9875\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728 <strong>\u300c\u6982\u8ff0\u300d<\/strong>\uff08Overview\uff09\u9875\u9762\uff0c\u627e\u5230 <strong>\u300cWorker URL\u300d<\/strong> \u533a\u57df\u3002<\/p>\n<\/li>\n<li>\n<p>\u590d\u5236 <strong>\u751f\u4ea7\u73af\u5883<\/strong> \u7684\u5730\u5740\uff1a<\/p>\n<pre class=\"prettyprint linenums\" ><code>https:\/\/xxxxxx.workers.dev<\/code><\/pre>\n<\/li>\n<li>\n<p>\u5728\u6d4f\u89c8\u5668\u4e2d\u6253\u5f00\u8fd9\u4e2a\u5730\u5740\uff0c\u4f7f\u7528\u4f60\u5728\u7b2c\u516d\u6b65\u8bbe\u7f6e\u7684 <code>USERNAME<\/code> \u548c <code>PASSWORD<\/code> \u767b\u5f55\u3002<\/p>\n<\/li>\n<\/ol>\n<h2>\u4e5d\u3001\u914d\u7f6e\u5f71\u89c6\u6e90\uff08\u6700\u5173\u952e\u7684\u4e00\u6b65\uff09<\/h2>\n<p>\u767b\u5f55\u6210\u529f\u540e\uff0c\u9875\u9762\u4f1a\u8fdb\u5165 MoonTVPlus \u7684\u7ba1\u7406\u540e\u53f0\u3002<\/p>\n<h4>\u6dfb\u52a0\u89c6\u9891\u6e90\uff1a<\/h4>\n<ol>\n<li>\n<p>\u5728\u5de6\u4fa7\u83dc\u5355\u6216\u9875\u9762\u4e2d\u627e\u5230 <strong>\u300c\u89c6\u9891\u6e90\u914d\u7f6e\u300d<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p>\u70b9\u51fb <strong>\u300c\u6dfb\u52a0\u300d<\/strong> \u6309\u94ae\u3002<\/p>\n<\/li>\n<li>\n<p>\u586b\u5199\u4ee5\u4e0b\u4fe1\u606f\uff1a<\/p>\n<ul>\n<li><strong>\u540d\u79f0\uff1a<\/strong> \u968f\u4fbf\u586b\uff0c\u5982 <code>LunaTV\u8ba2\u9605<\/code><\/li>\n<li><strong>Key\uff1a<\/strong> \u586b\u4e00\u4e2a\u82f1\u6587\u6807\u8bc6\u7b26\uff0c\u5982 <code>lunatv<\/code>\uff08<strong>\u4e0d\u80fd\u662f<\/strong> <code>openlist<\/code>\u3001<code>xiaoya<\/code> \u6216\u4ee5 <code>emby<\/code> \u5f00\u5934\u7684\u8bcd\uff09<\/li>\n<li><strong>\u63a5\u53e3\u5730\u5740\uff1a<\/strong> \u586b\u5165\u4ee5\u4e0b\u8ba2\u9605 URL\uff1a<\/li>\n<\/ul>\n<pre class=\"prettyprint linenums\" ><code>https:\/\/raw.githubusercontent.com\/hafrey1\/LunaTV-config\/refs\/heads\/main\/LunaTV-config.txt<\/code><\/pre>\n<\/li>\n<li>\n<p>\u70b9\u51fb <strong>\u300c\u6dfb\u52a0\u300d<\/strong> \u4fdd\u5b58\u3002<\/p>\n<\/li>\n<li>\n<p>\u7cfb\u7edf\u4f1a\u81ea\u52a8\u6d4b\u8bd5\u63a5\u53e3\u662f\u5426\u53ef\u7528\uff0c\u52a0\u8f7d\u5b8c\u6210\u540e\u5373\u53ef\u5728\u9996\u9875\u770b\u5230\u5f71\u7247\u5217\u8868\u3002<\/p>\n<\/li>\n<\/ol>\n<div class=\"doc-note doc-note--info\">\n            <strong>\ud83d\udccc \u5907\u7528\u7cbe\u7b80\u7248\u8ba2\u9605\u6e90\uff1a<\/strong>\uff08\u5982\u679c\u5b8c\u6574\u7248\u52a0\u8f7d\u6162\uff09<\/p>\n<pre class=\"prettyprint linenums\" ><code>https:\/\/raw.githubusercontent.com\/hafrey1\/LunaTV-config\/refs\/heads\/main\/jingjian.txt<\/code><\/pre>\n<\/p><\/div>\n<h2>\u5341\u3001\u7ed1\u5b9a\u81ea\u5b9a\u4e49\u57df\u540d\uff08\u53ef\u9009\uff09<\/h2>\n<p>\u5982\u679c\u4f60\u6709\u81ea\u5df1\u7684\u57df\u540d\uff0c\u5e76\u5df2\u6258\u7ba1\u5728 Cloudflare\uff1a<\/p>\n<ol>\n<li>\n<p>\u8fdb\u5165 Worker \u8be6\u60c5\u9875 \u2192 \u70b9\u51fb\u9876\u90e8 <strong>\u300c\u8bbe\u7f6e\u300d<\/strong>\uff08Settings\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u5de6\u4fa7\u83dc\u5355 \u2192 <strong>\u300c\u89e6\u53d1\u5668\u300d<\/strong>\uff08Triggers\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u5728 <strong>\u300c\u81ea\u5b9a\u4e49\u57df\u300d<\/strong>\uff08Custom Domains\uff09\u90e8\u5206\uff0c\u70b9\u51fb <strong>\u300c\u6dfb\u52a0\u57df\u300d<\/strong>\uff08Add Domain\uff09\u3002<\/p>\n<\/li>\n<li>\n<p>\u8f93\u5165\u4f60\u7684\u57df\u540d\uff08\u5982 <code>tv.yourdomain.com<\/code>\uff09\uff0c\u70b9\u51fb\u7ee7\u7eed\u3002<\/p>\n<\/li>\n<li>\n<p>Cloudflare \u4f1a\u81ea\u52a8\u68c0\u6d4b\u57df\u540d\uff0c\u6309\u63d0\u793a\u6dfb\u52a0 <strong>CNAME \u8bb0\u5f55<\/strong>\u3002<\/p>\n<\/li>\n<li>\n<p>\u7b49\u5f85 DNS \u89e3\u6790\u751f\u6548\uff08\u901a\u5e38\u51e0\u5206\u949f\uff09\uff0c\u5373\u53ef\u901a\u8fc7\u81ea\u5df1\u7684\u57df\u540d\u8bbf\u95ee\u3002<\/p>\n<\/li>\n<\/ol>\n<h2>\u5341\u4e00\u3001\u5e38\u89c1\u95ee\u9898\u4e0e\u907f\u5751\u6307\u5357<\/h2>\n<table class=\"doc-table\">\n<thead>\n<tr>\n<th style=\"width: 30%\">\u95ee\u9898\u73b0\u8c61<\/th>\n<th>\u539f\u56e0\u4e0e\u89e3\u51b3\u65b9\u6cd5<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><strong>\u627e\u4e0d\u5230 Workers &amp; Pages<\/strong><\/td>\n<td>\u8def\u5f84\u662f\uff1a\u5de6\u4fa7\u83dc\u5355 \u2192 <strong>\u300c\u8ba1\u7b97\u300d<\/strong>\uff08Compute\uff09\u2192 Workers &amp; Pages\uff0c\u4e0d\u662f\u9876\u90e8\u5bfc\u822a\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>Fork \u540e Actions \u6ca1\u6709 Deploy to Cloudflare<\/strong><\/td>\n<td>GitHub \u9ed8\u8ba4\u7981\u7528\u4e86 Fork \u4ed3\u5e93\u7684 Actions\uff0c\u70b9\u51fb\u84dd\u8272\u6309\u94ae <strong>\u300cI understand\u2026\u300d<\/strong> \u542f\u7528\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u90e8\u7f72\u5931\u8d25\uff0c\u62a5\u9519 Authentication error<\/strong><\/td>\n<td>API Token \u6743\u9650\u4e0d\u8db3\u6216\u5df2\u5931\u6548\u3002\u5220\u9664\u65e7 Token\uff0c\u91cd\u65b0\u521b\u5efa <strong>\u300c\u7f16\u8f91 Cloudflare Workers\u300d<\/strong> \u6a21\u677f\u7684 Token\uff0c\u5e76\u66f4\u65b0 GitHub Secret\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u90e8\u7f72\u6210\u529f\u4f46\u8bbf\u95ee\u9875\u9762\u7a7a\u767d<\/strong><\/td>\n<td>\u68c0\u67e5 UPSTASH \u6570\u636e\u5e93\u662f\u5426\u914d\u7f6e\u6b63\u786e\uff0c<code>NEXT_PUBLIC_STORAGE_TYPE<\/code> \u662f\u5426\u4e3a <code>upstash<\/code>\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u767b\u5f55\u540e\u6ca1\u6709\u5f71\u7247<\/strong><\/td>\n<td>\u9700\u8981\u5148\u914d\u7f6e\u89c6\u9891\u6e90\uff08\u7b2c\u4e5d\u6b65\uff09\uff0cMoonTVPlus \u662f\u7a7a\u58f3\uff0c\u4e0d\u5185\u7f6e\u4efb\u4f55\u5f71\u89c6\u8d44\u6e90\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u89c6\u9891\u6e90\u63a5\u53e3\u5931\u6548<\/strong><\/td>\n<td>\u7b2c\u4e09\u65b9\u63a5\u53e3\u968f\u65f6\u53ef\u80fd\u5931\u6548\u3002LunaTV-config \u9879\u76ee\u6bcf\u65e5\u81ea\u52a8\u68c0\u6d4b API \u6709\u6548\u6027\uff0c\u63a8\u8350\u4f7f\u7528\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>Upstash Token \u88ab\u661f\u53f7\u9690\u85cf<\/strong><\/td>\n<td>\u70b9\u51fb\u6570\u636e\u5e93\u8be6\u60c5\u9875 REST API \u533a\u57df\u7684\u773c\u775b\u56fe\u6807 \ud83d\udc41\ufe0f \u663e\u793a\u5b8c\u6574 Token\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u81ea\u5b9a\u4e49\u57df\u540d\u65e0\u6cd5\u8bbf\u95ee<\/strong><\/td>\n<td>\u68c0\u67e5 DNS \u89e3\u6790\u662f\u5426\u5df2\u6dfb\u52a0 CNAME \u8bb0\u5f55\uff0c\u4ee5\u53ca\u662f\u5426\u5df2\u751f\u6548\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2>\u5341\u4e8c\u3001\u603b\u7ed3<\/h2>\n<p><strong>\u6280\u672f\u94fe\u8def\uff1a<\/strong><\/p>\n<div class=\"doc-note doc-note--info\">\n            GitHub \u6258\u7ba1\u4ee3\u7801 \u2192 GitHub Actions \u81ea\u52a8\u6784\u5efa \u2192 Cloudflare Workers \u90e8\u7f72 \u2192 Upstash \u5b58\u50a8\u6570\u636e \u2192 LunaTV-config \u63d0\u4f9b\u5f71\u89c6\u6e90\n        <\/div>\n<p><strong>\u8d39\u7528\uff1a<\/strong> \u5168\u7a0b\u514d\u8d39\uff08Cloudflare \u514d\u8d39\u8ba1\u5212\u6bcf\u65e5 10 \u4e07\u6b21\u8bf7\u6c42\uff0c\u4e2a\u4eba\u4f7f\u7528\u5b8c\u5168\u8db3\u591f\uff09\u3002<\/p>\n<p><strong>\u7ef4\u62a4\uff1a<\/strong> \u90e8\u7f72\u5b8c\u6210\u540e\uff0c\u53ea\u9700\u5076\u5c14\u5173\u6ce8\u5f71\u89c6\u6e90\u662f\u5426\u6709\u6548\uff08LunaTV-config \u6bcf\u65e5\u81ea\u52a8\u66f4\u65b0\uff0c\u57fa\u672c\u65e0\u9700\u4eba\u5de5\u5e72\u9884\uff09\u3002<\/p>\n<hr>\n<p class=\"doc-foot doc-center\">\n            <em>\u672c\u6587\u4e3a\u4e2a\u4eba\u6298\u817e\u7ecf\u9a8c\u603b\u7ed3\uff0c\u6240\u6709\u5f71\u89c6\u6e90\u7531\u7b2c\u4e09\u65b9\u63d0\u4f9b\uff0c\u4ec5\u4f9b\u5b66\u4e60\u4ea4\u6d41\u4f7f\u7528\u3002<\/em>\n        <\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u6700\u7ec8\u65b9\u6848\uff1aCloudflare Workers\uff08\u514d\u8d39\u90e8\u7f72\uff09+ Upstash Redis\uff08\u514d\u8d39\u6570\u636e\u5e93\uff09+ LunaTV-config\uff08\u6bcf\u65e5\u81ea\u52a8\u66f4\u65b0\u7684\u5f71\u89c6\u6e90\uff09 \u4e00\u3001\u51c6\u5907\u5de5\u4f5c \u4f60\u9700\u8981\u51c6\u5907\u597d\u4ee5\u4e0b\u4e09\u6837\u4e1c\u897f\uff1a \u9879\u76ee \u8bf4\u660e GitHub \u8d26\u53f7 \u7528\u6765 Fork \u4ee3\u7801\u4ed3\u5e93 Cloudflare \u8d26\u53f7 \u7528\u6765\u90e8\u7f72 Worker\uff08\u514d\u8d39\uff09 Upstash \u8d26\u53f7 \u7528\u6765\u521b\u5efa\u514d\u8d39\u7684 Redis \u6570\u636e\u5e93\uff08\u652f\u6301 GitHub \u4e00\u952e [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[24,25,48],"class_list":["post-42","post","type-post","status-publish","format-standard","hentry","category-cloudflare","tag-cloudflare","tag-github-actions","tag-media-aggregation"],"_links":{"self":[{"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=\/wp\/v2\/posts\/42","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=42"}],"version-history":[{"count":1,"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=\/wp\/v2\/posts\/42\/revisions"}],"predecessor-version":[{"id":112,"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=\/wp\/v2\/posts\/42\/revisions\/112"}],"wp:attachment":[{"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=42"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=42"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wp.jyy7998.tk\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=42"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}