You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.MD
+7-7
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
# Kube PodSecurityPolicy Advisor
1
+
# Kube Policy Advisor
2
2
3
3
kube-policy-advisor is a tool that makes it easier to create K8s Pod Security Policies (PSPs) or OPA Policy from either a live K8s environment or from a single .yaml file containing a pod specification (Deployment, DaemonSet, Pod, etc).
4
4
@@ -9,22 +9,22 @@ It has 2 subcommands, `kube-policy-advisor inspect` and `kube-policy-advisor con
9
9
Follow the [instructions](https://github.com/kubernetes-sigs/krew#installation) to install `krew`. Then run the following command:
10
10
11
11
```
12
-
kubectl krew install advise-psp
12
+
kubectl krew install advise-policy
13
13
```
14
14
15
-
The plugin will be available as `kubectl advise-psp`.
15
+
The plugin will be available as `kubectl advise-policy`.
16
16
17
17
## Build and Run locally
18
18
1.```make build```
19
19
2.```./kube-policy-advisor inspect``` to generate Pod Security Policy based on running cluster configuration
20
20
- 2.1 ```./kube-policy-advisor inspect --report``` to print the details reports (why this PSP is recommended for the cluster)
21
21
- 2.2 ```./kube-policy-advisor inspect --grant``` to print PSPs, roles and rolebindings for service accounts (refer to [psp-grant.yaml](./test-yaml/psp-grant.yaml))
22
22
- 2.3 ```./kube-policy-advisor inspect --namespace=<ns>``` to print report or PSP(s) within a given namespace (default to all)
23
-
- 2.4 ```./kube-policy-advisor inspect --opa``` to generate OPA Policy based on running cluster configuration
24
-
- 2.5 ```./kube-policy-advisor inspect --opa --deny-by-default``` to generate an OPA Policy, where OPA Default Rule is Deny ALL
23
+
- 2.4 ```./kube-policy-advisor inspect --policy opa``` to generate OPA Policy based on running cluster configuration
24
+
- 2.5 ```./kube-policy-advisor inspect --policy opa --deny-by-default``` to generate an OPA Policy, where OPA Default Rule is Deny ALL
25
25
4.```./kube-policy-advisor convert --podFile <path> --pspFile <path>``` to generate a PSP from a single .yaml file.
26
-
- 4.1 ```./kube-policy-advisor convert --podFile <path> --pspFile <path> --opa``` to generate an OPA Policy from a single .yaml file.
27
-
- 4.2 ```./kube-policy-advisor convert --podFile <path> --pspFile <path> --opa --deny-by-default``` to generate an OPA Policy from a single .yaml file, where OPA Default Rule is Deny ALL.
26
+
- 4.1 ```./kube-policy-advisor convert --policy opa --podFile <path> --pspFile <path> ``` to generate an OPA Policy from a single .yaml file.
27
+
- 4.2 ```./kube-policy-advisor convert --policy opa --podFile <path> --pspFile <path> --deny-by-default``` to generate an OPA Policy from a single .yaml file, where OPA Default Rule is Deny ALL.
0 commit comments