docs(deploy): document gitea registry image path
Docker Image / Build and Push Docker Image (push) Failing after 19s

This commit is contained in:
2026-07-07 12:02:25 +08:00
parent 8f60c7fd82
commit 5b793b825e
3 changed files with 10 additions and 10 deletions
+3 -3
View File
@@ -95,14 +95,14 @@ production root@43.106.13.130:/root/cozsweet-repos/main
```env
COZSWEET_DEPLOY_IMAGE_SOURCE=pull
COZSWEET_REGISTRY_IMAGE=registry.example.com/cozsweet/cozsweet-web
COZSWEET_REGISTRY_IMAGE=gitea.banlv-ai.com/admin/cozsweet-web
```
默认远程镜像 tag 为 `<deploy_env>-<short_sha>`
```text
registry.example.com/cozsweet/cozsweet-web:test-<commit>
registry.example.com/cozsweet/cozsweet-web:prod-<commit>
gitea.banlv-ai.com/admin/cozsweet-web:test-<commit>
gitea.banlv-ai.com/admin/cozsweet-web:prod-<commit>
```
也可以在服务器本地 `.deploy.env` 中覆盖为 latest tag
+5 -5
View File
@@ -19,8 +19,8 @@
| Secret | 示例 | 说明 |
| --- | --- | --- |
| `REGISTRY_HOST` | `registry.example.com` | `docker login` 使用的镜像仓库地址 |
| `REGISTRY_IMAGE` | `registry.example.com/cozsweet/cozsweet-web` | 完整镜像仓库名,不包含 tag |
| `REGISTRY_HOST` | `gitea.banlv-ai.com` | `docker login` 使用的镜像仓库地址 |
| `REGISTRY_IMAGE` | `gitea.banlv-ai.com/admin/cozsweet-web` | 完整镜像仓库名,不包含 tag |
| `REGISTRY_USERNAME` | `cozsweet-bot` | 镜像仓库用户名 |
| `REGISTRY_PASSWORD` | `***` | 镜像仓库密码或访问令牌 |
| `TEST_ENV_FILE` | `.env.local` 的完整内容 | 测试环境构建期环境变量 |
@@ -106,14 +106,14 @@ cp env-example/.deploy.env.example .deploy.env
```env
COZSWEET_DEPLOY_IMAGE_SOURCE=pull
COZSWEET_REGISTRY_IMAGE=registry.example.com/cozsweet/cozsweet-web
COZSWEET_REGISTRY_IMAGE=gitea.banlv-ai.com/admin/cozsweet-web
```
`post-receive` 会根据当前分支和 commit 自动拉取:
```bash
registry.example.com/cozsweet/cozsweet-web:test-<short_sha>
registry.example.com/cozsweet/cozsweet-web:prod-<short_sha>
gitea.banlv-ai.com/admin/cozsweet-web:test-<short_sha>
gitea.banlv-ai.com/admin/cozsweet-web:prod-<short_sha>
```
如果需要改用 latest tag,可以在服务器 `.deploy.env` 中显式设置:
+2 -2
View File
@@ -8,8 +8,8 @@ COZSWEET_DEPLOY_IMAGE_SOURCE=pull
# Full image repository without tag.
# Example:
# COZSWEET_REGISTRY_IMAGE=registry.example.com/cozsweet/cozsweet-web
COZSWEET_REGISTRY_IMAGE=
# COZSWEET_REGISTRY_IMAGE=gitea.banlv-ai.com/admin/cozsweet-web
COZSWEET_REGISTRY_IMAGE=gitea.banlv-ai.com/admin/cozsweet-web
# Optional. Defaults to <deploy_env>-<short_sha>, for example:
# - test-abc1234 on test branch