Skip to content

Commit 5605549

Browse files
committed
Fix Initial Commit
1 parent b3cb8b5 commit 5605549

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

.krew.yaml

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: krew.googlecontainertools.github.com/v1alpha2
22
kind: Plugin
33
metadata:
4-
name: advise-psp
4+
name: advise-policy
55
spec:
66
version: {{ .TagName }}
77
homepage: https://github.com/sysdiglabs/kube-policy-advisor
@@ -11,14 +11,14 @@ spec:
1111
os: darwin
1212
arch: amd64
1313
{{addURIAndSha "https://github.com/sysdiglabs/kube-policy-advisor/releases/download/{{ .TagName }}/kube-policy-advisor_{{ .TagName }}_darwin_amd64.tar.gz" .TagName }}
14-
bin: kubectl-advise-psp
14+
bin: kubectl-advise-policy
1515
- selector:
1616
matchLabels:
1717
os: linux
1818
arch: amd64
1919
{{addURIAndSha "https://github.com/sysdiglabs/kube-policy-advisor/releases/download/{{ .TagName }}/kube-policy-advisor_{{ .TagName }}_linux_amd64.tar.gz" .TagName }}
20-
bin: kubectl-advise-psp
21-
shortDescription: Suggests PodSecurityPolicies for cluster.
20+
bin: kubectl-advise-policy
21+
shortDescription: Suggests PodSecurityPolicies and OPA Policies for cluster.
2222
description: |
23-
Suggests PSPs based on the required capabilities of the currently running
23+
Suggests PSPs and OPA Policies based on the required capabilities of the currently running
2424
workloads or a given manifest.

README.MD

+7-7
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Kube PodSecurityPolicy Advisor
1+
# Kube Policy Advisor
22

33
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).
44

@@ -9,22 +9,22 @@ It has 2 subcommands, `kube-policy-advisor inspect` and `kube-policy-advisor con
99
Follow the [instructions](https://github.com/kubernetes-sigs/krew#installation) to install `krew`. Then run the following command:
1010

1111
```
12-
kubectl krew install advise-psp
12+
kubectl krew install advise-policy
1313
```
1414

15-
The plugin will be available as `kubectl advise-psp`.
15+
The plugin will be available as `kubectl advise-policy`.
1616

1717
## Build and Run locally
1818
1. ```make build```
1919
2. ```./kube-policy-advisor inspect``` to generate Pod Security Policy based on running cluster configuration
2020
- 2.1 ```./kube-policy-advisor inspect --report``` to print the details reports (why this PSP is recommended for the cluster)
2121
- 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))
2222
- 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
2525
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.
2828

2929
## Build and Run as Container
3030
1. ```docker build -t <Image Name> -f container/Dockerfile .```

0 commit comments

Comments
 (0)