Fixing meta
This commit is contained in:
21
crd/multus/index.rhai
Normal file
21
crd/multus/index.rhai
Normal file
@@ -0,0 +1,21 @@
|
||||
const SRC=src;
|
||||
const DEST=dest;
|
||||
const DOIT=config.apply;
|
||||
const PURGE=config.purge;
|
||||
const crdFiles=["apiextensions.k8s.io_v1_CustomResourceDefinition_network-attachment-definitions.k8s.cni.cncf.io.yaml"];
|
||||
fn pre_install() {
|
||||
if ! global::DOIT {
|
||||
return;
|
||||
}
|
||||
for file in global::crdFiles {
|
||||
shell(`kubectl replace -f ${global::SRC}/${file} || kubectl create -f ${global::SRC}/${file}`);
|
||||
}
|
||||
}
|
||||
fn post_destroy() {
|
||||
if ! global::PURGE {
|
||||
return;
|
||||
}
|
||||
for file in global::crdFiles {
|
||||
shell(`kubectl delete -f ${global::SRC}/${file}`);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user