<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>开发运维 - 分类 - 南冥鹏影</title><link>https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/</link><description>南冥鹏影</description><generator>Hugo 0.168.0 &amp; FixIt v1.0.0-beta.4</generator><language>zh-CN</language><lastBuildDate>Thu, 15 Oct 2026 17:59:10 +0800</lastBuildDate><atom:link href="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/index.xml" rel="self" type="application/rss+xml"/><item><title>Systemd + Uvicorn + FastAPI 部署</title><link>https://fupcode.com/blog/posts/devops/systemd-uvicorn-fastapi/</link><pubDate>Sat, 05 Sep 2026 18:19:11 +0800</pubDate><guid>https://fupcode.com/blog/posts/devops/systemd-uvicorn-fastapi/</guid><category domain="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/">开发运维</category><description>使用 systemd 管理 Uvicorn 运行 FastAPI，配置开机启动、异常重启、日志查看和 NGINX 反向代理。</description></item><item><title>Docker 容器时区问题：UTC 导致的自然日业务刷新异常</title><link>https://fupcode.com/blog/posts/devops/problem-docker-timezone/</link><pubDate>Tue, 19 May 2026 17:38:41 +0800</pubDate><guid>https://fupcode.com/blog/posts/devops/problem-docker-timezone/</guid><category domain="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/">开发运维</category><description>&lt;p&gt;最近将微信小程序后端迁移到 Docker 后，出现了“每日刷新”相关 Bug，例如：&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;每日广告次数未刷新&lt;/li&gt;&#10;&lt;li&gt;次日仍然沿用前一天状态&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;p&gt;排查后发现，问题并不在业务逻辑，而是：&lt;/p&gt;</description></item><item><title>使用 Certbot --webroot 模式为 Nginx 配置 HTTPS</title><link>https://fupcode.com/blog/posts/devops/certbot-webroot/</link><pubDate>Tue, 19 May 2026 03:04:28 +0800</pubDate><guid>https://fupcode.com/blog/posts/devops/certbot-webroot/</guid><category domain="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/">开发运维</category><description>&lt;p&gt;之前我一直使用：&lt;/p&gt;&#10;&lt;pre&gt;&lt;code&gt;certbot --nginx&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;来自动申请和配置 HTTPS 证书。&lt;/p&gt;&#10;&lt;p&gt;这种方法虽然方便，但在实际使用中，我遇到了比较严重的问题：&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;certbot 会自动修改 nginx 配置&lt;/li&gt;&#10;&lt;li&gt;certbot 会自动 reload/restart nginx，导致systemd 状态与 nginx 实际状态脱节，出现“游离 nginx”，然后第一个证书成功、后面失败&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;p&gt;最终决定迁移到：&lt;/p&gt;</description></item><item><title>Docker 挂载单个文件的一个隐蔽 Bug：修改后容器和宿主机会“分离”</title><link>https://fupcode.com/blog/posts/devops/problem-docker-volume-edit-bug/</link><pubDate>Thu, 12 Mar 2026 19:11:13 +0800</pubDate><guid>https://fupcode.com/blog/posts/devops/problem-docker-volume-edit-bug/</guid><category domain="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/">开发运维</category><description>&lt;h2 class="heading-element" id="问题背景"&gt;&lt;span&gt;问题背景&lt;/span&gt;&#13;&#10; &lt;a href="#%e9%97%ae%e9%a2%98%e8%83%8c%e6%99%af" class="heading-mark"&gt;&lt;svg class="octicon octicon-link" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"&gt;&lt;path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/a&gt;&#13;&#10;&lt;/h2&gt;&lt;p&gt;Docker Compose 里经常会把单个配置文件 bind mount 到容器中：&lt;/p&gt;</description></item><item><title>VPS 的默认配置</title><link>https://fupcode.com/blog/posts/devops/vps-configure/</link><pubDate>Thu, 26 Feb 2026 17:36:17 +0800</pubDate><guid>https://fupcode.com/blog/posts/devops/vps-configure/</guid><category domain="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/">开发运维</category><description>&lt;h2 class="heading-element" id="一系统配置"&gt;&lt;span&gt;一、系统配置&lt;/span&gt;&#13;&#10; &lt;a href="#%e4%b8%80%e7%b3%bb%e7%bb%9f%e9%85%8d%e7%bd%ae" class="heading-mark"&gt;&lt;svg class="octicon octicon-link" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"&gt;&lt;path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/a&gt;&#13;&#10;&lt;/h2&gt;&lt;h3 class="heading-element" id="更新系统"&gt;&lt;span&gt;更新系统&lt;/span&gt;&#13;&#10; &lt;a href="#%e6%9b%b4%e6%96%b0%e7%b3%bb%e7%bb%9f" class="heading-mark"&gt;&lt;svg class="octicon octicon-link" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"&gt;&lt;path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/a&gt;&#13;&#10;&lt;/h3&gt;&lt;pre&gt;&lt;code&gt;apt update &amp;amp;&amp;amp; apt full-upgrade -y &amp;amp;&amp;amp; apt autoremove -y &amp;amp;&amp;amp; apt autoclean -y&lt;/code&gt;&lt;/pre&gt;&lt;h3 class="heading-element" id="安装常用工具"&gt;&lt;span&gt;安装常用工具&lt;/span&gt;&#13;&#10; &lt;a href="#%e5%ae%89%e8%a3%85%e5%b8%b8%e7%94%a8%e5%b7%a5%e5%85%b7" class="heading-mark"&gt;&lt;svg class="octicon octicon-link" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"&gt;&lt;path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/a&gt;&#13;&#10;&lt;/h3&gt;&lt;pre&gt;&lt;code&gt;apt install sudo htop git wget curl vim tmux net-tools unattended-upgrades fail2ban -y&lt;/code&gt;&lt;/pre&gt;&lt;h3 class="heading-element" id="配置自动更新策略"&gt;&lt;span&gt;配置自动更新策略&lt;/span&gt;&#13;&#10; &lt;a href="#%e9%85%8d%e7%bd%ae%e8%87%aa%e5%8a%a8%e6%9b%b4%e6%96%b0%e7%ad%96%e7%95%a5" class="heading-mark"&gt;&lt;svg class="octicon octicon-link" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"&gt;&lt;path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/a&gt;&#13;&#10;&lt;/h3&gt;&lt;p&gt;编辑文件：&lt;/p&gt;</description></item><item><title>重定向导致微信小程序只在正式版出现接口报错 code 600002, url not in domain list</title><link>https://fupcode.com/blog/posts/devops/problem-wx307/</link><pubDate>Sat, 29 Nov 2025 06:42:35 +0800</pubDate><guid>https://fupcode.com/blog/posts/devops/problem-wx307/</guid><category domain="https://fupcode.com/blog/categories/%E5%BC%80%E5%8F%91%E8%BF%90%E7%BB%B4/">开发运维</category><description>&lt;p&gt;最近在将自研小程序从测试版发布到正式版时，遇到了一个非常奇怪的坑：接口在本地开发和测试环境中一切正常，但一旦发布到正式版，就出现了 &lt;strong&gt;code &lt;code&gt;600002&lt;/code&gt;&lt;/strong&gt; 的报错，提示 &lt;strong&gt;URL not in domain list&lt;/strong&gt;。&lt;/p&gt;</description></item></channel></rss>