From 8d99ba94c84e85f34b1494a085e69870ce491b20 Mon Sep 17 00:00:00 2001 From: xiejunan Date: Mon, 10 Aug 2015 18:46:13 +0800 Subject: [PATCH] modify example and doc for ABAC authorization --- docs/admin/authorization.md | 2 +- pkg/auth/authorizer/abac/example_policy_file.jsonl | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/admin/authorization.md b/docs/admin/authorization.md index e0564b6544165..6dad2a51a14c2 100644 --- a/docs/admin/authorization.md +++ b/docs/admin/authorization.md @@ -111,7 +111,7 @@ To permit an action Policy with an unset namespace applies regardless of namespa 1. Alice can do anything: `{"user":"alice"}` 2. Kubelet can read any pods: `{"user":"kubelet", "resource": "pods", "readonly": true}` 3. Kubelet can read and write events: `{"user":"kubelet", "resource": "events"}` - 4. Bob can just read pods in namespace "projectCaribou": `{"user":"bob", "resource": "pods", "readonly": true, "ns": "projectCaribou"}` + 4. Bob can just read pods in namespace "projectCaribou": `{"user":"bob", "resource": "pods", "readonly": true, "namespace": "projectCaribou"}` [Complete file example](http://releases.k8s.io/HEAD/pkg/auth/authorizer/abac/example_policy_file.jsonl) diff --git a/pkg/auth/authorizer/abac/example_policy_file.jsonl b/pkg/auth/authorizer/abac/example_policy_file.jsonl index a9bdb9eea0225..554d97e527032 100644 --- a/pkg/auth/authorizer/abac/example_policy_file.jsonl +++ b/pkg/auth/authorizer/abac/example_policy_file.jsonl @@ -5,5 +5,5 @@ {"user":"kubelet", "readonly": true, "resource": "services"} {"user":"kubelet", "readonly": true, "resource": "endpoints"} {"user":"kubelet", "resource": "events"} -{"user":"alice", "ns": "projectCaribou"} -{"user":"bob", "readonly": true, "ns": "projectCaribou"} +{"user":"alice", "namespace": "projectCaribou"} +{"user":"bob", "readonly": true, "namespace": "projectCaribou"}