<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>镜像 on Last Stand</title><link>https://amatsuzero.github.io/LastStand/tags/%E9%95%9C%E5%83%8F/</link><description>Recent content in 镜像 on Last Stand</description><generator>Hugo</generator><language>zh-cn</language><lastBuildDate>Wed, 21 Oct 2026 14:06:24 +0800</lastBuildDate><atom:link href="https://amatsuzero.github.io/LastStand/tags/%E9%95%9C%E5%83%8F/index.xml" rel="self" type="application/rss+xml"/><item><title>UgreenHome CocoaPods Specs / 镜像 tag 故障复盘</title><link>https://amatsuzero.github.io/LastStand/posts/ugreen-notes/ugreenhome-cocoapods-spec-mirror/</link><pubDate>Wed, 21 Oct 2026 14:06:24 +0800</pubDate><guid>https://amatsuzero.github.io/LastStand/posts/ugreen-notes/ugreenhome-cocoapods-spec-mirror/</guid><description>&lt;h2 id="背景与现象"&gt;背景与现象&lt;/h2&gt;
&lt;p&gt;主工程使用内部 CocoaPods Specs 仓库。某些源码 pod 的 source.git 指向内部 GitLab 镜像；另一些第三方依赖由 &lt;code&gt;*-bin&lt;/code&gt; spec 提供预编译 XCFramework。FCUUID-bin 的 spec 声明了对源码 pod UICKeyChainStore (~&amp;gt; 2.1.0) 的依赖，而主工程此前没有直接声明 UICKeyChainStore。&lt;/p&gt;
&lt;p&gt;删除 iot/Podfile.lock 后运行 &lt;code&gt;make -C iot pods&lt;/code&gt;，CocoaPods 重新解析传递依赖，选中了 Specs 中的 UICKeyChainStore 2.1.3。该 spec 指向镜像中不存在的 v2.1.1 tag，安装失败，典型报错是 &lt;code&gt;fatal: Remote branch v2.1.1 not found in upstream origin&lt;/code&gt;。这发生在依赖解析、源码获取阶段，尚未进入 App 链接。&lt;/p&gt;
&lt;p&gt;主工程 Podfile → FCUUID-bin 1.3.3.1 → UICKeyChainStore (~&amp;gt; 2.1.0) [传递源码依赖] → 无 lock 时选到 2.1.3 → source.tag = v2.1.1 [镜像不存在] → make pods 失败。&lt;/p&gt;</description></item><item><title>UDC 镜像仓库迁移踩坑记录</title><link>https://amatsuzero.github.io/LastStand/posts/ugreen-notes/udc-mirror-migration/</link><pubDate>Wed, 21 Oct 2026 13:55:41 +0800</pubDate><guid>https://amatsuzero.github.io/LastStand/posts/ugreen-notes/udc-mirror-migration/</guid><description>&lt;h2 id="背景"&gt;背景&lt;/h2&gt;
&lt;p&gt;一次把 UDC 相关仓库从外部 GitLab 源迁到内网 GitLab + Nexus 的迁移，踩了十来个坑。本文把每个坑的「现象 → 根因 → 修复」记下来，方便后续再做类似镜像同步时直接对照。迁移目标是：把外部源（记为 gitlab-cloud）的仓库改写成指向内网 GitLab 的 podspec，并同步 Maven 产物到内网 Nexus。&lt;/p&gt;
&lt;h2 id="名词解释"&gt;名词解释&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Pull Mirror（GitLab 原生镜像）&lt;/strong&gt;：GitLab 自带的仓库镜像功能，让镜像仓库与上游完全一致。&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Nexus&lt;/strong&gt;：内网私有仓库（Maven / raw 等），用来托管同步过来的二进制与 Maven 产物。&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Protected 变量&lt;/strong&gt;：GitLab CI 变量标记为 Protected 后，只在保护分支 / 标签上注入。&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;members/all&lt;/strong&gt;：GitLab 查组成员接口，带 /all 才会包含从父组继承的成员。&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="一gitlab-原生镜像根本没法用"&gt;一、GitLab 原生镜像根本没法用&lt;/h2&gt;
&lt;p&gt;一开始想直接用 GitLab 自带的 Repository Mirroring（pull mirror），结果它和「改写 podspec URL」的需求天然冲突：原生 pull mirror 会让镜像仓库与上游完全一致，等于把我们在内网侧做的 podspec URL 改写每次同步都覆盖回去。而且源仓库里的 podspec 仍带外部域名，我们用的同步 bot 是源项目的只读成员，push 回源会 403 &amp;ldquo;not allowed to upload code&amp;rdquo;——源仓库修不了。&lt;/p&gt;</description></item></channel></rss>