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
f6a04ea9
Commit
f6a04ea9
authored
Jul 17, 2019
by
YAMAMOTO Takashi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a few comments in bootstrap.go
parent
d140911b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
bootstrap.go
pkg/daemons/control/bootstrap.go
+4
-0
No files found.
pkg/daemons/control/bootstrap.go
View file @
f6a04ea9
...
@@ -45,6 +45,8 @@ var validBootstrapTypes = map[string]bool{
...
@@ -45,6 +45,8 @@ var validBootstrapTypes = map[string]bool{
bootstrapTypeFull
:
true
,
bootstrapTypeFull
:
true
,
}
}
// fetchBootstrapData copies the bootstrap data (certs, keys, passwords)
// from etcd to inidividual files specified by cfg.Runtime.
func
fetchBootstrapData
(
cfg
*
config
.
Control
)
error
{
func
fetchBootstrapData
(
cfg
*
config
.
Control
)
error
{
if
valid
,
err
:=
checkBootstrapArgs
(
cfg
,
map
[
string
]
bool
{
if
valid
,
err
:=
checkBootstrapArgs
(
cfg
,
map
[
string
]
bool
{
bootstrapTypeFull
:
true
,
bootstrapTypeFull
:
true
,
...
@@ -95,6 +97,8 @@ func fetchBootstrapData(cfg *config.Control) error {
...
@@ -95,6 +97,8 @@ func fetchBootstrapData(cfg *config.Control) error {
return
writeRuntimeBootstrapData
(
cfg
.
Runtime
,
serverRuntime
)
return
writeRuntimeBootstrapData
(
cfg
.
Runtime
,
serverRuntime
)
}
}
// storeBootstrapData copies the bootstrap data in the opposite direction to
// fetchBootstrapData.
func
storeBootstrapData
(
cfg
*
config
.
Control
)
error
{
func
storeBootstrapData
(
cfg
*
config
.
Control
)
error
{
if
valid
,
err
:=
checkBootstrapArgs
(
cfg
,
map
[
string
]
bool
{
if
valid
,
err
:=
checkBootstrapArgs
(
cfg
,
map
[
string
]
bool
{
bootstrapTypeFull
:
true
,
bootstrapTypeFull
:
true
,
...
...
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