@@ -32,24 +32,52 @@ The `docker` daemon must be correctly installed and running on the system.
32
32
[[apb-devel-cli-install-prereqs-access-permissions]]
33
33
==== Access Permissions
34
34
35
- You must be logged in via `oc` as a user with *cluster-admin* permissions:
35
+ The `apb` tool requires you to be logged in as a tokened cluster user; the
36
+ default *system:admin* system user is not sufficient because it does not have a
37
+ token that can be used for the tool's authentication. In addition, there are a
38
+ number of local roles (project-scoped) and cluster roles (cluster-wide) that
39
+ must exist to permit the full breadth of the `apb` tool's functions (see
40
+ xref:../architecture/additional_concepts/authorization.adoc#cluster-and-local-rbac[Cluster and Local RBAC]).
41
+
42
+ The easiest option is to ensure the user has the *cluster-admin* cluster role.
43
+ To add this role to another user, you can run the following as a user that
44
+ already has such permissions (for example, the *system:admin* default system
45
+ user):
46
+
47
+ [WARNING]
48
+ ====
49
+ This is effectively cluster *root* and should only be used in a development
50
+ setting.
51
+ ====
36
52
37
53
----
54
+ $ oc adm policy add-cluster-role-to-user cluster-admin <user>
38
55
$ oc login -u <user> <openshift_server>
39
56
----
40
57
41
- To add this role to another user, you can run the following as a user that
42
- already has such permissions (for example, the *system:admin* default system
43
- user):
58
+ If you would like a more strictly permissioned environment, an OpenShift
59
+ template is provided that by default will permission a user called *developer*.
60
+ The template must be run by a user with sufficient permissions to create the
61
+ various roles. The *developer* user does not have such permissions, but the
62
+ *system:admin* user is sufficient.
63
+
64
+ To run the template:
44
65
66
+ . Download the
67
+ link:https://raw.githubusercontent.com/ansibleplaybookbundle/ansible-playbook-bundle/master/templates/openshift-permissions.template.yaml[*_openshift-permissions.template.yaml_*]
68
+ file locally.
69
+
70
+ . Run the following command:
71
+ +
45
72
----
46
- $ oc adm policy \
47
- add-cluster-role-to-user \
48
- cluster-admin <user>
73
+ $ oc process -f openshift-permissions.template.yaml \
74
+ -p BROKER_NAMESPACE=openshift-ansible-service-broker \
75
+ [-p USER=<your_desired_user>] \//<1>
76
+ | oc create -f -
49
77
----
50
-
51
- This permission requirement is so that the development lifecycle of the `apb`
52
- tool can function .
78
+ <1> By default, the template will permission the *developer* user. You can
79
+ optionally use the `-p` flag to override this default value with your desired
80
+ user .
53
81
54
82
ifdef::openshift-origin[]
55
83
[[apb-devel-cli-install-containerized]]
0 commit comments