You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/en/docs/reference/kubectl/conventions.md
-37Lines changed: 0 additions & 37 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -28,46 +28,9 @@ For `kubectl run` to satisfy infrastructure as code:
28
28
29
29
* Tag the image with a version-specific tag and don't move that tag to a new version. For example, use `:v1234`, `v1.2.3`, `r03062016-1-4`, rather than `:latest` (For more information, see [Best Practices for Configuration](/docs/concepts/configuration/overview/#container-images)).
30
30
* Capture the parameters in a checked-in script, or at least use `--record` to annotate the created objects with the command line for an image that is lightly parameterized.
31
-
* Pin to a specific [generator](#generators) version, such as `kubectl run --generator=run-pod/v1`.
32
31
* Check in the script for an image that is heavily parameterized.
33
32
* Switch to configuration files checked into source control for features that are needed, but not expressible via `kubectl run` flags.
34
33
35
-
#### Generators
36
-
37
-
You can create the following resources using `kubectl run` with the `--generator` flag:
38
-
39
-
{{< table caption="Resources you can create using kubectl run" >}}
| ReplicationController _(deprecated)_| v1 |`kubectl run --generator=run/v1`|
44
-
| Deployment _(deprecated)_| extensions/v1beta1 |`kubectl run --generator=deployment/v1beta1`|
45
-
| Deployment _(deprecated)_| apps/v1beta1 |`kubectl run --generator=deployment/apps.v1beta1`|
46
-
| Job _(deprecated)_| batch/v1 |`kubectl run --generator=job/v1`|
47
-
| CronJob _(deprecated)_| batch/v2alpha1 |`kubectl run --generator=cronjob/v2alpha1`|
48
-
| CronJob _(deprecated)_| batch/v1beta1 |`kubectl run --generator=cronjob/v1beta1`|
49
-
{{< /table >}}
50
-
51
-
{{< note >}}
52
-
Generators other than `run-pod/v1` are deprecated.
53
-
{{< /note >}}
54
-
55
-
If you explicitly set `--generator`, kubectl uses the generator you specified. If you invoke `kubectl run` and don't specify a generator, kubectl automatically selects which generator to use based on the other flags you set. The following table lists flags and the generators that are activated if you didn't specify one yourself:
56
-
57
-
{{< table caption="kubectl run flags and the resource they imply" >}}
0 commit comments