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
21b422fc
Unverified
Commit
21b422fc
authored
Jan 06, 2017
by
Jordan Liggitt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow enabling ABAC authz
parent
1fe517e9
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
5 deletions
+24
-5
configure-helper.sh
cluster/gce/container-linux/configure-helper.sh
+9
-3
configure-helper.sh
cluster/gce/gci/configure-helper.sh
+9
-2
exceptions.txt
hack/verify-flags/exceptions.txt
+6
-0
No files found.
cluster/gce/container-linux/configure-helper.sh
View file @
21b422fc
...
...
@@ -814,16 +814,22 @@ function start-kube-apiserver {
webhook_authn_config_volume
=
"{
\"
name
\"
:
\"
webhookauthnconfigmount
\"
,
\"
hostPath
\"
: {
\"
path
\"
:
\"
/etc/gcp_authn.config
\"
}},"
fi
params+
=
" --authorization-mode=RBAC"
local
authorization_mode
=
"RBAC"
if
[[
-n
"
${
ABAC_AUTHZ_FILE
:-}
"
&&
-e
"
${
ABAC_AUTHZ_FILE
}
"
]]
;
then
params+
=
" --authorization-policy-file=
${
ABAC_AUTHZ_FILE
}
"
authorization_mode+
=
",ABAC"
fi
local
webhook_config_mount
=
""
local
webhook_config_volume
=
""
if
[[
-n
"
${
GCP_AUTHZ_URL
:-}
"
]]
;
then
params+
=
",Webhook --authorization-webhook-config-file=/etc/gcp_authz.config"
authorization_mode+
=
",Webhook"
params+
=
" --authorization-webhook-config-file=/etc/gcp_authz.config"
webhook_config_mount
=
"{
\"
name
\"
:
\"
webhookconfigmount
\"
,
\"
mountPath
\"
:
\"
/etc/gcp_authz.config
\"
,
\"
readOnly
\"
: false},"
webhook_config_volume
=
"{
\"
name
\"
:
\"
webhookconfigmount
\"
,
\"
hostPath
\"
: {
\"
path
\"
:
\"
/etc/gcp_authz.config
\"
}},"
fi
local
-r
src_dir
=
"
${
KUBE_HOME
}
/kube-manifests/kubernetes/gci-trusty"
params+
=
" --authorization-mode=
${
authorization_mode
}
"
src_file
=
"
${
src_dir
}
/kube-apiserver.manifest"
remove-salt-config-comments
"
${
src_file
}
"
# Evaluate variables.
...
...
cluster/gce/gci/configure-helper.sh
View file @
21b422fc
...
...
@@ -878,15 +878,22 @@ function start-kube-apiserver {
webhook_authn_config_volume
=
"{
\"
name
\"
:
\"
webhookauthnconfigmount
\"
,
\"
hostPath
\"
: {
\"
path
\"
:
\"
/etc/gcp_authn.config
\"
}},"
fi
params+
=
" --authorization-mode=RBAC"
local
authorization_mode
=
"RBAC"
if
[[
-n
"
${
ABAC_AUTHZ_FILE
:-}
"
&&
-e
"
${
ABAC_AUTHZ_FILE
}
"
]]
;
then
params+
=
" --authorization-policy-file=
${
ABAC_AUTHZ_FILE
}
"
authorization_mode+
=
",ABAC"
fi
local
webhook_config_mount
=
""
local
webhook_config_volume
=
""
if
[[
-n
"
${
GCP_AUTHZ_URL
:-}
"
]]
;
then
params+
=
",Webhook --authorization-webhook-config-file=/etc/gcp_authz.config"
authorization_mode+
=
",Webhook"
params+
=
" --authorization-webhook-config-file=/etc/gcp_authz.config"
webhook_config_mount
=
"{
\"
name
\"
:
\"
webhookconfigmount
\"
,
\"
mountPath
\"
:
\"
/etc/gcp_authz.config
\"
,
\"
readOnly
\"
: false},"
webhook_config_volume
=
"{
\"
name
\"
:
\"
webhookconfigmount
\"
,
\"
hostPath
\"
: {
\"
path
\"
:
\"
/etc/gcp_authz.config
\"
}},"
fi
local
-r
src_dir
=
"
${
KUBE_HOME
}
/kube-manifests/kubernetes/gci-trusty"
params+
=
" --authorization-mode=
${
authorization_mode
}
"
src_file
=
"
${
src_dir
}
/kube-apiserver.manifest"
remove-salt-config-comments
"
${
src_file
}
"
...
...
hack/verify-flags/exceptions.txt
View file @
21b422fc
...
...
@@ -12,10 +12,16 @@ cluster/gce/configure-vm.sh: cloud_config: ${CLOUD_CONFIG}
cluster/gce/configure-vm.sh: env-to-grains "feature_gates"
cluster/gce/configure-vm.sh: env-to-grains "runtime_config"
cluster/gce/configure-vm.sh: kubelet_api_servers: '${KUBELET_APISERVER}'
cluster/gce/container-linux/configure-helper.sh: authorization_mode+=",ABAC"
cluster/gce/container-linux/configure-helper.sh: authorization_mode+=",Webhook"
cluster/gce/container-linux/configure-helper.sh: local api_servers="--master=https://${KUBERNETES_MASTER_NAME}"
cluster/gce/container-linux/configure-helper.sh: local authorization_mode="RBAC"
cluster/gce/container-linux/configure-helper.sh: sed -i -e "s@{{ *storage_backend *}}@${STORAGE_BACKEND:-}@g" "${temp_file}"
cluster/gce/container-linux/configure-helper.sh: sed -i -e "s@{{pillar\['allow_privileged'\]}}@true@g" "${src_file}"
cluster/gce/gci/configure-helper.sh: authorization_mode+=",ABAC"
cluster/gce/gci/configure-helper.sh: authorization_mode+=",Webhook"
cluster/gce/gci/configure-helper.sh: local api_servers="--master=https://${KUBERNETES_MASTER_NAME}"
cluster/gce/gci/configure-helper.sh: local authorization_mode="RBAC"
cluster/gce/gci/configure-helper.sh: sed -i -e "s@{{ *storage_backend *}}@${STORAGE_BACKEND:-}@g" "${temp_file}"
cluster/gce/gci/configure-helper.sh: sed -i -e "s@{{pillar\['allow_privileged'\]}}@true@g" "${src_file}"
cluster/gce/trusty/configure-helper.sh: sed -i -e "s@{{ *storage_backend *}}@${STORAGE_BACKEND:-}@g" "${temp_file}"
...
...
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