Skip to content
This repository has been archived by the owner on May 6, 2022. It is now read-only.

Capture information about the user that created an instance or binding #939

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions pkg/apis/servicecatalog/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,18 @@ type InstanceList struct {
Items []Instance
}

// AlphaUserInfo holds information about the user that created a resource.
type AlphaUserInfo struct {
Username string
UID string
Groups []string
Extra map[string]AlphaExtraValue
}

// AlphaExtraValue contains additional information about a user that may be
// provided by the authenticator.
type AlphaExtraValue []string

// +genclient=true

// Instance represents a provisioned instance of a ServiceClass.
Expand Down Expand Up @@ -327,6 +339,14 @@ type InstanceSpec struct {
//
// Immutable.
ExternalID string

// Currently, this field is ALPHA: it may change or disappear at any time
// and its data will not be migrated.
//
// AlphaUser contains information about the user that created this
// instance. This field is set by the API server and not settable by the
// end-user. User-provided values for this field are not saved.
AlphaUser AlphaUserInfo
}

// InstanceStatus represents the current status of an Instance.
Expand Down Expand Up @@ -439,6 +459,14 @@ type BindingSpec struct {
//
// Immutable.
ExternalID string

// Currently, this field is ALPHA: it may change or disappear at any time
// and its data will not be migrated.
//
// AlphaUser contains information about the user that created this
// binding. This field is set by the API server and not settable by the
// end-user. User-provided values for this field are not saved.
AlphaUser AlphaUserInfo
}

// BindingStatus represents the current status of a Binding.
Expand Down
Loading