Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
e4c82b3d
Commit
e4c82b3d
authored
Aug 04, 2018
by
xing-yang
Committed by
Xing Yang
Aug 28, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add TypedLocalObjectReference and DataSource
This PR adds TypedLocalObjectReference in the core API and adds DataSource in PersistentVolumeClaimSpec.
parent
d46d6715
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
0 deletions
+29
-0
types.go
pkg/apis/core/types.go
+13
-0
types.go
staging/src/k8s.io/api/core/v1/types.go
+16
-0
No files found.
pkg/apis/core/types.go
View file @
e4c82b3d
...
...
@@ -413,6 +413,9 @@ type PersistentVolumeClaimSpec struct {
// This is an alpha feature and may change in the future.
// +optional
VolumeMode
*
PersistentVolumeMode
// If specified, volume will be prepopulated with data from the DataSource.
// +optional
DataSource
*
TypedLocalObjectReference
}
type
PersistentVolumeClaimConditionType
string
...
...
@@ -3960,6 +3963,16 @@ type LocalObjectReference struct {
Name
string
}
// TypedLocalObjectReference contains enough information to let you locate the typed referenced object inside the same namespace.
type
TypedLocalObjectReference
struct
{
// Name of the referent.
// +optional
Name
string
// Kind of the referent.
// +optional
Kind
string
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
type
SerializedReference
struct
{
...
...
staging/src/k8s.io/api/core/v1/types.go
View file @
e4c82b3d
...
...
@@ -458,6 +458,9 @@ type PersistentVolumeClaimSpec struct {
// This is an alpha feature and may change in the future.
// +optional
VolumeMode
*
PersistentVolumeMode
`json:"volumeMode,omitempty" protobuf:"bytes,6,opt,name=volumeMode,casttype=PersistentVolumeMode"`
// If specified, volume will be prepopulated with data from the DataSource.
// +optional
DataSource
*
TypedLocalObjectReference
`json:"dataSource" protobuf:"bytes,7,opt,name=dataSource"`
}
// PersistentVolumeClaimConditionType is a valid value of PersistentVolumeClaimCondition.Type
...
...
@@ -4478,6 +4481,19 @@ type LocalObjectReference struct {
Name
string
`json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
}
// TypedLocalObjectReference contains enough information to let you locate the
// typed referenced object inside the same namespace.
type
TypedLocalObjectReference
struct
{
// Name of the referent.
// More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
// +optional
Name
string
`json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
// Kind of the referent.
// More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
// +optional
Kind
string
`json:"kind,omitempty" protobuf:"bytes,2,opt,name=kind"`
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// SerializedReference is a reference to serialized object.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment