Skip to content

Commit

Permalink
Fix typos (#134)
Browse files Browse the repository at this point in the history
* Fixed typo in disallow cluster admin readme

* Fix typos in 'prevent default service account usage' readme
  • Loading branch information
galshi authored Oct 19, 2021
1 parent 7573db2 commit 473fbe9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Prevent Default Serviceaccount
# Disallow Cluster Admin

The policy initiates an alert once a cluster-admin privilages have been granted to unapproved subjects (users, groups, serviceaccounts).
The policy initiates an alert once a cluster-admin privileges have been granted to unapproved subjects (users, groups, serviceaccounts).

cluster-admin is the most powerful ClusterRole that Openshift has for its users; Once it has been granted to a subject - this subject can perform any operation on the entire cluster; The best practice for managing it appropriatly is to raise an alert for any unauthorized entity that it has been granted to in the environment.

Expand All @@ -14,7 +14,7 @@ The required procedure to deploy the policy:
* Note that any openshift-* & kubernetes-* default namespaces are excluded
4. Run the test commands to make sure the policy works as expected

`cluster-admin privilage is required to run the next commands`
`cluster-admin privilege is required to run the next commands`

## Deploy the template & constraint yamls that define the policy

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Prevent Default Serviceaccount
# Prevent Default ServiceAccount

The policy disallows creating pods/service/deployment/deploymentconfig/replicaset (and every object that includes pod creation in any shape) that is not associated with a dedicated service account.

Expand All @@ -14,7 +14,7 @@ The required procedure to deploy the policy:
* Note that any openshift-* & kubernetes-* default namespaces are excluded
4. Deploy test pods & deployment object to make sure the policy works as expected

`You should be logged in as cluster-admin privilaged user`
`You should be logged in as cluster-admin privileged user`

## Deploy the template & constraint yamls that define the policy

Expand All @@ -40,7 +40,7 @@ oc apply -f ./test/not_approved_pod_1.yaml -n test
# No spec.serviceAccountName == "some-sa"
oc apply -f ./test/approved_pod.yaml -n test

# Examin violation
# Examine violation
oc describe k8spoduniqueserviceaccountvalidation.constraints.gatekeeper.sh/pod-unique-serviceaccount-validation -n openshift-gatekeeper-system

# Should work because of namespace excluding
Expand Down

0 comments on commit 473fbe9

Please sign in to comment.