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
0cbabdd9
Unverified
Commit
0cbabdd9
authored
Jun 30, 2017
by
Lucas Käldström
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kubeadm: Remove some old comments
parent
d20c60de
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
0 additions
and
17 deletions
+0
-17
cmd.go
cmd/kubeadm/app/cmd/cmd.go
+0
-11
clusterroles.go
cmd/kubeadm/app/phases/apiconfig/clusterroles.go
+0
-2
pki_helpers.go
cmd/kubeadm/app/phases/certs/pkiutil/pki_helpers.go
+0
-3
checks.go
cmd/kubeadm/app/preflight/checks.go
+0
-1
No files found.
cmd/kubeadm/app/cmd/cmd.go
View file @
0cbabdd9
...
@@ -63,17 +63,6 @@ func NewKubeadmCommand(f cmdutil.Factory, in io.Reader, out, err io.Writer) *cob
...
@@ -63,17 +63,6 @@ func NewKubeadmCommand(f cmdutil.Factory, in io.Reader, out, err io.Writer) *cob
`
),
`
),
}
}
// TODO(phase2+) figure out how to avoid running as root
//
// TODO(phase2) detect interactive vs non-interactive use and adjust output accordingly
// i.e. make it automation friendly
//
// TODO(phase2) create an abstraction that defines files and the content that needs to
// be written to disc and write it all in one go at the end as we have a lot of
// crappy little files written from different parts of this code; this could also
// be useful for testing by having this model we can allow users to create some files before
// `kubeadm init` runs, e.g. PKI assets, we would then be able to look at files users has
// given an diff or validate if those are sane, we could also warn if any of the files had been deprecated
cmds
.
ResetFlags
()
cmds
.
ResetFlags
()
cmds
.
SetGlobalNormalizationFunc
(
flag
.
WarnWordSepNormalizeFunc
)
cmds
.
SetGlobalNormalizationFunc
(
flag
.
WarnWordSepNormalizeFunc
)
...
...
cmd/kubeadm/app/phases/apiconfig/clusterroles.go
View file @
0cbabdd9
...
@@ -46,8 +46,6 @@ const (
...
@@ -46,8 +46,6 @@ const (
nodeAutoApproveBootstrap
=
"kubeadm:node-autoapprove-bootstrap"
nodeAutoApproveBootstrap
=
"kubeadm:node-autoapprove-bootstrap"
)
)
// TODO: Are there any unit tests that could be made for this file other than duplicating all values and logic in a separate file?
// CreateServiceAccounts creates the necessary serviceaccounts that kubeadm uses/might use, if they don't already exist.
// CreateServiceAccounts creates the necessary serviceaccounts that kubeadm uses/might use, if they don't already exist.
func
CreateServiceAccounts
(
clientset
clientset
.
Interface
)
error
{
func
CreateServiceAccounts
(
clientset
clientset
.
Interface
)
error
{
serviceAccounts
:=
[]
v1
.
ServiceAccount
{
serviceAccounts
:=
[]
v1
.
ServiceAccount
{
...
...
cmd/kubeadm/app/phases/certs/pkiutil/pki_helpers.go
View file @
0cbabdd9
...
@@ -27,9 +27,6 @@ import (
...
@@ -27,9 +27,6 @@ import (
certutil
"k8s.io/client-go/util/cert"
certutil
"k8s.io/client-go/util/cert"
)
)
// TODO: It should be able to generate different types of private keys, at least: RSA and ECDSA (and in the future maybe Ed25519 as well)
// TODO: See if it makes sense to move this package directly to pkg/util/cert
func
NewCertificateAuthority
()
(
*
x509
.
Certificate
,
*
rsa
.
PrivateKey
,
error
)
{
func
NewCertificateAuthority
()
(
*
x509
.
Certificate
,
*
rsa
.
PrivateKey
,
error
)
{
key
,
err
:=
certutil
.
NewPrivateKey
()
key
,
err
:=
certutil
.
NewPrivateKey
()
if
err
!=
nil
{
if
err
!=
nil
{
...
...
cmd/kubeadm/app/preflight/checks.go
View file @
0cbabdd9
...
@@ -141,7 +141,6 @@ type PortOpenCheck struct {
...
@@ -141,7 +141,6 @@ type PortOpenCheck struct {
func
(
poc
PortOpenCheck
)
Check
()
(
warnings
,
errors
[]
error
)
{
func
(
poc
PortOpenCheck
)
Check
()
(
warnings
,
errors
[]
error
)
{
errors
=
[]
error
{}
errors
=
[]
error
{}
// TODO: Get IP from KubeadmConfig
ln
,
err
:=
net
.
Listen
(
"tcp"
,
fmt
.
Sprintf
(
":%d"
,
poc
.
port
))
ln
,
err
:=
net
.
Listen
(
"tcp"
,
fmt
.
Sprintf
(
":%d"
,
poc
.
port
))
if
err
!=
nil
{
if
err
!=
nil
{
errors
=
append
(
errors
,
fmt
.
Errorf
(
"Port %d is in use"
,
poc
.
port
))
errors
=
append
(
errors
,
fmt
.
Errorf
(
"Port %d is in use"
,
poc
.
port
))
...
...
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