mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-13 01:50:55 +00:00
Refactor kustomize config command structure
- Create cfg, fn, live parent commands
This commit is contained in:
committed by
Phillip Wittrock
parent
73157c7141
commit
701c217791
@@ -11,8 +11,8 @@
|
||||
|
||||
### Examples
|
||||
|
||||
kustomize config annotate my-dir/ --kv foo=bar
|
||||
kustomize cfg annotate my-dir/ --kv foo=bar
|
||||
|
||||
kustomize config annotate my-dir/ --kv foo=bar --kv a=b
|
||||
kustomize cfg annotate my-dir/ --kv foo=bar --kv a=b
|
||||
|
||||
kustomize config annotate my-dir/ --kv foo=bar --kind Deployment --name foo
|
||||
kustomize cfg annotate my-dir/ --kv foo=bar --kind Deployment --name foo
|
||||
|
||||
@@ -12,10 +12,10 @@
|
||||
### Examples
|
||||
|
||||
# print Resource config from a directory
|
||||
kustomize config cat my-dir/
|
||||
kustomize cfg cat my-dir/
|
||||
|
||||
# wrap Resource config from a directory in an ResourceList
|
||||
kustomize config cat my-dir/ --wrap-kind ResourceList --wrap-version config.kubernetes.io/v1alpha1 --function-config fn.yaml
|
||||
kustomize cfg cat my-dir/ --wrap-kind ResourceList --wrap-version config.kubernetes.io/v1alpha1 --function-config fn.yaml
|
||||
|
||||
# unwrap Resource config from a directory in an ResourceList
|
||||
... | kustomize config cat
|
||||
... | kustomize cfg cat
|
||||
|
||||
@@ -12,4 +12,4 @@
|
||||
### Examples
|
||||
|
||||
# print Resource counts from a directory
|
||||
kustomize config count my-dir/
|
||||
kustomize cfg count my-dir/
|
||||
@@ -38,7 +38,7 @@ Create a custom setter for a Resource field by inlining OpenAPI as comments.
|
||||
**Create a new setter:**
|
||||
|
||||
# create a setter for ports
|
||||
$ kustomize config set create DIR/ http-port 8080 --type "integer" --field "port"
|
||||
$ kustomize cfg set create DIR/ http-port 8080 --type "integer" --field "port"
|
||||
|
||||
Resources fields with a field name matching `--field` and field value matching `VALUE` will
|
||||
have a line comment added marking this field as settable.
|
||||
@@ -63,7 +63,7 @@ Create a custom setter for a Resource field by inlining OpenAPI as comments.
|
||||
Users may not set the field value using the `set` command:
|
||||
|
||||
# change the http-port value to 8081
|
||||
$ kustomize config set DIR/ http-port 8081
|
||||
$ kustomize cfg set DIR/ http-port 8081
|
||||
|
||||
### Using default values
|
||||
|
||||
@@ -75,7 +75,7 @@ The default values for a setter may be:
|
||||
|
||||
A setter may be for a substring of a full field:
|
||||
|
||||
$ kustomize config set create DIR/ image-tag v1.0.01 --type "string" --field "image"
|
||||
$ kustomize cfg set create DIR/ image-tag v1.0.01 --type "string" --field "image"
|
||||
|
||||
image: gcr.io/example/app:v1.0.1 # # {"type":"string","x-kustomize":{"partialFieldSetters":[{"name":"image-tag","value":"v1.0.1"}]}}
|
||||
|
||||
@@ -84,10 +84,10 @@ A single field value may have multiple setters applied to it for different parts
|
||||
### Examples
|
||||
|
||||
# create a setter for port fields matching "8080"
|
||||
kustomize config create-setter DIR/ port 8080 --type "integer" --field port \
|
||||
kustomize cfg create-setter DIR/ port 8080 --type "integer" --field port \
|
||||
--description "default port used by the app"
|
||||
|
||||
# create a setter for a substring of a field rather than the full field -- e.g. only the
|
||||
# image tag, not the full image
|
||||
kustomize config create-setter DIR/ image-tag v1.0.1 --type "string" \
|
||||
kustomize cfg create-setter DIR/ image-tag v1.0.1 --type "string" \
|
||||
--field image --description "current stable release"
|
||||
@@ -32,13 +32,13 @@ field paths.
|
||||
### Examples
|
||||
|
||||
# format file1.yaml and file2.yml
|
||||
kustomize config fmt file1.yaml file2.yml
|
||||
kustomize cfg fmt file1.yaml file2.yml
|
||||
|
||||
# format all *.yaml and *.yml recursively traversing directories
|
||||
kustomize config fmt my-dir/
|
||||
kustomize cfg fmt my-dir/
|
||||
|
||||
# format kubectl output
|
||||
kubectl get -o yaml deployments | kustomize config fmt
|
||||
kubectl get -o yaml deployments | kustomize cfg fmt
|
||||
|
||||
# format kustomize output
|
||||
kustomize build | kustomize config fmt
|
||||
kustomize build | kustomize cfg fmt
|
||||
@@ -19,13 +19,13 @@
|
||||
### Examples
|
||||
|
||||
# find Deployment Resources
|
||||
kustomize config grep "kind=Deployment" my-dir/
|
||||
kustomize cfg grep "kind=Deployment" my-dir/
|
||||
|
||||
# find Resources named nginx
|
||||
kustomize config grep "metadata.name=nginx" my-dir/
|
||||
kustomize cfg grep "metadata.name=nginx" my-dir/
|
||||
|
||||
# use tree to display matching Resources
|
||||
kustomize config grep "metadata.name=nginx" my-dir/ | kustomize config tree
|
||||
kustomize cfg grep "metadata.name=nginx" my-dir/ | kustomize cfg tree
|
||||
|
||||
# look for Resources matching a specific container image
|
||||
kustomize config grep "spec.template.spec.containers[name=nginx].image=nginx:1\.7\.9" my-dir/ | kustomize config tree
|
||||
kustomize cfg grep "spec.template.spec.containers[name=nginx].image=nginx:1\.7\.9" my-dir/ | kustomize cfg tree
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
### Examples
|
||||
|
||||
# create a Krmfile in the local directory
|
||||
kustomize config init
|
||||
kustomize cfg init
|
||||
|
||||
# create a Krmfile in my-dir/
|
||||
kustomize config init my-dir/
|
||||
kustomize cfg init my-dir/
|
||||
|
||||
@@ -18,6 +18,6 @@ List setters for Resources.
|
||||
|
||||
Show setters:
|
||||
|
||||
$ config list-setters DIR/
|
||||
$ kustomize cfg list-setters DIR/
|
||||
NAME DESCRIPTION VALUE TYPE COUNT SETBY
|
||||
name-prefix '' PREFIX string 2
|
||||
|
||||
@@ -17,8 +17,8 @@ earlier are lower-precedence (the destination).
|
||||
|
||||
For information on merge rules, run:
|
||||
|
||||
kustomize config docs merge
|
||||
kustomize cfg docs merge
|
||||
|
||||
### Examples
|
||||
|
||||
cat resources_and_patches.yaml | kustomize config merge > merged_resources.yaml
|
||||
cat resources_and_patches.yaml | kustomize cfg merge > merged_resources.yaml
|
||||
@@ -16,8 +16,8 @@ to the Resource in the DEST_DIR.
|
||||
|
||||
For information on merge rules, run:
|
||||
|
||||
kustomize config docs-merge3
|
||||
kustomize cfg docs-merge3
|
||||
|
||||
### Examples
|
||||
|
||||
kustomize config merge3 --ancestor a/ --from b/ --to c/
|
||||
kustomize cfg merge3 --ancestor a/ --from b/ --to c/
|
||||
@@ -40,14 +40,14 @@ order they appear in the file).
|
||||
spec:
|
||||
configField: configValue
|
||||
|
||||
In the preceding example, 'kustomize config run example/' would identify the function by
|
||||
In the preceding example, 'kustomize fn run example/' would identify the function by
|
||||
the metadata.annotations.[config.kubernetes.io/function] field. It would then write all Resources in the directory to
|
||||
a container stdin (running the gcr.io/example/examplefunction:v1.0.1 image). It
|
||||
would then write the container stdout back to example/, replacing the directory
|
||||
file contents.
|
||||
|
||||
See `kustomize help config docs-fn` for more details on writing functions.
|
||||
See `kustomize help cfg docs-fn` for more details on writing functions.
|
||||
|
||||
### Examples
|
||||
|
||||
kustomize config run example/
|
||||
kustomize fn run example/
|
||||
|
||||
@@ -29,7 +29,7 @@ the configuration as comments.
|
||||
|
||||
|
||||
To print the possible setters for the Resources in a directory, run
|
||||
`list-setters` on a directory -- e.g. `kustomize config list-setters DIR/`.
|
||||
`list-setters` on a directory -- e.g. `kustomize cfg list-setters DIR/`.
|
||||
|
||||
#### Tips
|
||||
|
||||
@@ -39,7 +39,7 @@ To print the possible setters for the Resources in a directory, run
|
||||
|
||||
The description and setBy fields are left unmodified unless specified with flags.
|
||||
|
||||
To create a custom setter for a field see: `kustomize help config create-setter`
|
||||
To create a custom setter for a field see: `kustomize help cfg create-setter`
|
||||
|
||||
### Examples
|
||||
|
||||
@@ -64,7 +64,7 @@ To create a custom setter for a field see: `kustomize help config create-setter`
|
||||
|
||||
Perform set: set a new value, owner and description
|
||||
|
||||
$ kustomize config set DIR/ name-prefix "test" --description "test environment" --set-by "dev"
|
||||
$ kustomize cfg set DIR/ name-prefix "test" --description "test environment" --set-by "dev"
|
||||
set 2 values
|
||||
|
||||
List setters: Show the new values
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
[Alpha] Implement a Sink by writing input to a local directory.
|
||||
|
||||
kustomize config sink [DIR]
|
||||
kustomize fn sink [DIR]
|
||||
|
||||
DIR:
|
||||
Path to local directory. If unspecified, sink will write to stdout as if it were a single file.
|
||||
@@ -15,4 +15,4 @@
|
||||
|
||||
### Examples
|
||||
|
||||
kustomize config source DIR/ | your-function | kustomize config sink DIR/
|
||||
kustomize fn source DIR/ | your-function | kustomize fn sink DIR/
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
[Alpha] Implement a Source by reading a local directory.
|
||||
|
||||
kustomize config source DIR...
|
||||
kustomize fn source DIR...
|
||||
|
||||
DIR:
|
||||
One or more paths to local directories. Contents from directories will be concatenated.
|
||||
@@ -17,6 +17,6 @@
|
||||
### Examples
|
||||
|
||||
# emity configuration directory as input source to a function
|
||||
kustomize config source DIR/
|
||||
kustomize fn source DIR/
|
||||
|
||||
kustomize config source DIR/ | your-function | kustomize config sink DIR/
|
||||
kustomize fn source DIR/ | your-function | kustomize fn sink DIR/
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
[Alpha] Display Resource structure from a directory or stdin.
|
||||
|
||||
kustomize config tree may be used to print Resources in a directory or cluster, preserving structure
|
||||
kustomize cfg tree may be used to print Resources in a directory or cluster, preserving structure
|
||||
|
||||
Args:
|
||||
|
||||
@@ -15,38 +15,38 @@ Args:
|
||||
|
||||
Resource fields may be printed as part of the Resources by specifying the fields as flags.
|
||||
|
||||
kustomize config tree has build-in support for printing common fields, such as replicas, container images,
|
||||
kustomize cfg tree has build-in support for printing common fields, such as replicas, container images,
|
||||
container names, etc.
|
||||
|
||||
kustomize config tree supports printing arbitrary fields using the '--field' flag.
|
||||
kustomize cfg tree supports printing arbitrary fields using the '--field' flag.
|
||||
|
||||
By default, kustomize config tree uses Resource graph structure if any relationships between resources (ownerReferences)
|
||||
By default, kustomize cfg tree uses Resource graph structure if any relationships between resources (ownerReferences)
|
||||
are detected, as is typically the case when printing from a cluster. Otherwise, directory graph structure is used. The
|
||||
graph structure can also be selected explicitly using the '--graph-structure' flag.
|
||||
|
||||
### Examples
|
||||
|
||||
# print Resources using directory structure
|
||||
kustomize config tree my-dir/
|
||||
kustomize cfg tree my-dir/
|
||||
|
||||
# print replicas, container name, and container image and fields for Resources
|
||||
kustomize config tree my-dir --replicas --image --name
|
||||
kustomize cfg tree my-dir --replicas --image --name
|
||||
|
||||
# print all common Resource fields
|
||||
kustomize config tree my-dir/ --all
|
||||
kustomize cfg tree my-dir/ --all
|
||||
|
||||
# print the "foo"" annotation
|
||||
kustomize config tree my-dir/ --field "metadata.annotations.foo"
|
||||
kustomize cfg tree my-dir/ --field "metadata.annotations.foo"
|
||||
|
||||
# print the "foo"" annotation
|
||||
kubectl get all -o yaml | kustomize config tree \
|
||||
kubectl get all -o yaml | kustomize cfg tree \
|
||||
--field="status.conditions[type=Completed].status"
|
||||
|
||||
# print live Resources from a cluster using owners for graph structure
|
||||
kubectl get all -o yaml | kustomize config tree --replicas --name --image
|
||||
kubectl get all -o yaml | kustomize cfg tree --replicas --name --image
|
||||
|
||||
# print live Resources with status condition fields
|
||||
kubectl get all -o yaml | kustomize config tree \
|
||||
kubectl get all -o yaml | kustomize cfg tree \
|
||||
--name --image --replicas \
|
||||
--field="status.conditions[type=Completed].status" \
|
||||
--field="status.conditions[type=Complete].status" \
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
### Synopsis
|
||||
|
||||
`kustomize config` provides tools for working with local configuration directories.
|
||||
`kustomize cfg` provides tools for working with local configuration directories.
|
||||
|
||||
First fetch a bundle of configuration to your local file system from the
|
||||
Kubernetes examples repository.
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
`tree` can be used to summarize the collection of Resources in a directory:
|
||||
|
||||
$ kustomize config tree mysql-wordpress-pd/
|
||||
$ kustomize cfg tree mysql-wordpress-pd/
|
||||
mysql-wordpress-pd
|
||||
├── [gce-volumes.yaml] v1.PersistentVolume wordpress-pv-1
|
||||
├── [gce-volumes.yaml] v1.PersistentVolume wordpress-pv-2
|
||||
@@ -31,7 +31,7 @@
|
||||
supported fields, and may also print arbitrary values using the `--field` flag to specify a field
|
||||
path.
|
||||
|
||||
$ kustomize config tree mysql-wordpress-pd/ --name --image --replicas --ports
|
||||
$ kustomize cfg tree mysql-wordpress-pd/ --name --image --replicas --ports
|
||||
mysql-wordpress-pd
|
||||
├── [gce-volumes.yaml] PersistentVolume wordpress-pv-1
|
||||
├── [gce-volumes.yaml] PersistentVolume wordpress-pv-2
|
||||
@@ -60,7 +60,7 @@
|
||||
to build the tree structure.
|
||||
|
||||
kubectl apply -R -f cockroachdb/
|
||||
kubectl get all -o yaml | kustomize config tree --graph-structure owners --name --image --replicas
|
||||
kubectl get all -o yaml | kustomize cfg tree --graph-structure owners --name --image --replicas
|
||||
.
|
||||
├── [Resource] Deployment wp/wordpress
|
||||
│ ├── spec.replicas: 1
|
||||
@@ -84,7 +84,7 @@
|
||||
|
||||
### `cat` -- view the full collection of Resources
|
||||
|
||||
$ kustomize config cat mysql-wordpress-pd/
|
||||
$ kustomize cfg cat mysql-wordpress-pd/
|
||||
apiVersion: v1
|
||||
kind: PersistentVolume
|
||||
metadata:
|
||||
@@ -111,7 +111,7 @@
|
||||
`fmt` formats the Resource Configuration by applying a consistent style, including
|
||||
ordering of fields and indentation.
|
||||
|
||||
$ kustomize config fmt mysql-wordpress-pd/
|
||||
$ kustomize cfg fmt mysql-wordpress-pd/
|
||||
|
||||
Run `git diff` and see the changes that have been applied.
|
||||
|
||||
@@ -120,7 +120,7 @@
|
||||
`grep` prints Resources matching some field value. The Resources are annotated with their
|
||||
file source so they can be piped to other commands without losing this information.
|
||||
|
||||
$ kustomize config grep "metadata.name=wordpress" wordpress/
|
||||
$ kustomize cfg grep "metadata.name=wordpress" wordpress/
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
@@ -142,7 +142,7 @@
|
||||
- list elements may be indexed by a field value using list[field=value]
|
||||
- '.' as part of a key or value may be escaped as '\.'
|
||||
|
||||
$ kustomize config grep "spec.status.spec.containers[name=nginx].image=mysql:5\.6" wordpress/
|
||||
$ kustomize cfg grep "spec.status.spec.containers[name=nginx].image=mysql:5\.6" wordpress/
|
||||
apiVersion: apps/v1 # for k8s versions before 1.9.0 use apps/v1beta2 and before 1.8.0 use extensions/v1beta1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
@@ -163,7 +163,7 @@
|
||||
|
||||
`grep` may be used with kubectl to search for Resources in a cluster matching a value.
|
||||
|
||||
kubectl get all -o yaml | kustomize config grep "spec.replicas>0" | kustomize config tree --replicas
|
||||
kubectl get all -o yaml | kustomize cfg grep "spec.replicas>0" | kustomize cfg tree --replicas
|
||||
.
|
||||
└──
|
||||
├── [.] Deployment wp/wordpress
|
||||
@@ -179,7 +179,7 @@
|
||||
|
||||
If there is an error parsing the Resource configuration, kustomize will print an error with the file.
|
||||
|
||||
$ kustomize config grep "spec.template.spec.containers[name=\.*].resources.limits.cpu>1.0" ./staging/ | kustomize config tree --name --resources
|
||||
$ kustomize cfg grep "spec.template.spec.containers[name=\.*].resources.limits.cpu>1.0" ./staging/ | kustomize cfg tree --name --resources
|
||||
Error: staging/persistent-volume-provisioning/quobyte/quobyte-admin-secret.yaml: [0]: yaml: unmarshal errors:
|
||||
line 13: mapping key "type" already defined at line 9
|
||||
|
||||
@@ -192,7 +192,7 @@
|
||||
When developing -- to get a stack trace for where an error was encountered,
|
||||
use the `--stack-trace` flag:
|
||||
|
||||
$ kustomize config grep "spec.template.spec.containers[name=\.*].resources.limits.cpu>1.0" ./staging/ --stack-trace
|
||||
$ kustomize cfg grep "spec.template.spec.containers[name=\.*].resources.limits.cpu>1.0" ./staging/ --stack-trace
|
||||
go/src/sigs.k8s.io/kustomize/kyaml/yaml/types.go:260 (0x4d35c86)
|
||||
(*RNode).GetMeta: return m, errors.Wrap(err)
|
||||
go/src/sigs.k8s.io/kustomize/kyaml/kio/byteio_reader.go:130 (0x4d3e099)
|
||||
@@ -206,7 +206,7 @@
|
||||
|
||||
Query for `replicas`:
|
||||
|
||||
$ kustomize config grep "spec.replicas>5" ./ | kustomize config tree --replicas
|
||||
$ kustomize cfg grep "spec.replicas>5" ./ | kustomize cfg tree --replicas
|
||||
.
|
||||
├── staging/sysdig-cloud
|
||||
│ └── [sysdig-rc.yaml] ReplicationController sysdig-agent
|
||||
@@ -217,7 +217,7 @@
|
||||
|
||||
Query for `resource.limits`
|
||||
|
||||
$ kustomize config grep "spec.template.spec.containers[name=\.*].resources.limits.memory>0" ./ | kustomize config tree --resources
|
||||
$ kustomize cfg grep "spec.template.spec.containers[name=\.*].resources.limits.memory>0" ./ | kustomize cfg tree --resources
|
||||
.
|
||||
├── cassandra
|
||||
│ └── [cassandra-statefulset.yaml] StatefulSet cassandra
|
||||
@@ -246,7 +246,7 @@
|
||||
|
||||
Find Resources that have an image specified, but the image doesn't have a tag:
|
||||
|
||||
$ kustomize config grep "spec.template.spec.containers[name=\.*].name=\.*" ./ | kustomize config grep "spec.template.spec.containers[name=\.*].image=\.*:\.*" -v | kustomize config tree --image --name
|
||||
$ kustomize cfg grep "spec.template.spec.containers[name=\.*].name=\.*" ./ | kustomize cfg grep "spec.template.spec.containers[name=\.*].image=\.*:\.*" -v | kustomize cfg tree --image --name
|
||||
.
|
||||
├── staging/newrelic
|
||||
│ ├── [newrelic-daemonset.yaml] DaemonSet newrelic-agent
|
||||
|
||||
@@ -25,13 +25,13 @@
|
||||
cd template-heredoc-cockroachdb/
|
||||
|
||||
# view the Resources
|
||||
kustomize config tree local-resource/ --name --image --replicas
|
||||
kustomize cfg tree local-resource/ --name --image --replicas
|
||||
|
||||
# run the function
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
|
||||
# view the generated Resources
|
||||
kustomize config tree local-resource/ --name --image --replicas
|
||||
kustomize cfg tree local-resource/ --name --image --replicas
|
||||
|
||||
`run` generated the directory ` local-resource/config` containing the generated
|
||||
Resources.
|
||||
@@ -45,7 +45,7 @@
|
||||
but keep the fields that you manually added to the generated Resource configuration.
|
||||
|
||||
# run the function
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
|
||||
`run` facilitates a non-destructive *smart templating* approach that allows templating
|
||||
to be composed with manual modifications directly to the template output, as well as
|
||||
@@ -70,13 +70,13 @@
|
||||
cd template-go-nginx/
|
||||
|
||||
# view the Resources
|
||||
kustomize config tree local-resource/ --name --image --replicas
|
||||
kustomize cfg tree local-resource/ --name --image --replicas
|
||||
|
||||
# run the function
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
|
||||
# view the generated Resources
|
||||
kustomize config tree local-resource/ --name --image --replicas
|
||||
kustomize cfg tree local-resource/ --name --image --replicas
|
||||
|
||||
`run` generated the directory ` local-resource/config` containing the generated
|
||||
Resources. this time it put the configuration in a single file rather than multiple
|
||||
@@ -92,7 +92,7 @@
|
||||
but keep the fields that you manually added to the generated Resource configuration.
|
||||
|
||||
# run the function
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
|
||||
Just like in the preceding section, the function is implemented using a non-destructive
|
||||
approach which merges the generated Resources into previously generated instances.
|
||||
@@ -112,7 +112,7 @@
|
||||
directory, and invoke `run` on the `local-resource/` directory.
|
||||
|
||||
# run the function
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
cpu-requests missing for a container in Deployment nginx (example-use.yaml [1])
|
||||
Error: exit status 1
|
||||
Usage:
|
||||
@@ -124,7 +124,7 @@
|
||||
and print the name of the file + Resource index. Edit the file and uncomment the resources,
|
||||
then re-run the functions.
|
||||
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
|
||||
The validation now passes.
|
||||
|
||||
@@ -139,7 +139,7 @@
|
||||
directory, and invoke `run` on the `local-resource/` directory.
|
||||
|
||||
# print the resources
|
||||
kustomize config tree local-resource --resources --name
|
||||
kustomize cfg tree local-resource --resources --name
|
||||
local-resource
|
||||
├── [example-use.yaml] Validator
|
||||
└── [example-use.yaml] Deployment nginx
|
||||
@@ -148,10 +148,10 @@
|
||||
└── name: nginx
|
||||
|
||||
# run the functions
|
||||
kustomize config run local-resource/
|
||||
kustomize fn run local-resource/
|
||||
|
||||
# print the new resources
|
||||
kustomize config tree local-resource --resources --name
|
||||
kustomize cfg tree local-resource --resources --name
|
||||
├── [example-use.yaml] Validator
|
||||
└── [example-use.yaml] Deployment nginx
|
||||
└── spec.template.spec.containers
|
||||
@@ -163,8 +163,8 @@
|
||||
|
||||
Change the `tshirt-size` annotation from `medium` to `small` and re-run the functions.
|
||||
|
||||
kustomize config run local-resource/
|
||||
kustomize config tree local-resource/
|
||||
kustomize fn run local-resource/
|
||||
kustomize cfg tree local-resource/
|
||||
local-resource
|
||||
├── [example-use.yaml] Validator
|
||||
└── [example-use.yaml] Deployment nginx
|
||||
|
||||
Reference in New Issue
Block a user