v1

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 6, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

+groupName=apisix.apache.org

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

View Source
var (
	SchemeGroupVersion = schema.GroupVersion{
		Group:   _groupName,
		Version: _version,
	}
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var (
	// SchemeHTTP represents the HTTP protocol.
	SchemeHTTP = "http"
	// SchemeGRPC represents the GRPC protocol.
	SchemeGRPC = "grpc"
)

Functions

func Kind

func Kind(kind string) schema.GroupKind

func Resource

func Resource(resource string) schema.GroupResource

Types

type ApisixRoute

type ApisixRoute struct {
	metav1.TypeMeta   `json:",inline" yaml:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty"`
	Spec              *ApisixRouteSpec `json:"spec,omitempty" yaml:"spec,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object ApisixRoute is used to define the route rules and upstreams for Apache APISIX. The definition closes the Kubernetes Ingress resource.

func (*ApisixRoute) DeepCopy

func (in *ApisixRoute) DeepCopy() *ApisixRoute

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixRoute.

func (*ApisixRoute) DeepCopyInto

func (in *ApisixRoute) DeepCopyInto(out *ApisixRoute)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixRoute) DeepCopyObject

func (in *ApisixRoute) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixRouteList

type ApisixRouteList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`
	Items           []ApisixRoute `json:"items,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*ApisixRouteList) DeepCopy

func (in *ApisixRouteList) DeepCopy() *ApisixRouteList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixRouteList.

func (*ApisixRouteList) DeepCopyInto

func (in *ApisixRouteList) DeepCopyInto(out *ApisixRouteList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixRouteList) DeepCopyObject

func (in *ApisixRouteList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixRouteSpec

type ApisixRouteSpec struct {
	Rules []Rule `json:"rules,omitempty"`
}

ApisixRouteSpec is the spec definition for ApisixRouteSpec.

func (*ApisixRouteSpec) DeepCopy

func (in *ApisixRouteSpec) DeepCopy() *ApisixRouteSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixRouteSpec.

func (*ApisixRouteSpec) DeepCopyInto

func (in *ApisixRouteSpec) DeepCopyInto(out *ApisixRouteSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApisixSecret

type ApisixSecret struct {
	Name      string `json:"name,omitempty"`
	Namespace string `json:"namespace,omitempty"`
}

ApisixSecret describes the Kubernetes Secret name and namespace.

func (*ApisixSecret) DeepCopy

func (in *ApisixSecret) DeepCopy() *ApisixSecret

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixSecret.

func (*ApisixSecret) DeepCopyInto

func (in *ApisixSecret) DeepCopyInto(out *ApisixSecret)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApisixService

type ApisixService struct {
	metav1.TypeMeta   `json:",inline" yaml:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty"`
	Spec              *ApisixServiceSpec `json:"spec,omitempty" yaml:"spec,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object ApisixService is used to define the Service resource in APISIX, it's useful to use Service to put all common configurations and let Route to reference it.

func (*ApisixService) DeepCopy

func (in *ApisixService) DeepCopy() *ApisixService

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixService.

func (*ApisixService) DeepCopyInto

func (in *ApisixService) DeepCopyInto(out *ApisixService)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixService) DeepCopyObject

func (in *ApisixService) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixServiceList

type ApisixServiceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`
	Items           []ApisixService `json:"items,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*ApisixServiceList) DeepCopy

func (in *ApisixServiceList) DeepCopy() *ApisixServiceList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixServiceList.

func (*ApisixServiceList) DeepCopyInto

func (in *ApisixServiceList) DeepCopyInto(out *ApisixServiceList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixServiceList) DeepCopyObject

func (in *ApisixServiceList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixServiceSpec

type ApisixServiceSpec struct {
	Upstream string   `json:"upstream,omitempty"`
	Port     int      `json:"port,omitempty"`
	Plugins  []Plugin `json:"plugins,omitempty"`
}

ApisixServiceSpec describes the ApisixService specification.

func (*ApisixServiceSpec) DeepCopy

func (in *ApisixServiceSpec) DeepCopy() *ApisixServiceSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixServiceSpec.

func (*ApisixServiceSpec) DeepCopyInto

func (in *ApisixServiceSpec) DeepCopyInto(out *ApisixServiceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApisixTls

type ApisixTls struct {
	metav1.TypeMeta   `json:",inline" yaml:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty"`
	Spec              *ApisixTlsSpec `json:"spec,omitempty" yaml:"spec,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object ApisixTls defines SSL resource in APISIX.

func (*ApisixTls) DeepCopy

func (in *ApisixTls) DeepCopy() *ApisixTls

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixTls.

func (*ApisixTls) DeepCopyInto

func (in *ApisixTls) DeepCopyInto(out *ApisixTls)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixTls) DeepCopyObject

func (in *ApisixTls) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixTlsList

type ApisixTlsList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`
	Items           []ApisixTls `json:"items,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*ApisixTlsList) DeepCopy

func (in *ApisixTlsList) DeepCopy() *ApisixTlsList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixTlsList.

func (*ApisixTlsList) DeepCopyInto

func (in *ApisixTlsList) DeepCopyInto(out *ApisixTlsList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixTlsList) DeepCopyObject

func (in *ApisixTlsList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixTlsSpec

type ApisixTlsSpec struct {
	Hosts  []string     `json:"hosts,omitempty"`
	Secret ApisixSecret `json:"secret,omitempty"`
}

ApisixTlsSpec is the specification of ApisixSSL.

func (*ApisixTlsSpec) DeepCopy

func (in *ApisixTlsSpec) DeepCopy() *ApisixTlsSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixTlsSpec.

func (*ApisixTlsSpec) DeepCopyInto

func (in *ApisixTlsSpec) DeepCopyInto(out *ApisixTlsSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApisixUpstream

type ApisixUpstream struct {
	metav1.TypeMeta   `json:",inline" yaml:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty"`
	Spec              *ApisixUpstreamSpec `json:"spec,omitempty" yaml:"spec,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object ApisixUpstream is used to decorate Upstream in APISIX, such as load balacing type.

func (*ApisixUpstream) DeepCopy

func (in *ApisixUpstream) DeepCopy() *ApisixUpstream

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixUpstream.

func (*ApisixUpstream) DeepCopyInto

func (in *ApisixUpstream) DeepCopyInto(out *ApisixUpstream)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixUpstream) DeepCopyObject

func (in *ApisixUpstream) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixUpstreamList

type ApisixUpstreamList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`
	Items           []ApisixUpstream `json:"items,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*ApisixUpstreamList) DeepCopy

func (in *ApisixUpstreamList) DeepCopy() *ApisixUpstreamList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixUpstreamList.

func (*ApisixUpstreamList) DeepCopyInto

func (in *ApisixUpstreamList) DeepCopyInto(out *ApisixUpstreamList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApisixUpstreamList) DeepCopyObject

func (in *ApisixUpstreamList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApisixUpstreamSpec

type ApisixUpstreamSpec struct {
	Ports []Port `json:"ports,omitempty"`
}

ApisixUpstreamSpec describes the specification of Upstream in APISIX.

func (*ApisixUpstreamSpec) DeepCopy

func (in *ApisixUpstreamSpec) DeepCopy() *ApisixUpstreamSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApisixUpstreamSpec.

func (*ApisixUpstreamSpec) DeepCopyInto

func (in *ApisixUpstreamSpec) DeepCopyInto(out *ApisixUpstreamSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Backend

type Backend struct {
	ServiceName string `json:"serviceName,omitempty"`
	ServicePort int    `json:"servicePort,omitempty"`
}

Backend defines an upstream, it should be an existing Kubernetes Service. Note the Service should be in the same namespace with ApisixRoute resource, i.e. cross namespacing is not allowed.

func (*Backend) DeepCopy

func (in *Backend) DeepCopy() *Backend

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Backend.

func (*Backend) DeepCopyInto

func (in *Backend) DeepCopyInto(out *Backend)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Config

type Config map[string]interface{}

func (*Config) DeepCopy

func (p *Config) DeepCopy() *Config

func (Config) DeepCopyInto

func (p Config) DeepCopyInto(out *Config)

type ConfigSet

type ConfigSet []interface{}

func (*ConfigSet) DeepCopy

func (p *ConfigSet) DeepCopy() *ConfigSet

func (ConfigSet) DeepCopyInto

func (p ConfigSet) DeepCopyInto(out *ConfigSet)

type Http

type Http struct {
	Paths []Path `json:"paths,omitempty"`
}

Http represents all route rules in HTTP scope.

func (*Http) DeepCopy

func (in *Http) DeepCopy() *Http

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Http.

func (*Http) DeepCopyInto

func (in *Http) DeepCopyInto(out *Http)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LoadBalancer

type LoadBalancer struct {
	Type string `json:"type" yaml:"type"`
	// The HashOn and Key fields are required when Type is "chash".
	// HashOn represents the key fetching scope.
	HashOn string `json:"hashOn,omitempty" yaml:"hashOn,omitempty"`
	// Key represents the hash key.
	Key string `json:"key,omitempty" yaml:"key,omitempty"`
}

LoadBalancer describes the load balancing parameters.

func (*LoadBalancer) DeepCopy

func (in *LoadBalancer) DeepCopy() *LoadBalancer

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LoadBalancer.

func (*LoadBalancer) DeepCopyInto

func (in *LoadBalancer) DeepCopyInto(out *LoadBalancer)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Path

type Path struct {
	Path    string   `json:"path,omitempty"`
	Backend Backend  `json:"backend,omitempty"`
	Plugins []Plugin `json:"plugins,omitempty"`
}

Path defines an URI based route rule.

func (*Path) DeepCopy

func (in *Path) DeepCopy() *Path

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Path.

func (*Path) DeepCopyInto

func (in *Path) DeepCopyInto(out *Path)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Plugin

type Plugin struct {
	Name      string    `json:"name,omitempty"`
	Enable    bool      `json:"enable,omitempty"`
	Config    Config    `json:"config,omitempty"`
	ConfigSet ConfigSet `json:"config_set,omitempty"`
}

func (*Plugin) DeepCopy

func (in *Plugin) DeepCopy() *Plugin

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Plugin.

func (*Plugin) DeepCopyInto

func (in *Plugin) DeepCopyInto(out *Plugin)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Port

type Port struct {
	Port         int           `json:"port,omitempty"`
	LoadBalancer *LoadBalancer `json:"loadbalancer,omitempty"`
	// The scheme used to talk with the upstream.
	// Now value can be http, grpc.
	// +optional
	Scheme string `json:"scheme,omitempty" yaml:"scheme,omitempty"`
}

Port is the port-specific configurations.

func (*Port) DeepCopy

func (in *Port) DeepCopy() *Port

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Port.

func (*Port) DeepCopyInto

func (in *Port) DeepCopyInto(out *Port)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Rule

type Rule struct {
	Host string `json:"host,omitempty"`
	Http Http   `json:"http,omitempty"`
}

Rule represents a single route rule in ApisixRoute.

func (*Rule) DeepCopy

func (in *Rule) DeepCopy() *Rule

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Rule.

func (*Rule) DeepCopyInto

func (in *Rule) DeepCopyInto(out *Rule)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL