mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-27 21:47:07 +00:00
Merge pull request #123417 from soltysh/kube_codegen-applyexternal
kube_codegen: expose external-applyconfigurations flag for client generation
This commit is contained in:
commit
4b3da38651
@ -451,6 +451,10 @@ function kube::codegen::gen_openapi() {
|
|||||||
# --applyconfig-name <string = "applyconfiguration">
|
# --applyconfig-name <string = "applyconfiguration">
|
||||||
# An optional override for the leaf name of the generated "applyconfiguration" directory.
|
# An optional override for the leaf name of the generated "applyconfiguration" directory.
|
||||||
#
|
#
|
||||||
|
# --applyconfig-externals <string = "">
|
||||||
|
# An optional list of comma separated external apply configurations locations
|
||||||
|
# in <type-package>.<type-name>:<applyconfiguration-package> form.
|
||||||
|
#
|
||||||
# --with-watch
|
# --with-watch
|
||||||
# Enables generation of listers and informers for APIs which support WATCH.
|
# Enables generation of listers and informers for APIs which support WATCH.
|
||||||
#
|
#
|
||||||
@ -461,7 +465,7 @@ function kube::codegen::gen_openapi() {
|
|||||||
# An optional override for the leaf name of the generated "informers" directory.
|
# An optional override for the leaf name of the generated "informers" directory.
|
||||||
#
|
#
|
||||||
# --plural-exceptions <string = "">
|
# --plural-exceptions <string = "">
|
||||||
# An optional list of comma separated plural exception definitions in Type:PluralizedType form.
|
# An optional list of comma separated plural exception definitions in Type:PluralizedType form.
|
||||||
#
|
#
|
||||||
function kube::codegen::gen_client() {
|
function kube::codegen::gen_client() {
|
||||||
local in_pkg_root=""
|
local in_pkg_root=""
|
||||||
@ -472,6 +476,7 @@ function kube::codegen::gen_client() {
|
|||||||
local clientset_versioned_name="versioned"
|
local clientset_versioned_name="versioned"
|
||||||
local applyconfig="false"
|
local applyconfig="false"
|
||||||
local applyconfig_subdir="applyconfiguration"
|
local applyconfig_subdir="applyconfiguration"
|
||||||
|
local applyconfig_external=""
|
||||||
local watchable="false"
|
local watchable="false"
|
||||||
local listers_subdir="listers"
|
local listers_subdir="listers"
|
||||||
local informers_subdir="informers"
|
local informers_subdir="informers"
|
||||||
@ -517,6 +522,10 @@ function kube::codegen::gen_client() {
|
|||||||
applyconfig_subdir="$2"
|
applyconfig_subdir="$2"
|
||||||
shift 2
|
shift 2
|
||||||
;;
|
;;
|
||||||
|
"--applyconfig-externals")
|
||||||
|
applyconfig_external="$2"
|
||||||
|
shift 2
|
||||||
|
;;
|
||||||
"--with-watch")
|
"--with-watch")
|
||||||
watchable="true"
|
watchable="true"
|
||||||
shift
|
shift
|
||||||
@ -624,6 +633,7 @@ function kube::codegen::gen_client() {
|
|||||||
--go-header-file "${boilerplate}" \
|
--go-header-file "${boilerplate}" \
|
||||||
--output-base "${out_base}" \
|
--output-base "${out_base}" \
|
||||||
--output-package "${out_pkg_root}/${applyconfig_subdir}" \
|
--output-package "${out_pkg_root}/${applyconfig_subdir}" \
|
||||||
|
--external-applyconfigurations "${applyconfig_external}" \
|
||||||
"${inputs[@]}"
|
"${inputs[@]}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user