Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Hepto
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ACIDES
Hepto
Commits
b03ca69e
Commit
b03ca69e
authored
1 year ago
by
kaiyou
Browse files
Options
Downloads
Patches
Plain Diff
Disable unused post-start hooks (breaks rbac currently)
parent
58471cb8
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
services/apiserver.go
+12
-0
12 additions, 0 deletions
services/apiserver.go
with
12 additions
and
0 deletions
services/apiserver.go
+
12
−
0
View file @
b03ca69e
...
@@ -94,6 +94,17 @@ func buildConfig(c *Cluster) (config *server.Config, clients *Clients, err error
...
@@ -94,6 +94,17 @@ func buildConfig(c *Cluster) (config *server.Config, clients *Clients, err error
sets
.
NewString
(
"attach"
,
"exec"
,
"proxy"
,
"log"
,
"portforward"
),
sets
.
NewString
(
"attach"
,
"exec"
,
"proxy"
,
"log"
,
"portforward"
),
)
)
// Disable unneeded post start hooks, these cannot be easily disabled except at runtime, which still takes up
// space in the binary sadly
config
.
DisabledPostStartHooks
=
sets
.
NewString
(
// bootstrap-controller : TODO replace endpoint reconciler logic if required
"generic-apiserver-start-informers"
,
// they are started manually
"start-apiextensions-informers"
,
// started manually also
"storage-object-count-tracker-hook"
,
// unused
"start-legacy-token-tracking-controller"
,
// legacy and unused
"rbac/bootstrap-roles"
,
// TODO replaced with our own simpler RBAC
)
// Setup listener
// Setup listener
listener
,
err
:=
net
.
Listen
(
"tcp6"
,
fmt
.
Sprintf
(
"[%s]:%d"
,
c
.
networking
.
NodeAddress
.
IP
.
String
(),
apiserverPort
))
listener
,
err
:=
net
.
Listen
(
"tcp6"
,
fmt
.
Sprintf
(
"[%s]:%d"
,
c
.
networking
.
NodeAddress
.
IP
.
String
(),
apiserverPort
))
if
err
!=
nil
{
if
err
!=
nil
{
...
@@ -328,6 +339,7 @@ var kubeApiserver = &Unit{
...
@@ -328,6 +339,7 @@ var kubeApiserver = &Unit{
// Finally start the apiserver
// Finally start the apiserver
server
:=
apiServer
.
GenericAPIServer
.
PrepareRun
()
server
:=
apiServer
.
GenericAPIServer
.
PrepareRun
()
go
clients
.
Start
(
ctx
)
return
server
.
Run
(
ctx
.
Done
())
return
server
.
Run
(
ctx
.
Done
())
},
},
Ready
:
func
(
u
*
Unit
,
c
*
Cluster
)
bool
{
Ready
:
func
(
u
*
Unit
,
c
*
Cluster
)
bool
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment