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
d861631f
Commit
d861631f
authored
Jun 02, 2015
by
Brian Grant
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #9142 from roberthbailey/kubelet-on-master
Prevent access to the /run and /exec endpoints on the master's kubelet
parents
36a4ece8
1dad552e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
default
cluster/saltbase/salt/kubelet/default
+6
-2
No files found.
cluster/saltbase/salt/kubelet/default
View file @
d861631f
...
@@ -22,11 +22,15 @@
...
@@ -22,11 +22,15 @@
{% set api_servers_with_port = api_servers + ":6443" -%}
{% set api_servers_with_port = api_servers + ":6443" -%}
{% endif -%}
{% endif -%}
# Disable registration for the kubelet running on the master on GCE.
# Disable registration for the kubelet running on the master on GCE. Also disable
# the debugging handlers (/run and /exec) to prevent arbitrary code execution on
# the master.
# TODO(roberthbailey): Make this configurable via an env var in config-default.sh
# TODO(roberthbailey): Make this configurable via an env var in config-default.sh
{% set debugging_handlers = "--enable-debugging-handlers=true" -%}
{% if grains.cloud == 'gce' -%}
{% if grains.cloud == 'gce' -%}
{% if grains['roles'][0] == 'kubernetes-master' -%}
{% if grains['roles'][0] == 'kubernetes-master' -%}
{% set api_servers_with_port = "" -%}
{% set api_servers_with_port = "" -%}
{% set debugging_handlers = "--enable-debugging-handlers=false" -%}
{% endif -%}
{% endif -%}
{% endif -%}
{% endif -%}
...
@@ -71,4 +75,4 @@
...
@@ -71,4 +75,4 @@
{% set cgroup_root = "--cgroup_root=/" -%}
{% set cgroup_root = "--cgroup_root=/" -%}
{% endif -%}
{% endif -%}
DAEMON_ARGS="{{daemon_args}} {{api_servers_with_port}} {{hostname_override}} {{cloud_provider}} {{config}} --allow_privileged={{pillar['allow_privileged']}} {{pillar['log_level']}} {{cluster_dns}} {{cluster_domain}} {{docker_root}} {{kubelet_root}} {{configure_cbr0}} {{cgroup_root}} {{system_container}}"
DAEMON_ARGS="{{daemon_args}} {{api_servers_with_port}} {{
debugging_handlers}} {{
hostname_override}} {{cloud_provider}} {{config}} --allow_privileged={{pillar['allow_privileged']}} {{pillar['log_level']}} {{cluster_dns}} {{cluster_domain}} {{docker_root}} {{kubelet_root}} {{configure_cbr0}} {{cgroup_root}} {{system_container}}"
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