Files
docker-docs/content/contribute/components/call-outs.md
T
Sarah Sanders 9f56d945a7 chore: summary bar cleanup (#21887)
## Description
- Updated "Contribute" guide to reference summary bars, added
instructions for using them
- Removed `introduced` partial, this is now replaced by the summary bar
`requires` value
- Updated all files using `introduced` partial to use summary bar,
updated YAML file w/ feature name and info

## Related issues or tickets
[ENGDOCS-2392](https://docker.atlassian.net/browse/ENGDOCS-2392)

## Reviews
- [ ] Technical review
- [ ] Editorial review

[ENGDOCS-2392]:
https://docker.atlassian.net/browse/ENGDOCS-2392?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
2025-01-30 07:54:26 -08:00

3.7 KiB

description, title, toc_max
description title toc_max
components and formatting examples used in Docker's docs Callouts 3

We support these broad categories of callouts:

  • Alerts: Note, Tip, Important, Warning, Caution

We also support summary bars, which represent a feature's required subscription, version, or Adminstrator role. To add a summary bar:

Add the feature name to the /data/summary.yaml file. Use the following attributes:

Attribute Description Possible values
subscription Notes the subscription required to use the feature All, Personal, Pro, Team, Business
availability Notes what product development stage the feature is in Experimental, Beta, Early access, GA, Retired
requires Notes what minimum version is required for the feature No specific value, use a string to describe the version and link to relevant release notes
for Notes if the feature is intended for IT Administrators Administrators

Then, add the summary-bar shortcode on the page you want to add the summary bar to. Note, the feature name is case sensitive. The icons that appear in the summary bar are automatically rendered.

Examples

{{< 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.

For both of the following callouts, consult the Docker release lifecycle for more information on when to use them.

Formatting

> {{< 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.