{"id":260,"date":"2026-05-19T01:44:03","date_gmt":"2026-05-18T17:44:03","guid":{"rendered":"https:\/\/blog.nickys.cn\/?p=260"},"modified":"2026-05-19T01:45:43","modified_gmt":"2026-05-18T17:45:43","slug":"%e7%94%a8-github-vercel-%e6%90%ad%e4%ba%86%e4%b8%80%e5%a5%97%e5%85%a8%e8%87%aa%e5%8a%a8%e7%bd%91%e7%ab%99%e9%83%a8%e7%bd%b2%e9%93%be%e8%b7%af","status":"publish","type":"post","link":"https:\/\/blog.nickys.cn\/?p=260","title":{"rendered":"\u7528 GitHub + Vercel \u642d\u4e86\u4e00\u5957\u5168\u81ea\u52a8\u7f51\u7ad9\u90e8\u7f72\u94fe\u8def"},"content":{"rendered":"<style>\n.auto-hero { background:linear-gradient(135deg,#0c1929 0%,#1e3a5f 50%,#0c1929 100%);padding:44px 32px;text-align:center;border-radius:16px;margin-bottom:32px;}\n.auto-hero .badge { display:inline-block;background:linear-gradient(135deg,#3b82f6,#1d4ed8);color:#fff;padding:4px 16px;border-radius:20px;font-size:13px;font-weight:600;margin-bottom:16px;}\n.auto-hero h2 { color:#fff;font-size:24px;margin:0 0 10px;font-weight:700;}\n.auto-hero p { color:#94a3b8;font-size:15px;margin:0;line-height:1.7;}\n.auto-card { border-radius:12px;padding:20px 24px;margin:16px 0;border-left:4px solid #3b82f6;background:#f0f7ff;}\n.auto-card.green { border-left-color:#22c55e;background:#f0fdf4;}\n.auto-card.amber { border-left-color:#f59e0b;background:#fffbeb;}\n.auto-code { background:#0f172a;border-radius:12px;padding:20px;margin:16px 0;overflow-x:auto;font-family:monospace;font-size:14px;line-height:1.7;color:#e2e8f0;}\n.auto-code .arrow { color:#22d3ee; }\n.auto-code .site { color:#fbbf24; }\n.auto-code .action { color:#34d399; }\n.auto-note { background:#fffbeb;border:1px solid #fde68a;border-radius:12px;padding:16px 20px;margin:16px 0;color:#92400e;font-size:14px;}\n.auto-tip { background:#f0fdf4;border:1px solid #bbf7d0;border-radius:12px;padding:16px 20px;margin:16px 0;color:#166534;font-size:14px;}\n.auto-table { border-radius:12px;overflow:hidden;box-shadow:0 4px 16px rgba(0,0,0,0.06);margin:20px 0;}\n.auto-table table { width:100%;border-collapse:collapse;font-size:14px;}\n.auto-table thead th { background:linear-gradient(135deg,#3b82f6,#1d4ed8);color:#fff;padding:12px 14px;text-align:left;}\n.auto-table tbody td { padding:10px 14px;border-bottom:1px solid #e2e8f0;}\n.auto-table tbody tr:nth-child(even) { background:#f8fafc;}\n.auto-summary { background:linear-gradient(135deg,#0c1929,#1e3a5f);border-radius:16px;padding:24px 28px;margin:24px 0;color:#cbd5e1;}\n.auto-summary strong { color:#fff;}\n<\/style>\n<div class=\"auto-hero\">\n<div class=\"badge\">\u2699\ufe0f \u6280\u672f\u65b9\u6848<\/div>\n<h2>\u4ece\u624b\u52a8\u5230\u5168\u81ea\u52a8<\/h2>\n<p>\u817e\u8baf\u4e91 + GitHub + Vercel + \u4e09\u7ad9\u8054\u52a8\uff0c\u4e00\u6b21\u914d\u597d\u7ba1\u5230\u4f4e<\/p>\n<\/div>\n<p>\u6700\u8fd1\u628a\u7f51\u7ad9\u90e8\u7f72\u67b6\u6784\u91cd\u65b0\u68b3\u7406\u4e86\u4e00\u904d\uff0c\u4ece\u817e\u8baf\u4e91\u5230 GitHub \u518d\u5230 Vercel \u5b9e\u73b0\u4e86\u5168\u81ea\u52a8\u90e8\u7f72\u3002\u8bb0\u5f55\u4e00\u4e0b\u5b8c\u6574\u7684\u65b9\u6848\uff0c\u7ed9\u540c\u6837\u6298\u817e\u81ea\u5efa\u7ad9\u7684\u670b\u53cb\u53c2\u8003\u3002<\/p>\n<h3>\u4e4b\u524d\u7684\u5c40\u9762<\/h3>\n<p>\u6211\u624b\u5934\u4e09\u53f0\u670d\u52a1\u5668\uff1a\u817e\u8baf\u4e91\u4e3b\u529b\u3001web2 \u8f85\u52a9\u3001nasweb \u5907\u4efd\u3002\u6bcf\u6b21\u66f4\u65b0\u6587\u4ef6\u8981\u624b\u52a8\u540c\u6b65\u4e09\u904d\uff0c\u7528 lftp \u4f20\u5230 web2 \u548c nasweb\uff0c\u5076\u5c14\u8fd8\u4f1a\u6f0f\u6389\u4e00\u4e24\u4e2a\u7ad9\u3002\u4e5f\u6ca1\u6709\u7248\u672c\u7ba1\u7406\uff0c\u6539\u9519\u4e86\u56de\u4e0d\u53bb\u3002<\/p>\n<div class=\"auto-card amber\">\n  <strong>\ud83d\ude05 \u75db\u70b9<\/strong> \u2014 \u624b\u5de5\u64cd\u4f5c\u4e09\u7ad9\u540c\u6b65\uff0c\u5bb9\u6613\u6f0f\u3001\u5bb9\u6613\u5fd8\u3001\u6539\u9519\u4e86\u56de\u4e0d\u4e86\u5934\n<\/div>\n<h3>\u73b0\u5728\u7684\u67b6\u6784<\/h3>\n<p>\u6574\u6761\u94fe\u8def\u5f88\u7b80\u5355\uff1a<\/p>\n<div class=\"auto-code\">\n<span class=\"site\">\u817e\u8baf\u4e91 web<\/span> <span class=\"arrow\">\u2192<\/span> <span class=\"action\">\u5b9e\u65f6\u76d1\u63a7<\/span> <span class=\"arrow\">\u2192<\/span> <span class=\"site\">GitHub \u79c1\u6709\u4ed3\u5e93<\/span> <span class=\"arrow\">\u2192<\/span> <span class=\"action\">Vercel \u81ea\u52a8\u90e8\u7f72<\/span> (ai.nickys.cn)<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class=\"arrow\">\u2193<\/span><br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\u81ea\u52a8\u540c\u6b65\u5230 web2 + nasweb\n<\/div>\n<div class=\"auto-tip\">\n  <strong>\ud83d\udca1 \u4e09\u4e2a\u5b57\uff1a\u5168\u81ea\u52a8\u3002<\/strong> \u6539\u4e86\u6587\u4ef6\uff0c\u7b49\u4e00\u5206\u949f\uff0c\u56db\u4e2a\u7ad9\u81ea\u52a8\u5230\u4f4d\u3002\n<\/div>\n<h3>GitHub \u79c1\u6709\u4ed3\u5e93<\/h3>\n<p>\u5728 GitHub \u4e0a\u5efa\u4e86\u4e00\u4e2a\u79c1\u6709\u4ed3\u5e93 <strong>nicky5760-collab\/default<\/strong>\uff0c\u5b58\u653e\u817e\u8baf\u4e91\u670d\u52a1\u5668\u7684\u5168\u90e8\u7f51\u7ad9\u6587\u4ef6\u3002\u79c1\u6709\u4ed3\u5e93\u4fdd\u8bc1\u4ee3\u7801\u5b89\u5168\uff0c\u5bc6\u94a5\u5bc6\u7801\u53ea\u6709\u81ea\u5df1\u80fd\u770b\u5230\u3002\u8bbe\u7f6e\u597d Personal Access Token\uff0c\u7ed9\u8db3\u6743\u9650\uff0c\u4e00\u6b21\u914d\u597d\u7ba1\u5230\u5e95\u3002<\/p>\n<h3>\u670d\u52a1\u5668\u5b9e\u65f6\u76d1\u63a7<\/h3>\n<p>\u817e\u8baf\u4e91\u4e0a\u8dd1\u4e86\u4e2a inotify \u76d1\u63a7\u811a\u672c\uff0c\u76ef\u7740\u7f51\u7ad9\u76ee\u5f55\u3002\u6587\u4ef6\u6709\u53d8\u52a8\uff08\u65b0\u589e\u3001\u4fee\u6539\u3001\u5220\u9664\uff09\uff0c60 \u79d2\u9632\u6296\u540e\u81ea\u52a8 git add\u3001commit\u3001push\u3002\u6bcf\u6b21\u53d8\u66f4\u81ea\u52a8\u63a8\u4e0a\u53bb\uff0c\u4e0d\u7528\u518d\u624b\u5de5\u64cd\u4f5c\u3002<\/p>\n<h3>Vercel \u81ea\u52a8\u90e8\u7f72<\/h3>\n<p>\u7f51\u7ad9\u7528\u7684 PHP\uff0cVercel \u9ed8\u8ba4\u4e0d\u652f\u6301\u3002\u89e3\u51b3\u65b9\u6848\u662f <strong>vercel-php<\/strong> \u8fd0\u884c\u65f6\uff0c\u52a0\u4e00\u4e2a <code>api\/router.php<\/code> \u8def\u7531\u5668\uff0c\u628a\u6240\u6709 PHP \u8bf7\u6c42\u8f6c\u53d1\u5230\u5bf9\u5e94\u6587\u4ef6\u3002GitHub \u4e00\u66f4\u65b0\uff0cVercel \u81ea\u52a8\u89e6\u53d1\u90e8\u7f72\u3002<\/p>\n<h3>\u4e09\u7ad9\u81ea\u52a8\u540c\u6b65<\/h3>\n<p>web2 \u548c nasweb \u90fd\u6ca1\u6709 Git \u73af\u5883\uff0c\u901a\u8fc7\u76d1\u63a7\u811a\u672c\u91cc\u7684 lftp \u81ea\u52a8\u540c\u6b65\u3002\u6bcf\u6b21 git push \u4e4b\u540e\uff0c\u53d8\u66f4\u7684\u6587\u4ef6\u81ea\u52a8\u540c\u6b65\u5230\u8fd9\u4e24\u4e2a\u7ad9\uff0c\u771f\u6b63\u7684\u4e09\u7ad9\u4e00\u4f53\u3002<\/p>\n<div class=\"auto-card green\">\n  <strong>\u2705 \u6548\u679c<\/strong> \u2014 \u56db\u4e2a\u7ad9\uff08web\u3001web2\u3001nasweb\u3001Vercel\uff09\u4e00\u6b21\u66f4\u65b0\uff0c\u5168\u90e8\u5230\u4f4d\n<\/div>\n<h3>\u8e29\u8fc7\u7684\u51e0\u4e2a\u5751<\/h3>\n<div class=\"auto-card\">\n  <strong>\ud83d\uded1 GitHub push protection<\/strong> \u2014 \u626b\u63cf\u5230\u5bc6\u94a5\u4f1a\u963b\u6b62\u63a8\u9001\u3002\u4f46\u79c1\u6709\u4ed3\u5e93\u4e0d\u4f1a\u963b\u6b62\uff0c\u53ea\u662f\u63d0\u9192\uff0c\u76f4\u63a5\u5ffd\u7565\u5c31\u884c\u3002\n<\/div>\n<div class=\"auto-card\">\n  <strong>\ud83d\uded1 Vercel \u51fd\u6570\u8def\u5f84\u9650\u5236<\/strong> \u2014 functions \u914d\u7f6e\u8981\u6c42 PHP \u6587\u4ef6\u5fc5\u987b\u653e\u5728 api\/ \u76ee\u5f55\u4e0b\u3002\u5199\u4e00\u4e2a <code>api\/router.php<\/code> \u505a\u4e2d\u8f6c\u5c31\u80fd\u7ed5\u8fc7\u3002\n<\/div>\n<div class=\"auto-card\">\n  <strong>\ud83d\uded1 lftp \u8d85\u65f6<\/strong> \u2014 \u7f51\u7edc\u4e0d\u7a33\u5b9a\u65f6\u5bb9\u6613\u6389\u7ebf\u3002\u52a0\u4e0a\u91cd\u8bd5\u53c2\u6570\u548c <code>-P3<\/code> \u5e76\u884c\u4f20\u8f93\u80fd\u6539\u5584\u3002\n<\/div>\n<div class=\"auto-summary\">\n  <strong>\ud83d\udccc \u603b\u7ed3<\/strong><\/p>\n<p>  \u8fd9\u5957\u65b9\u6848\u8dd1\u4e0b\u6765\uff0c\u6700\u8212\u670d\u7684\u662f\u4e0d\u7528\u518d\u8bb0&#8221;\u8fd9\u4e2a\u6587\u4ef6\u540c\u6b65\u4e86\u6ca1\u6709&#8221;\u3002\u6539\u4e86\u6587\u4ef6\uff0c\u7b49\u4e00\u5206\u949f\uff0c\u56db\u4e2a\u7ad9\uff08web\u3001web2\u3001nasweb\u3001Vercel\uff09\u81ea\u52a8\u5230\u4f4d\u3002GitHub \u4e0a\u8fd8\u6709\u5b8c\u6574\u7684\u5386\u53f2\u7248\u672c\uff0c\u6539\u9519\u4e86\u968f\u65f6\u56de\u9000\u3002<\/p>\n<p>  \u5bf9\u4e8e\u624b\u5934\u6709\u591a\u53f0\u670d\u52a1\u5668\u7684\u670b\u53cb\uff0cGitHub \u505a\u4e2d\u95f4\u67a2\u7ebd + \u670d\u52a1\u5668\u7aef\u5b9e\u65f6\u76d1\u63a7\uff0c\u6bd4\u624b\u52a8 FTP \u6328\u4e2a\u4f20\u9760\u8c31\u5f97\u591a\u3002\n<\/p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u2699\ufe0f \u6280\u672f\u65b9\u6848 \u4ece\u624b\u52a8\u5230\u5168\u81ea\u52a8 \u817e\u8baf\u4e91 + GitHub + Vercel + \u4e09\u7ad9\u8054\u52a8\uff0c\u4e00\u6b21\u914d\u597d\u7ba1\u5230\u4f4e \u6700\u8fd1 &#8230; <a title=\"\u7528 GitHub + Vercel \u642d\u4e86\u4e00\u5957\u5168\u81ea\u52a8\u7f51\u7ad9\u90e8\u7f72\u94fe\u8def\" class=\"read-more\" href=\"https:\/\/blog.nickys.cn\/?p=260\" aria-label=\"\u9605\u8bfb \u7528 GitHub + Vercel \u642d\u4e86\u4e00\u5957\u5168\u81ea\u52a8\u7f51\u7ad9\u90e8\u7f72\u94fe\u8def\">\u9605\u8bfb\u66f4\u591a<\/a><\/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":[],"class_list":["post-260","post","type-post","status-publish","format-standard","hentry","category-tech"],"_links":{"self":[{"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=\/wp\/v2\/posts\/260","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=260"}],"version-history":[{"count":1,"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=\/wp\/v2\/posts\/260\/revisions"}],"predecessor-version":[{"id":261,"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=\/wp\/v2\/posts\/260\/revisions\/261"}],"wp:attachment":[{"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=260"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=260"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.nickys.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=260"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}