mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-07-17 17:52:12 +00:00
Ease doing custom configuration of builtin plugins.
This commit is contained in:
@@ -20,11 +20,6 @@ type ReplicaCountTransformerPlugin struct {
|
||||
FieldSpecs []config.FieldSpec `json:"fieldSpecs,omitempty" yaml:"fieldSpecs,omitempty"`
|
||||
}
|
||||
|
||||
//noinspection GoUnusedGlobalVariable
|
||||
func NewReplicaCountTransformerPlugin() *ReplicaCountTransformerPlugin {
|
||||
return &ReplicaCountTransformerPlugin{}
|
||||
}
|
||||
|
||||
func (p *ReplicaCountTransformerPlugin) Config(
|
||||
ldr ifc.Loader, rf *resmap.Factory, c []byte) (err error) {
|
||||
|
||||
@@ -88,3 +83,7 @@ func (p *ReplicaCountTransformerPlugin) addReplicas(in interface{}) (interface{}
|
||||
}
|
||||
return p.Replica.Count, nil
|
||||
}
|
||||
|
||||
func NewReplicaCountTransformerPlugin() resmap.TransformerPlugin {
|
||||
return &ReplicaCountTransformerPlugin{}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user