Revert "update to use containerd seccomp package"

This reverts commit 4f8e065faf055d3f0463a92622297ca3afac07f4.
This commit is contained in:
Jess Frazelle 2018-03-22 09:15:36 -04:00
parent 09243b740c
commit 60f032f6f5
8199 changed files with 1598219 additions and 30742 deletions

View file

@ -0,0 +1,5 @@
// +k8s:deepcopy-gen=package,register
// +groupName=compose.docker.com
// Package compose is the internal version of the API.
package compose

View file

@ -0,0 +1,43 @@
package compose
import (
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
)
// GroupName is the group name used to register these objects
const GroupName = "compose.docker.com"
// SchemeGroupVersion is group version used to register these objects
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal}
// Kind takes an unqualified kind and returns back a Group qualified GroupKind
func Kind(kind string) schema.GroupKind {
return SchemeGroupVersion.WithKind(kind).GroupKind()
}
// Resource takes an unqualified resource and returns back a Group qualified GroupResource
func Resource(resource string) schema.GroupResource {
return SchemeGroupVersion.WithResource(resource).GroupResource()
}
var (
// SchemeBuilder collects functions that add things to a scheme. It's to allow
// code to compile without explicitly referencing generated types. You should
// declare one in each package that will have generated deep copy or conversion
// functions.
SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
// AddToScheme applies all the stored functions to the scheme. A non-nil error
// indicates that one function failed and the attempt was abandoned.
AddToScheme = SchemeBuilder.AddToScheme
)
// adds the list of known types to api.Scheme.
func addKnownTypes(scheme *runtime.Scheme) error {
scheme.AddKnownTypes(SchemeGroupVersion,
&Stack{},
&StackList{},
)
return nil
}

View file

@ -0,0 +1,117 @@
package compose
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)
// ImpersonationConfig holds information use to impersonate calls from the compose controller
type ImpersonationConfig struct {
// UserName is the username to impersonate on each request.
UserName string
// Groups are the groups to impersonate on each request.
Groups []string
// Extra is a free-form field which can be used to link some authentication information
// to authorization information. This field allows you to impersonate it.
Extra map[string][]string
}
// Stack defines a stack object to be register in the kubernetes API
// +genclient=true
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
type Stack struct {
metav1.TypeMeta
metav1.ObjectMeta
Spec StackSpec
Status StackStatus
}
// StackStatus defines the observed state of Stack
type StackStatus struct {
Phase StackPhase
Message string
}
// StackSpec defines the desired state of Stack
type StackSpec struct {
ComposeFile string
Owner ImpersonationConfig
}
// StackPhase defines the status phase in which the stack is.
type StackPhase string
// These are valid conditions of a stack.
const (
// Available means the stack is available.
StackAvailable StackPhase = "Available"
// Progressing means the deployment is progressing.
StackProgressing StackPhase = "Progressing"
// StackFailure is added in a stack when one of its members fails to be created
// or deleted.
StackFailure StackPhase = "Failure"
)
// StackList defines a list of stacks
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
type StackList struct {
metav1.TypeMeta
metav1.ListMeta
Items []Stack
}
// Owner defines the owner of a stack. It is used to impersonate the controller calls
// to kubernetes api.
type Owner struct {
metav1.TypeMeta
metav1.ObjectMeta
Owner ImpersonationConfig
}
// OwnerList defines a list of owner.
type OwnerList struct {
metav1.TypeMeta
metav1.ListMeta
Items []Owner
}
// FIXME(vdemeester) are those necessary ??
// NewStatus is newStatus
func (Stack) NewStatus() interface{} {
return StackStatus{}
}
// GetStatus returns the status
func (pc *Stack) GetStatus() interface{} {
return pc.Status
}
// SetStatus sets the status
func (pc *Stack) SetStatus(s interface{}) {
pc.Status = s.(StackStatus)
}
// GetSpec returns the spec
func (pc *Stack) GetSpec() interface{} {
return pc.Spec
}
// SetSpec sets the spec
func (pc *Stack) SetSpec(s interface{}) {
pc.Spec = s.(StackSpec)
}
// GetObjectMeta returns the ObjectMeta
func (pc *Stack) GetObjectMeta() *metav1.ObjectMeta {
return &pc.ObjectMeta
}
// SetGeneration sets the Generation
func (pc *Stack) SetGeneration(generation int64) {
pc.ObjectMeta.Generation = generation
}
// GetGeneration returns the Generation
func (pc Stack) GetGeneration() int64 {
return pc.ObjectMeta.Generation
}

View file

@ -0,0 +1,11 @@
// Package v1beta1 holds the v1beta1 versions of our stack structures.
// API versions allow the api contract for a resource to be changed while keeping
// backward compatibility by support multiple concurrent versions
// of the same resource
//
// +k8s:openapi-gen=true
// +k8s:deepcopy-gen=package,register
// +k8s:conversion-gen=github.com/docker/cli/kubernetes/compose
// +k8s:defaulter-gen=TypeMeta
// +groupName=compose.docker.com
package v1beta1 // import "github.com/docker/cli/kubernetes/compose/v1beta1"

View file

@ -0,0 +1,25 @@
package v1beta1
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/docker/cli/kubernetes/compose"
)
// Owner defines the owner of a stack. It is used to impersonate the controller calls
// to kubernetes api.
// +genclient=true
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// +subresource-request
type Owner struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Owner compose.ImpersonationConfig `json:"owner,omitempty"`
}
// OwnerList defines a list of owner.
type OwnerList struct {
metav1.TypeMeta
metav1.ListMeta
Items []Owner
}

View file

@ -0,0 +1,47 @@
package v1beta1
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
)
// GroupName is the group name used to register these objects
const GroupName = "compose.docker.com"
// SchemeGroupVersion is group version used to register these objects
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"}
var (
// SchemeBuilder collects functions that add things to a scheme. It's to allow
// code to compile without explicitly referencing generated types. You should
// declare one in each package that will have generated deep copy or conversion
// functions.
SchemeBuilder runtime.SchemeBuilder
localSchemeBuilder = &SchemeBuilder
// AddToScheme applies all the stored functions to the scheme. A non-nil error
// indicates that one function failed and the attempt was abandoned.
AddToScheme = localSchemeBuilder.AddToScheme
)
func init() {
localSchemeBuilder.Register(addKnownTypes)
}
// Adds the list of known types to api.Scheme.
func addKnownTypes(scheme *runtime.Scheme) error {
scheme.AddKnownTypes(SchemeGroupVersion,
&Stack{},
&StackList{},
&Owner{},
&OwnerList{},
)
metav1.AddToGroupVersion(scheme, SchemeGroupVersion)
return nil
}
// Resource takes an unqualified resource and returns a Group qualified GroupResource
func Resource(resource string) schema.GroupResource {
return SchemeGroupVersion.WithResource(resource).GroupResource()
}

View file

@ -0,0 +1,68 @@
package v1beta1
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
)
// StackList defines a list of stacks
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
type StackList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
Items []Stack `json:"items" protobuf:"bytes,2,rep,name=items"`
}
// +genclient=true
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// Stack defines a stack object to be register in the kubernetes API
// +k8s:openapi-gen=true
// +resource:path=stacks,strategy=StackStrategy
// +subresource:request=Owner,path=owner,rest=OwnerStackREST
type Stack struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec StackSpec `json:"spec,omitempty"`
Status StackStatus `json:"status,omitempty"`
}
// StackSpec defines the desired state of Stack
type StackSpec struct {
ComposeFile string `json:"composeFile,omitempty"`
}
// StackPhase defines the status phase in which the stack is.
type StackPhase string
// These are valid conditions of a stack.
const (
// Available means the stack is available.
StackAvailable StackPhase = "Available"
// Progressing means the deployment is progressing.
StackProgressing StackPhase = "Progressing"
// StackFailure is added in a stack when one of its members fails to be created
// or deleted.
StackFailure StackPhase = "Failure"
)
// StackStatus defines the observed state of Stack
type StackStatus struct {
// Current condition of the stack.
// +optional
Phase StackPhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=StackPhase"`
// A human readable message indicating details about the stack.
// +optional
Message string `json:"message,omitempty" protobuf:"bytes,5,opt,name=message"`
}
// Clone implements the Cloner interface for kubernetes
func (s *Stack) Clone() (*Stack, error) {
scheme := runtime.NewScheme()
if err := AddToScheme(scheme); err != nil {
return nil, err
}
return s.DeepCopy(), nil
}

View file

@ -0,0 +1,9 @@
version: "3.2"
services:
nginx:
image: nginx
deploy:
replicas: 2
redis:
image: redis:alpine

View file

@ -0,0 +1,10 @@
version: "3.2"
services:
nginx:
image: nginx
deploy:
replicas: 2
redis:
image: redis:alpine
deploy:
replicas: 5

View file

@ -0,0 +1,10 @@
version: "3.2"
services:
redis:
image: redis:alpine
deploy:
resources:
limits:
memory: 64M
reservations:
memory: 64M

View file

@ -0,0 +1,11 @@
version: "3.2"
services:
redis:
image: redis:alpine
deploy:
resources:
limits:
memory: 64M
reservations:
memory: 64M
replicas: 5

View file

@ -0,0 +1,6 @@
version: "3.2"
services:
redis:
image: redis:alpine
deploy:
replicas: 2

View file

@ -0,0 +1,6 @@
version: "3.2"
services:
redis:
image: redis:alpine
deploy:
replicas: 5

View file

@ -0,0 +1,4 @@
version: "3.2"
services:
redis:
image: redis:alpine

View file

@ -0,0 +1,6 @@
version: "3.2"
services:
redis:
image: redis:alpine
deploy:
replicas: 5

View file

@ -0,0 +1,169 @@
// +build !ignore_autogenerated
// This file was autogenerated by conversion-gen. Do not edit it manually!
package v1beta1
import (
compose "github.com/docker/cli/kubernetes/compose"
conversion "k8s.io/apimachinery/pkg/conversion"
runtime "k8s.io/apimachinery/pkg/runtime"
)
func init() {
localSchemeBuilder.Register(RegisterConversions)
}
// RegisterConversions adds conversion functions to the given scheme.
// Public to allow building arbitrary schemes.
func RegisterConversions(scheme *runtime.Scheme) error {
return scheme.AddGeneratedConversionFuncs(
Convert_v1beta1_Owner_To_compose_Owner,
Convert_compose_Owner_To_v1beta1_Owner,
Convert_v1beta1_Stack_To_compose_Stack,
Convert_compose_Stack_To_v1beta1_Stack,
Convert_v1beta1_StackList_To_compose_StackList,
Convert_compose_StackList_To_v1beta1_StackList,
Convert_v1beta1_StackSpec_To_compose_StackSpec,
Convert_compose_StackSpec_To_v1beta1_StackSpec,
Convert_v1beta1_StackStatus_To_compose_StackStatus,
Convert_compose_StackStatus_To_v1beta1_StackStatus,
)
}
func autoConvert_v1beta1_Owner_To_compose_Owner(in *Owner, out *compose.Owner, s conversion.Scope) error {
out.ObjectMeta = in.ObjectMeta
out.Owner = in.Owner
return nil
}
// Convert_v1beta1_Owner_To_compose_Owner is an autogenerated conversion function.
func Convert_v1beta1_Owner_To_compose_Owner(in *Owner, out *compose.Owner, s conversion.Scope) error {
return autoConvert_v1beta1_Owner_To_compose_Owner(in, out, s)
}
func autoConvert_compose_Owner_To_v1beta1_Owner(in *compose.Owner, out *Owner, s conversion.Scope) error {
out.ObjectMeta = in.ObjectMeta
out.Owner = in.Owner
return nil
}
// Convert_compose_Owner_To_v1beta1_Owner is an autogenerated conversion function.
func Convert_compose_Owner_To_v1beta1_Owner(in *compose.Owner, out *Owner, s conversion.Scope) error {
return autoConvert_compose_Owner_To_v1beta1_Owner(in, out, s)
}
func autoConvert_v1beta1_Stack_To_compose_Stack(in *Stack, out *compose.Stack, s conversion.Scope) error {
out.ObjectMeta = in.ObjectMeta
if err := Convert_v1beta1_StackSpec_To_compose_StackSpec(&in.Spec, &out.Spec, s); err != nil {
return err
}
if err := Convert_v1beta1_StackStatus_To_compose_StackStatus(&in.Status, &out.Status, s); err != nil {
return err
}
return nil
}
// Convert_v1beta1_Stack_To_compose_Stack is an autogenerated conversion function.
func Convert_v1beta1_Stack_To_compose_Stack(in *Stack, out *compose.Stack, s conversion.Scope) error {
return autoConvert_v1beta1_Stack_To_compose_Stack(in, out, s)
}
func autoConvert_compose_Stack_To_v1beta1_Stack(in *compose.Stack, out *Stack, s conversion.Scope) error {
out.ObjectMeta = in.ObjectMeta
if err := Convert_compose_StackSpec_To_v1beta1_StackSpec(&in.Spec, &out.Spec, s); err != nil {
return err
}
if err := Convert_compose_StackStatus_To_v1beta1_StackStatus(&in.Status, &out.Status, s); err != nil {
return err
}
return nil
}
// Convert_compose_Stack_To_v1beta1_Stack is an autogenerated conversion function.
func Convert_compose_Stack_To_v1beta1_Stack(in *compose.Stack, out *Stack, s conversion.Scope) error {
return autoConvert_compose_Stack_To_v1beta1_Stack(in, out, s)
}
func autoConvert_v1beta1_StackList_To_compose_StackList(in *StackList, out *compose.StackList, s conversion.Scope) error {
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]compose.Stack, len(*in))
for i := range *in {
if err := Convert_v1beta1_Stack_To_compose_Stack(&(*in)[i], &(*out)[i], s); err != nil {
return err
}
}
} else {
out.Items = nil
}
return nil
}
// Convert_v1beta1_StackList_To_compose_StackList is an autogenerated conversion function.
func Convert_v1beta1_StackList_To_compose_StackList(in *StackList, out *compose.StackList, s conversion.Scope) error {
return autoConvert_v1beta1_StackList_To_compose_StackList(in, out, s)
}
func autoConvert_compose_StackList_To_v1beta1_StackList(in *compose.StackList, out *StackList, s conversion.Scope) error {
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]Stack, len(*in))
for i := range *in {
if err := Convert_compose_Stack_To_v1beta1_Stack(&(*in)[i], &(*out)[i], s); err != nil {
return err
}
}
} else {
out.Items = make([]Stack, 0)
}
return nil
}
// Convert_compose_StackList_To_v1beta1_StackList is an autogenerated conversion function.
func Convert_compose_StackList_To_v1beta1_StackList(in *compose.StackList, out *StackList, s conversion.Scope) error {
return autoConvert_compose_StackList_To_v1beta1_StackList(in, out, s)
}
func autoConvert_v1beta1_StackSpec_To_compose_StackSpec(in *StackSpec, out *compose.StackSpec, s conversion.Scope) error {
out.ComposeFile = in.ComposeFile
return nil
}
func Convert_compose_StackSpec_To_v1beta1_StackSpec(in *compose.StackSpec, out *StackSpec, s conversion.Scope) error {
return autoConvert_compose_StackSpec_To_v1beta1_StackSpec(in, out, s)
}
// Convert_v1beta1_StackSpec_To_compose_StackSpec is an autogenerated conversion function.
func Convert_v1beta1_StackSpec_To_compose_StackSpec(in *StackSpec, out *compose.StackSpec, s conversion.Scope) error {
return autoConvert_v1beta1_StackSpec_To_compose_StackSpec(in, out, s)
}
func autoConvert_compose_StackSpec_To_v1beta1_StackSpec(in *compose.StackSpec, out *StackSpec, s conversion.Scope) error {
out.ComposeFile = in.ComposeFile
return nil
}
func autoConvert_v1beta1_StackStatus_To_compose_StackStatus(in *StackStatus, out *compose.StackStatus, s conversion.Scope) error {
out.Phase = compose.StackPhase(in.Phase)
out.Message = in.Message
return nil
}
// Convert_v1beta1_StackStatus_To_compose_StackStatus is an autogenerated conversion function.
func Convert_v1beta1_StackStatus_To_compose_StackStatus(in *StackStatus, out *compose.StackStatus, s conversion.Scope) error {
return autoConvert_v1beta1_StackStatus_To_compose_StackStatus(in, out, s)
}
func autoConvert_compose_StackStatus_To_v1beta1_StackStatus(in *compose.StackStatus, out *StackStatus, s conversion.Scope) error {
out.Phase = StackPhase(in.Phase)
out.Message = in.Message
return nil
}
// Convert_compose_StackStatus_To_v1beta1_StackStatus is an autogenerated conversion function.
func Convert_compose_StackStatus_To_v1beta1_StackStatus(in *compose.StackStatus, out *StackStatus, s conversion.Scope) error {
return autoConvert_compose_StackStatus_To_v1beta1_StackStatus(in, out, s)
}

View file

@ -0,0 +1,205 @@
// +build !ignore_autogenerated
// This file was autogenerated by deepcopy-gen. Do not edit it manually!
package v1beta1
import (
reflect "reflect"
conversion "k8s.io/apimachinery/pkg/conversion"
runtime "k8s.io/apimachinery/pkg/runtime"
)
// Deprecated: register deep-copy functions.
func init() {
SchemeBuilder.Register(RegisterDeepCopies)
}
// Deprecated: RegisterDeepCopies adds deep-copy functions to the given scheme. Public
// to allow building arbitrary schemes.
func RegisterDeepCopies(scheme *runtime.Scheme) error {
return scheme.AddGeneratedDeepCopyFuncs(
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*Owner).DeepCopyInto(out.(*Owner))
return nil
}, InType: reflect.TypeOf(&Owner{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*OwnerList).DeepCopyInto(out.(*OwnerList))
return nil
}, InType: reflect.TypeOf(&OwnerList{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*Stack).DeepCopyInto(out.(*Stack))
return nil
}, InType: reflect.TypeOf(&Stack{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*StackList).DeepCopyInto(out.(*StackList))
return nil
}, InType: reflect.TypeOf(&StackList{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*StackSpec).DeepCopyInto(out.(*StackSpec))
return nil
}, InType: reflect.TypeOf(&StackSpec{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*StackStatus).DeepCopyInto(out.(*StackStatus))
return nil
}, InType: reflect.TypeOf(&StackStatus{})},
)
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Owner) DeepCopyInto(out *Owner) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
in.Owner.DeepCopyInto(&out.Owner)
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new Owner.
func (x *Owner) DeepCopy() *Owner {
if x == nil {
return nil
}
out := new(Owner)
x.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (x *Owner) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *OwnerList) DeepCopyInto(out *OwnerList) {
*out = *in
out.TypeMeta = in.TypeMeta
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]Owner, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new OwnerList.
func (x *OwnerList) DeepCopy() *OwnerList {
if x == nil {
return nil
}
out := new(OwnerList)
x.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (x *OwnerList) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Stack) DeepCopyInto(out *Stack) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
out.Spec = in.Spec
out.Status = in.Status
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new Stack.
func (x *Stack) DeepCopy() *Stack {
if x == nil {
return nil
}
out := new(Stack)
x.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (x *Stack) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *StackList) DeepCopyInto(out *StackList) {
*out = *in
out.TypeMeta = in.TypeMeta
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]Stack, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new StackList.
func (x *StackList) DeepCopy() *StackList {
if x == nil {
return nil
}
out := new(StackList)
x.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (x *StackList) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *StackSpec) DeepCopyInto(out *StackSpec) {
*out = *in
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new StackSpec.
func (x *StackSpec) DeepCopy() *StackSpec {
if x == nil {
return nil
}
out := new(StackSpec)
x.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *StackStatus) DeepCopyInto(out *StackStatus) {
*out = *in
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new StackStatus.
func (x *StackStatus) DeepCopy() *StackStatus {
if x == nil {
return nil
}
out := new(StackStatus)
x.DeepCopyInto(out)
return out
}

View file

@ -0,0 +1,233 @@
// +build !ignore_autogenerated
// This file was autogenerated by deepcopy-gen. Do not edit it manually!
package compose
import (
reflect "reflect"
conversion "k8s.io/apimachinery/pkg/conversion"
runtime "k8s.io/apimachinery/pkg/runtime"
)
// Deprecated: register deep-copy functions.
func init() {
SchemeBuilder.Register(RegisterDeepCopies)
}
// Deprecated: RegisterDeepCopies adds deep-copy functions to the given scheme. Public
// to allow building arbitrary schemes.
func RegisterDeepCopies(scheme *runtime.Scheme) error {
return scheme.AddGeneratedDeepCopyFuncs(
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*ImpersonationConfig).DeepCopyInto(out.(*ImpersonationConfig))
return nil
}, InType: reflect.TypeOf(&ImpersonationConfig{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*Owner).DeepCopyInto(out.(*Owner))
return nil
}, InType: reflect.TypeOf(&Owner{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*OwnerList).DeepCopyInto(out.(*OwnerList))
return nil
}, InType: reflect.TypeOf(&OwnerList{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*Stack).DeepCopyInto(out.(*Stack))
return nil
}, InType: reflect.TypeOf(&Stack{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*StackList).DeepCopyInto(out.(*StackList))
return nil
}, InType: reflect.TypeOf(&StackList{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*StackSpec).DeepCopyInto(out.(*StackSpec))
return nil
}, InType: reflect.TypeOf(&StackSpec{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*StackStatus).DeepCopyInto(out.(*StackStatus))
return nil
}, InType: reflect.TypeOf(&StackStatus{})},
)
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *ImpersonationConfig) DeepCopyInto(out *ImpersonationConfig) {
*out = *in
if in.Groups != nil {
in, out := &in.Groups, &out.Groups
*out = make([]string, len(*in))
copy(*out, *in)
}
if in.Extra != nil {
in, out := &in.Extra, &out.Extra
*out = make(map[string][]string, len(*in))
for key, val := range *in {
if val == nil {
(*out)[key] = nil
} else {
(*out)[key] = make([]string, len(val))
copy((*out)[key], val)
}
}
}
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new ImpersonationConfig.
func (x *ImpersonationConfig) DeepCopy() *ImpersonationConfig {
if x == nil {
return nil
}
out := new(ImpersonationConfig)
x.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Owner) DeepCopyInto(out *Owner) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
in.Owner.DeepCopyInto(&out.Owner)
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new Owner.
func (x *Owner) DeepCopy() *Owner {
if x == nil {
return nil
}
out := new(Owner)
x.DeepCopyInto(out)
return out
}
func (x *Owner) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *OwnerList) DeepCopyInto(out *OwnerList) {
*out = *in
out.TypeMeta = in.TypeMeta
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]Owner, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new OwnerList.
func (x *OwnerList) DeepCopy() *OwnerList {
if x == nil {
return nil
}
out := new(OwnerList)
x.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *Stack) DeepCopyInto(out *Stack) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
in.Spec.DeepCopyInto(&out.Spec)
out.Status = in.Status
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new Stack.
func (x *Stack) DeepCopy() *Stack {
if x == nil {
return nil
}
out := new(Stack)
x.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (x *Stack) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *StackList) DeepCopyInto(out *StackList) {
*out = *in
out.TypeMeta = in.TypeMeta
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]Stack, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new StackList.
func (x *StackList) DeepCopy() *StackList {
if x == nil {
return nil
}
out := new(StackList)
x.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (x *StackList) DeepCopyObject() runtime.Object {
if c := x.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *StackSpec) DeepCopyInto(out *StackSpec) {
*out = *in
in.Owner.DeepCopyInto(&out.Owner)
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new StackSpec.
func (x *StackSpec) DeepCopy() *StackSpec {
if x == nil {
return nil
}
out := new(StackSpec)
x.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *StackStatus) DeepCopyInto(out *StackStatus) {
*out = *in
return
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, creating a new StackStatus.
func (x *StackStatus) DeepCopy() *StackStatus {
if x == nil {
return nil
}
out := new(StackStatus)
x.DeepCopyInto(out)
return out
}