diff --git a/README.md b/README.md index 348f401..5a82dfc 100644 --- a/README.md +++ b/README.md @@ -118,6 +118,33 @@ http://服务器IP:18080 仓库里的 `docker-compose.yml` 已经是最简单模板:默认不用 `.env`。 +### 镜像地址怎么选 + +两种镜像地址都可以用,选择其中一种写到 `image:` 即可: + +| 来源 | 镜像地址 | 适合场景 | +| --- | --- | --- | +| Docker Hub | `shukbet/mediastationgo:latest` | 最常用,直接 `docker compose pull` | +| GitHub 仓库镜像 GHCR | `ghcr.io/shukebta/mediastation-go:latest` | Docker Hub 拉取慢或不可用时备用 | + +如果想固定版本,推荐使用 Docker Hub 已发布版本标签,例如: + +```yaml +image: shukbet/mediastationgo:MediaStationGo-v0.0.72 +``` + +GHCR 固定版本请以仓库 Packages 页面已发布的标签为准;如果只想简单部署,直接使用 `latest` 即可。 + +手动拉取示例: + +```bash +# Docker Hub +docker pull shukbet/mediastationgo:latest + +# GitHub 仓库镜像 +docker pull ghcr.io/shukebta/mediastation-go:latest +``` + 你只需要重点看 `volumes` 这一段: ```yaml @@ -173,7 +200,12 @@ environment: ```yaml services: mediastation-go: - image: ghcr.io/shukebta/mediastation-go:latest + # 镜像二选一: + # Docker Hub: + image: shukbet/mediastationgo:latest + # GitHub 仓库镜像 GHCR: + # image: ghcr.io/shukebta/mediastation-go:latest + container_name: mediastation-go restart: unless-stopped init: true diff --git a/README_EN.md b/README_EN.md index c1824c6..bad5fcb 100644 --- a/README_EN.md +++ b/README_EN.md @@ -118,6 +118,33 @@ Password: admin123 The repository `docker-compose.yml` is intentionally simple and does not require `.env`. +### Choose an image source + +Both image sources are supported. Pick one and put it in `image:`: + +| Source | Image | Best for | +| --- | --- | --- | +| Docker Hub | `shukbet/mediastationgo:latest` | Most common deployments, simple `docker compose pull` | +| GitHub Container Registry (GHCR) | `ghcr.io/shukebta/mediastation-go:latest` | Backup source when Docker Hub is slow or unavailable | + +To pin a version, use a published Docker Hub version tag: + +```yaml +image: shukbet/mediastationgo:MediaStationGo-v0.0.72 +``` + +For pinned GHCR versions, use the tags published on the repository Packages page. For the simplest setup, keep `latest`. + +Manual pull examples: + +```bash +# Docker Hub +docker pull shukbet/mediastationgo:latest + +# GitHub Container Registry +docker pull ghcr.io/shukebta/mediastation-go:latest +``` + Focus on this part: ```yaml @@ -173,7 +200,12 @@ The root `docker-compose.yml` follows this style: ```yaml services: mediastation-go: - image: ghcr.io/shukebta/mediastation-go:latest + # Pick one image source: + # Docker Hub: + image: shukbet/mediastationgo:latest + # GitHub Container Registry (GHCR): + # image: ghcr.io/shukebta/mediastation-go:latest + container_name: mediastation-go restart: unless-stopped init: true diff --git a/docker-compose.yml b/docker-compose.yml index fa6768b..6ec8edf 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -16,7 +16,12 @@ services: mediastation-go: - image: ghcr.io/shukebta/mediastation-go:latest + # 镜像二选一: + # 方式一:Docker Hub(默认,推荐) + image: shukbet/mediastationgo:latest + # 方式二:GitHub 仓库镜像 GHCR(Docker Hub 拉取慢或不可用时使用) + # image: ghcr.io/shukebta/mediastation-go:latest + container_name: mediastation-go restart: unless-stopped init: true