标注
目录
我们支持以下几类标注
- 提醒:注意、提示、重要、警告、小心
我们还支持摘要条,用于指示某个功能所需的订阅、版本或管理员角色。要添加摘要条,请执行以下操作
将功能名称添加到 /data/summary.yaml
文件中。使用以下属性
属性 | 描述 | 可能的值 |
---|---|---|
订阅 | 指明使用该功能所需的订阅 | 所有、个人、专业版、团队版、商业版 |
可用性 | 指明该功能处于哪个产品开发阶段 | 实验性、测试版、抢先体验、正式发布、已弃用 |
要求 | 指明使用该功能所需的最低版本 | 没有特定值,使用字符串描述版本并链接到相关的发行说明 |
适用于 | 指明该功能是否适用于 IT 管理员 | 管理员 |
然后,在要添加摘要条的页面上添加 summary-bar
Shortcode。请注意,功能名称区分大小写。摘要条中显示的图标会自动渲染。
示例
注意
请注意
get_hit_count
函数的编写方式。如果 redis 服务不可用,这个基本的重试循环允许我们多次尝试请求。这在应用程序启动时非常有用,同时也可以使我们的应用程序更具弹性,即使在应用程序的生命周期内 Redis 服务需要随时重启。在集群中,这也有助于处理节点之间的瞬时连接中断。
提示
对于更小的基础镜像,请使用
alpine
。
重要
请像对待密码一样对待访问令牌,并将其保密。请安全地存储您的令牌(例如,在凭据管理器中)。
警告
删除卷
默认情况下,运行
docker compose down
时不会删除 compose 文件中的命名卷。如果您想删除卷,需要添加--volumes
标志。当您删除应用程序堆栈时,Docker Desktop Dashboard 不会删除卷。
小心
此处有龙。
对于以下两种标注,请查阅 Docker 发行生命周期 以获取何时使用它们的更多信息。
格式
{{< summary-bar feature_name="PKG installer" >}}
> [!NOTE]
>
> Note the way the `get_hit_count` function is written. This basic retry
> loop lets us attempt our request multiple times if the redis service is
> not available. This is useful at startup while the application comes
> online, but also makes our application more resilient if the Redis
> service needs to be restarted anytime during the app's lifetime. In a
> cluster, this also helps handling momentary connection drops between
> nodes.
> [!TIP]
>
> For a smaller base image, use `alpine`.
> [!IMPORTANT]
>
> Treat access tokens like your password and keep them secret. Store your
> tokens securely (for example, in a credential manager).
> [!WARNING]
>
> Removing Volumes
>
> By default, named volumes in your compose file are NOT removed when running
> `docker compose down`. If you want to remove the volumes, you will need to add
> the `--volumes` flag.
>
> The Docker Desktop Dashboard does not remove volumes when you delete the app stack.
> [!CAUTION]
>
> Here be dragons.