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
af5714da
Commit
af5714da
authored
Oct 08, 2014
by
Daniel Smith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix v1beta2 types having been copied incorrectly.
parent
e1cb72f1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
67 deletions
+1
-67
conversion.go
pkg/api/v1beta2/conversion.go
+0
-54
types.go
pkg/api/v1beta2/types.go
+1
-13
No files found.
pkg/api/v1beta2/conversion.go
View file @
af5714da
...
@@ -58,59 +58,5 @@ func init() {
...
@@ -58,59 +58,5 @@ func init() {
}
}
return
nil
return
nil
},
},
// EnvVar's Key is deprecated in favor of Name.
func
(
in
*
newer
.
EnvVar
,
out
*
EnvVar
,
s
conversion
.
Scope
)
error
{
out
.
Value
=
in
.
Value
out
.
Key
=
in
.
Name
out
.
Name
=
in
.
Name
return
nil
},
func
(
in
*
EnvVar
,
out
*
newer
.
EnvVar
,
s
conversion
.
Scope
)
error
{
out
.
Value
=
in
.
Value
if
in
.
Name
!=
""
{
out
.
Name
=
in
.
Name
}
else
{
out
.
Name
=
in
.
Key
}
return
nil
},
// Path & MountType are deprecated.
func
(
in
*
newer
.
VolumeMount
,
out
*
VolumeMount
,
s
conversion
.
Scope
)
error
{
out
.
Name
=
in
.
Name
out
.
ReadOnly
=
in
.
ReadOnly
out
.
MountPath
=
in
.
MountPath
out
.
Path
=
in
.
MountPath
out
.
MountType
=
""
// MountType is ignored.
return
nil
},
func
(
in
*
VolumeMount
,
out
*
newer
.
VolumeMount
,
s
conversion
.
Scope
)
error
{
out
.
Name
=
in
.
Name
out
.
ReadOnly
=
in
.
ReadOnly
if
in
.
MountPath
==
""
{
out
.
MountPath
=
in
.
Path
}
else
{
out
.
MountPath
=
in
.
MountPath
}
return
nil
},
// MinionList.Items had a wrong name in v1beta1
func
(
in
*
newer
.
MinionList
,
out
*
MinionList
,
s
conversion
.
Scope
)
error
{
s
.
Convert
(
&
in
.
TypeMeta
,
&
out
.
TypeMeta
,
0
)
s
.
Convert
(
&
in
.
Items
,
&
out
.
Items
,
0
)
out
.
Minions
=
out
.
Items
return
nil
},
func
(
in
*
MinionList
,
out
*
newer
.
MinionList
,
s
conversion
.
Scope
)
error
{
s
.
Convert
(
&
in
.
TypeMeta
,
&
out
.
TypeMeta
,
0
)
if
len
(
in
.
Items
)
==
0
{
s
.
Convert
(
&
in
.
Minions
,
&
out
.
Items
,
0
)
}
else
{
s
.
Convert
(
&
in
.
Items
,
&
out
.
Items
,
0
)
}
return
nil
},
)
)
}
}
pkg/api/v1beta2/types.go
View file @
af5714da
...
@@ -131,22 +131,13 @@ type VolumeMount struct {
...
@@ -131,22 +131,13 @@ type VolumeMount struct {
// Optional: Defaults to false (read-write).
// Optional: Defaults to false (read-write).
ReadOnly
bool
`yaml:"readOnly,omitempty" json:"readOnly,omitempty"`
ReadOnly
bool
`yaml:"readOnly,omitempty" json:"readOnly,omitempty"`
// Required.
// Required.
// Exactly one of the following must be set. If both are set, prefer MountPath.
// DEPRECATED: Path will be removed in a future version of the API.
MountPath
string
`yaml:"mountPath,omitempty" json:"mountPath,omitempty"`
MountPath
string
`yaml:"mountPath,omitempty" json:"mountPath,omitempty"`
Path
string
`yaml:"path,omitempty" json:"path,omitempty"`
// One of: "LOCAL" (local volume) or "HOST" (external mount from the host). Default: LOCAL.
// DEPRECATED: MountType will be removed in a future version of the API.
MountType
string
`yaml:"mountType,omitempty" json:"mountType,omitempty"`
}
}
// EnvVar represents an environment variable present in a Container.
// EnvVar represents an environment variable present in a Container.
type
EnvVar
struct
{
type
EnvVar
struct
{
// Required: This must be a C_IDENTIFIER.
// Required: This must be a C_IDENTIFIER.
// Exactly one of the following must be set. If both are set, prefer Name.
// DEPRECATED: EnvVar.Key will be removed in a future version of the API.
Name
string
`yaml:"name" json:"name"`
Name
string
`yaml:"name" json:"name"`
Key
string
`yaml:"key,omitempty" json:"key,omitempty"`
// Optional: defaults to "".
// Optional: defaults to "".
Value
string
`yaml:"value,omitempty" json:"value,omitempty"`
Value
string
`yaml:"value,omitempty" json:"value,omitempty"`
}
}
...
@@ -464,10 +455,7 @@ type Minion struct {
...
@@ -464,10 +455,7 @@ type Minion struct {
// MinionList is a list of minions.
// MinionList is a list of minions.
type
MinionList
struct
{
type
MinionList
struct
{
TypeMeta
`json:",inline" yaml:",inline"`
TypeMeta
`json:",inline" yaml:",inline"`
// DEPRECATED: the below Minions is due to a naming mistake and
Items
[]
Minion
`json:"items,omitempty" yaml:"items,omitempty"`
// will be replaced with Items in the future.
Minions
[]
Minion
`json:"minions,omitempty" yaml:"minions,omitempty"`
Items
[]
Minion
`json:"items,omitempty" yaml:"items,omitempty"`
}
}
// Binding is written by a scheduler to cause a pod to be bound to a host.
// Binding is written by a scheduler to cause a pod to be bound to a host.
...
...
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