mirror of
https://github.com/projectcapsule/capsule.git
synced 2026-08-25 16:07:24 +00:00
feat(tenant): support gateway/class (#1463)
* feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> Co-authored-by: Oliver Bähler <oliverbaehler@hotmail.com> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> * feat(tenant): support gateway/class Signed-off-by: Hristo Hristov <me@hhristov.info> --------- Signed-off-by: Hristo Hristov <me@hhristov.info> Co-authored-by: Oliver Bähler <oliverbaehler@hotmail.com>
This commit is contained in:
co-authored by
Oliver Bähler
parent
7d0a4c58fd
commit
a60ebfac5e
@@ -0,0 +1,12 @@
|
||||
// Copyright 2020-2023 Project Capsule Authors.
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
package v1beta2
|
||||
|
||||
import (
|
||||
"github.com/projectcapsule/capsule/pkg/api"
|
||||
)
|
||||
|
||||
type GatewayOptions struct {
|
||||
AllowedClasses *api.SelectionListWithDefaultSpec `json:"allowedClasses,omitempty"`
|
||||
}
|
||||
@@ -49,6 +49,8 @@ type TenantSpec struct {
|
||||
// A default value can be specified, and all the Pod resources created will inherit the declared class.
|
||||
// Optional.
|
||||
PriorityClasses *api.DefaultAllowedListSpec `json:"priorityClasses,omitempty"`
|
||||
// Specifies options for the GatewayClass resources.
|
||||
GatewayOptions GatewayOptions `json:"gatewayOptions,omitempty"`
|
||||
// Toggling the Tenant resources cordoning, when enable resources cannot be deleted.
|
||||
//+kubebuilder:default:=false
|
||||
Cordoned bool `json:"cordoned,omitempty"`
|
||||
|
||||
@@ -154,6 +154,26 @@ func (in *CapsuleResources) DeepCopy() *CapsuleResources {
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *GatewayOptions) DeepCopyInto(out *GatewayOptions) {
|
||||
*out = *in
|
||||
if in.AllowedClasses != nil {
|
||||
in, out := &in.AllowedClasses, &out.AllowedClasses
|
||||
*out = new(api.SelectionListWithDefaultSpec)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GatewayOptions.
|
||||
func (in *GatewayOptions) DeepCopy() *GatewayOptions {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(GatewayOptions)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *GlobalTenantResource) DeepCopyInto(out *GlobalTenantResource) {
|
||||
*out = *in
|
||||
@@ -770,6 +790,7 @@ func (in *TenantSpec) DeepCopyInto(out *TenantSpec) {
|
||||
*out = new(api.DefaultAllowedListSpec)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
in.GatewayOptions.DeepCopyInto(&out.GatewayOptions)
|
||||
if in.ForceTenantPrefix != nil {
|
||||
in, out := &in.ForceTenantPrefix, &out.ForceTenantPrefix
|
||||
*out = new(bool)
|
||||
|
||||
Reference in New Issue
Block a user