|
9 | 9 | // Examples: https://github.com/cruise-automation/isopod, https://qri.io/docs/starlark/starlib, |
10 | 10 | // https://github.com/stripe/skycfg, https://github.com/k14s/ytt |
11 | 11 | // |
12 | | -// The resources are provided to the starlark program through the global variable "resourceList". |
13 | | -// "resourceList" is a dictionary containing an "items" field with a list of resources. |
14 | | -// The starlark modified "resourceList" is the Filter output. |
| 12 | +// The resources are provided to the starlark program through ctx.resource_list. |
| 13 | +// ctx.resource_list is a dictionary containing an "items" field with a list of resources. |
| 14 | +// The starlark-modified ctx.resource_list is the Filter output. |
15 | 15 | // |
16 | | -// After being run through the starlark program, the filter will copy the comments from the input |
17 | | -// resources to restore them -- due to them being dropped as a result of serializing the resources |
18 | | -// as starlark values. |
19 | | -// |
20 | | -// "resourceList" may also contain a "functionConfig" entry to configure the starlark script itself. |
21 | | -// Changes made by the starlark program to the "functionConfig" will be reflected in the |
| 16 | +// ctx.resource_list may also contain a "functionConfig" entry to configure the starlark script |
| 17 | +// itself. Changes made by the starlark program to the "functionConfig" will be reflected in the |
22 | 18 | // Filter.FunctionConfig value. |
23 | 19 | // |
24 | 20 | // The Filter will also format the output so that output has the preferred field ordering |
25 | 21 | // rather than an alphabetical field ordering. |
26 | 22 | // |
27 | | -// The resourceList variable adheres to the kustomize function spec as specified by: |
| 23 | +// The ctx.resource_list value adheres to the kustomize function spec as specified by: |
28 | 24 | // https://github.com/kubernetes-sigs/kustomize/blob/master/cmd/config/docs/api-conventions/functions-spec.md |
29 | 25 | // |
30 | | -// All items in the resourceList are resources represented as starlark dictionaries/ |
31 | | -// The items in the resourceList respect the io spec specified by: |
| 26 | +// All items in ctx.resource_list are resources represented as starlark dictionaries/ |
| 27 | +// The items in ctx.resource_list respect the io spec specified by: |
32 | 28 | // https://github.com/kubernetes-sigs/kustomize/blob/master/cmd/config/docs/api-conventions/config-io.md |
33 | 29 | // |
34 | 30 | // The starlark language spec can be found here: |
|
0 commit comments