docs: make Chinese README the default
container project - merge build / Invoke build (push) Successful in 1s
container project - merge build / Invoke build (push) Successful in 1s
This commit is contained in:
@@ -1,92 +1,98 @@
|
||||
<!-- WEHUB_ZH_README -->
|
||||
> [!NOTE]
|
||||
> 本文档由 WeHub 基于上游 README 翻译整理,属于社区翻译,非官方中文文档。
|
||||
> [English](./README.en.md) · [原始项目](https://github.com/apple/container) · [上游 README](https://github.com/apple/container/blob/HEAD/README.md)
|
||||
> 原作者、版权与许可证归属以原始项目及本仓库 LICENSE 文件为准。
|
||||
|
||||
<h1>
|
||||
<img alt="Containerization logo" src="./assets/Containerization-Logo.png" width="70" valign="middle">
|
||||
<img alt="Containerization 徽标" src="./assets/Containerization-Logo.png" width="70" valign="middle">
|
||||
container
|
||||
</h1>
|
||||
|
||||
`container` is a tool that you can use to create and run Linux containers as lightweight virtual machines on your Mac. It's written in Swift, and optimized for Apple silicon.
|
||||
`container` 是一款工具,可用于在 Mac 上以轻量级虚拟机的方式创建和运行 Linux 容器。它使用 Swift 编写,并针对 Apple 芯片进行了优化。
|
||||
|
||||
The tool consumes and produces [OCI-compatible container images](https://github.com/opencontainers/image-spec), so you can pull and run images from any standard container registry. You can push images that you build to those registries as well, and run the images in any other OCI-compatible application.
|
||||
该工具可消费并生成 [OCI 兼容的容器镜像](https://github.com/opencontainers/image-spec),,因此你可以从任何标准容器镜像仓库拉取并运行镜像。你也可以将构建的镜像推送到这些仓库,并在任何其他 OCI 兼容应用中运行这些镜像。
|
||||
|
||||
`container` uses the [Containerization](https://github.com/apple/containerization) Swift package for low-level container, image, and process management.
|
||||
`container` 使用 [Containerization](https://github.com/apple/containerization) Swift 包来进行底层容器、镜像和进程管理。
|
||||
|
||||

|
||||

|
||||
|
||||
## Get started
|
||||
## 快速开始
|
||||
|
||||
### Requirements
|
||||
### 系统要求
|
||||
|
||||
You need a Mac with Apple silicon to run `container`. To build it, see the [BUILDING](./BUILDING.md) document.
|
||||
你需要一台搭载 Apple 芯片的 Mac 才能运行 `container`。若要构建它,请参阅 [BUILDING](./BUILDING.md) 文档。
|
||||
|
||||
`container` is supported on macOS 26, since it takes advantage of new features and enhancements to virtualization and networking in this release. We do not support older versions of macOS and the `container` maintainers typically will not address issues that cannot be reproduced on macOS 26.
|
||||
`container` 支持 macOS 26,因为它利用了该版本在虚拟化和网络方面的新功能与增强特性。我们不支持更早版本的 macOS,且 `container` 的维护者通常不会处理无法在 macOS 26 上复现的问题。
|
||||
|
||||
### Initial install
|
||||
### 初次安装
|
||||
|
||||
Download the latest signed installer package for `container` from the [GitHub release page](https://github.com/apple/container/releases).
|
||||
从 [GitHub 发布页面](https://github.com/apple/container/releases). 下载 `container` 的最新签名安装包。
|
||||
|
||||
To install the tool, double-click the package file and follow the instructions. Enter your administrator password when prompted, to give the installer permission to place the installed files under `/usr/local`.
|
||||
要安装该工具,请双击安装包文件并按说明操作。在提示时输入管理员密码,以授予安装程序将文件安装到 `/usr/local` 下的权限。
|
||||
|
||||
Start the system service with:
|
||||
使用以下命令启动系统服务:
|
||||
|
||||
```bash
|
||||
container system start
|
||||
```
|
||||
|
||||
### Upgrade or downgrade
|
||||
### 升级或降级
|
||||
|
||||
For both upgrading and downgrading, you can manually download and install the signed installer package by following the steps from [initial install](#initial-install) or use the `update-container.sh` script (installed to `/usr/local/bin`).
|
||||
无论是升级还是降级,你都可以按照 [初次安装](#initial-install) 中的步骤手动下载并安装签名安装包,或使用 `update-container.sh` 脚本(安装于 `/usr/local/bin`)。
|
||||
|
||||
If you're upgrading or downgrading, you must stop your existing `container`:
|
||||
如果你正在升级或降级,必须先停止现有的 `container`:
|
||||
|
||||
```bash
|
||||
container system stop
|
||||
```
|
||||
|
||||
To upgrade to the latest release, simply run the command below:
|
||||
要升级到最新版本,只需运行以下命令:
|
||||
|
||||
```bash
|
||||
/usr/local/bin/update-container.sh
|
||||
```
|
||||
|
||||
To downgrade, you must uninstall your existing `container` (the `-k` flag keeps your user data, while `-d` removes it):
|
||||
要降级,你必须先卸载现有的 `container`(`-k` 标志会保留你的用户数据,而 `-d` 会将其删除):
|
||||
|
||||
```bash
|
||||
/usr/local/bin/uninstall-container.sh -k
|
||||
/usr/local/bin/update-container.sh -v 0.3.0
|
||||
```
|
||||
|
||||
Start the system service with:
|
||||
使用以下命令启动系统服务:
|
||||
|
||||
```bash
|
||||
container system start
|
||||
```
|
||||
|
||||
### Uninstall
|
||||
### 卸载
|
||||
|
||||
Use the `uninstall-container.sh` script (installed to `/usr/local/bin`) to remove `container` from your system. To remove your user data along with the tool, run:
|
||||
使用 `uninstall-container.sh` 脚本(安装于 `/usr/local/bin`)从系统中移除 `container`。若要同时删除用户数据,请运行:
|
||||
|
||||
```bash
|
||||
/usr/local/bin/uninstall-container.sh -d
|
||||
```
|
||||
|
||||
To retain your user data so that it is available should you reinstall later, run:
|
||||
若要保留用户数据以便日后重新安装时仍可使用,请运行:
|
||||
|
||||
```bash
|
||||
/usr/local/bin/uninstall-container.sh -k
|
||||
```
|
||||
|
||||
## Next steps
|
||||
## 后续步骤
|
||||
|
||||
- Take [a guided tour of `container`](./docs/tutorials/start-here.md) by building, running, and publishing a simple web server image.
|
||||
- Learn how to [use various `container` features](./docs/how-to.md).
|
||||
- Read a brief description and [technical overview](./docs/technical-overview.md) of `container`.
|
||||
- Browse the [full command reference](./docs/command-reference.md).
|
||||
- [Build and run](./BUILDING.md) `container` on your own development system.
|
||||
- View the project [API documentation](https://apple.github.io/container/documentation/).
|
||||
- 参加 [`container` 引导式导览](./docs/tutorials/start-here.md),通过构建、运行并发布一个简单的 Web 服务器镜像。
|
||||
- 了解如何 [使用 `container` 的各项功能](./docs/how-to.md)。
|
||||
- 阅读 `container` 的简要说明与 [技术概览](./docs/technical-overview.md)。
|
||||
- 浏览 [完整命令参考](./docs/command-reference.md)。
|
||||
- 在你自己的开发系统上 [构建并运行](./BUILDING.md) `container`。
|
||||
- 查看项目 [API 文档](https://apple.github.io/container/documentation/).
|
||||
|
||||
## Contributing
|
||||
## 参与贡献
|
||||
|
||||
Contributions to `container` are welcome and encouraged. Please see our [main contributing guide](https://github.com/apple/containerization/blob/main/CONTRIBUTING.md) for more information.
|
||||
欢迎并鼓励为 `container` 做出贡献。更多信息请参阅我们的 [主要贡献指南](https://github.com/apple/containerization/blob/main/CONTRIBUTING.md)。
|
||||
|
||||
## Project Status
|
||||
## 项目状态
|
||||
|
||||
The container project is currently under active development. Its stability, both for consuming the project as a Swift package and the `container` tool, is only guaranteed within patch versions, such as between 0.1.1 and 0.1.2. Minor version releases may include breaking changes until we reach a 1.0.0 release.
|
||||
container 项目目前处于积极开发中。无论是作为 Swift 包消费该项目,还是使用 `container` 工具,其稳定性仅在补丁版本之间得到保证,例如 0.1.1 与 0.1.2 之间。在我们发布 1.0.0 版本之前,次要版本发布可能包含破坏性变更。
|
||||
|
||||
Reference in New Issue
Block a user