Add admonition type to shortcode (#9482)

* Change existing admon blocks

* Fix includes issue
This commit is contained in:
Luc Perkins
2018-11-06 11:33:04 -08:00
committed by k8s-ci-robot
parent e839031292
commit d65e1790ff
192 changed files with 673 additions and 543 deletions
@@ -60,7 +60,7 @@ annotation on each object. The annotation contains the contents of the object
configuration file that was used to create the object.
{{< note >}}
**Note:** Add the `-R` flag to recursively process directories.
Add the `-R` flag to recursively process directories.
{{< /note >}}
Here's an example of an object configuration file:
@@ -134,7 +134,7 @@ kubectl apply -f <directory>/
```
{{< note >}}
**Note:** Add the `-R` flag to recursively process directories.
Add the `-R` flag to recursively process directories.
{{< /note >}}
Here's an example configuration file:
@@ -148,7 +148,7 @@ kubectl apply -f https://k8s.io/examples/application/simple_deployment.yaml
```
{{< note >}}
**Note:** For purposes of illustration, the preceding command refers to a single
For purposes of illustration, the preceding command refers to a single
configuration file instead of a directory.
{{< /note >}}
@@ -322,7 +322,7 @@ spec:
```
{{< warning >}}
**Warning:** Mixing `kubectl apply` with the imperative object configuration commands
Mixing `kubectl apply` with the imperative object configuration commands
`create` and `replace` is not supported. This is because `create`
and `replace` do not retain the `kubectl.kubernetes.io/last-applied-configuration`
that `kubectl apply` uses to compute updates.
@@ -347,12 +347,12 @@ kubectl delete -f <filename>
Only use this if you know what you are doing.
{{< warning >}}
**Warning:** `kubectl apply --prune` is in alpha, and backwards incompatible
`kubectl apply --prune` is in alpha, and backwards incompatible
changes might be introduced in subsequent releases.
{{< /warning >}}
{{< warning >}}
**Warning:** You must be careful when using this command, so that you
You must be careful when using this command, so that you
do not delete objects unintentionally.
{{< /warning >}}
@@ -373,7 +373,7 @@ kubectl apply -f <directory/> --prune -l <labels>
```
{{< warning >}}
**Warning:** Apply with prune should only be run against the root directory
Apply with prune should only be run against the root directory
containing the object configuration files. Running against sub-directories
can cause objects to be unintentionally deleted if they are returned
by the label selector query specified with `-l <labels>` and
@@ -391,10 +391,9 @@ kubectl get -f <filename|url> -o yaml
## How apply calculates differences and merges changes
{{< caution >}}
**Caution:** A *patch* is an update operation that is scoped to specific
fields of an object instead of the entire object.
This enables updating only a specific set of fields on an object without
reading the object first.
A *patch* is an update operation that is scoped to specific fields of an object
instead of the entire object. This enables updating only a specific set of fields
on an object without reading the object first.
{{< /caution >}}
When `kubectl apply` updates the live configuration for an object,
@@ -546,7 +545,7 @@ and merged.
Primitive fields are replaced or cleared.
{{< note >}}
**Note:** '-' is used for "not applicable" because the value is not used.
`-` is used for "not applicable" because the value is not used.
{{< /note >}}
| Field in object configuration file | Field in live object configuration | Field in last-applied-configuration | Action |
@@ -561,7 +560,7 @@ Primitive fields are replaced or cleared.
Fields that represent maps are merged by comparing each of the subfields or elements of the map:
{{< note >}}
**Note:** '-' is used for "not applicable" because the value is not used.
`-` is used for "not applicable" because the value is not used.
{{< /note >}}
| Key in object configuration file | Key in live object configuration | Field in last-applied-configuration | Action |
@@ -689,7 +688,7 @@ by `name`.
As of Kubernetes 1.5, merging lists of primitive elements is not supported.
{{< note >}}
**Note:** Which of the above strategies is chosen for a given field is controlled by
Which of the above strategies is chosen for a given field is controlled by
the `patchStrategy` tag in [types.go](https://git.k8s.io/api/core/v1/types.go#L2565)
If no `patchStrategy` is specified for a field of type list, then
the list is replaced.
@@ -900,7 +899,7 @@ Kubernetes objects should be managed using only one method at a time.
Switching from one method to another is possible, but is a manual process.
{{< note >}}
**Note:** It is OK to use imperative deletion with declarative management.
It is OK to use imperative deletion with declarative management.
{{< /note >}}
{{< comment >}}
@@ -924,8 +923,10 @@ configuration involves several manual steps:
1. Manually remove the `status` field from the configuration file.
{{< note >}}**Note:** This step is optional, as `kubectl apply` does not update the status field
even if it is present in the configuration file.{{< /note >}}
{{< note >}}
This step is optional, as `kubectl apply` does not update the status field
even if it is present in the configuration file.
{{< /note >}}
1. Set the `kubectl.kubernetes.io/last-applied-configuration` annotation on the object:
@@ -952,7 +953,7 @@ TODO(pwittrock): Why doesn't export remove the status field? Seems like it shou
## Defining controller selectors and PodTemplate labels
{{< warning >}}
**Warning:** Updating selectors on controllers is strongly discouraged.
Updating selectors on controllers is strongly discouraged.
{{< /warning >}}
The recommended approach is to define a single, immutable PodTemplate label
@@ -76,8 +76,7 @@ Setting this aspect may set different fields for different object types:
- `set` <field>: Set an aspect of an object.
{{< note >}}
**Note**: In Kubernetes version 1.5, not every verb-driven command has an
associated aspect-driven command.
In Kubernetes version 1.5, not every verb-driven command has an associated aspect-driven command.
{{< /note >}}
The `kubectl` tool supports these additional ways to update a live object directly,
@@ -95,7 +94,7 @@ You can use the `delete` command to delete an object from a cluster:
- `delete <type>/<name>`
{{< note >}}
**Note**: You can use `kubectl delete` for both imperative commands and imperative object
You can use `kubectl delete` for both imperative commands and imperative object
configuration. The difference is in the arguments passed to the command. To use
`kubectl delete` as an imperative command, pass the object to be deleted as
an argument. Here's an example that passes a Deployment object named nginx:
@@ -34,7 +34,7 @@ for details.
## How to update objects
{{< warning >}}
**Warning:** Updating objects with the `replace` command drops all
Updating objects with the `replace` command drops all
parts of the spec not specified in the configuration file. This
should not be used with objects whose specs are partially managed
by the cluster, such as Services of type `LoadBalancer`, where
@@ -115,7 +115,7 @@ kubectl replace -f <kind>_<name>.yaml
## Defining controller selectors and PodTemplate labels
{{< warning >}}
**Warning:** Updating selectors on controllers is strongly discouraged.
Updating selectors on controllers is strongly discouraged.
{{< /warning >}}
The recommended approach is to define a single, immutable PodTemplate label
@@ -15,7 +15,7 @@ approaches.
## Management techniques
{{< warning >}}
**Warning:** A Kubernetes object should be managed using only one technique. Mixing
A Kubernetes object should be managed using only one technique. Mixing
and matching techniques for the same object results in undefined behavior.
{{< /warning >}}
@@ -74,7 +74,7 @@ See the [API reference](/docs/reference/generated/kubernetes-api/{{< param "vers
for more details on object definitions.
{{< warning >}}
**Warning:** The imperative `replace` command replaces the existing
The imperative `replace` command replaces the existing
spec with the newly provided one, dropping all changes to the object missing from
the configuration file. This approach should not be used with resource
types whose specs are updated independently of the configuration file.
@@ -135,7 +135,7 @@ are automatically detected per-object by `kubectl`. This enables working on
directories, where different operations might be needed for different objects.
{{< note >}}
**Note:** Declarative object configuration retains changes made by other
Declarative object configuration retains changes made by other
writers, even if the changes are not merged back to the object configuration file.
This is possible by using the `patch` API operation to write only
observed differences, instead of using the `replace`
@@ -19,7 +19,7 @@ Instead, applications are informal and described with metadata. The definition o
what an application contains is loose.
{{< note >}}
**Note:** These are recommended labels. They make it easier to manage applications
These are recommended labels. They make it easier to manage applications
but aren't required for any core tooling.
{{< /note >}}
@@ -66,7 +66,7 @@ An empty label selector (that is, one with zero requirements) selects every obje
A null label selector (which is only possible for optional selector fields) selects no objects.
{{< note >}}
**Note**: the label selectors of two controllers must not overlap within a namespace, otherwise they will fight with each other.
The label selectors of two controllers must not overlap within a namespace, otherwise they will fight with each other.
{{< /note >}}
### _Equality-based_ requirement