{"action":"created","comment":{"url":"https://api.github.com/repos/openshift/openshift-docs/pulls/comments/64847685","id":64847685,"diff_hunk":"@@ -0,0 +1,542 @@\n+= User and Role Management\n+{product-author}\n+{product-version}\n+:data-uri:\n+:icons:\n+:experimental:\n+:toc: macro\n+:toc-title:\n+\n+toc::[]\n+\n+== Overview\n+As an OpenShift cluster administrator, you can manage users and roles, as well\n+as the projects, templates, and available resources they manage themselves. For\n+now, this topic focuses on common operations a cluster administrator needs to\n+perform. You can:\n+\n+* link:../admin_solutions/user_role_mgmt.html#setting-limits-users-projects[Place quotas and limits on projects],\n+enabling you to control pod and container limits, object counts, and compute\n+resources.\n+* link:../admin_solutions/user_role_mgmt.html#limit-number-projects[Limit the number of projects a user can have]\n+* link:../admin_solutions/user_role_mgmt.html#control-monitor-resources[Monitor resource usage],\n+enabling you to check the amount of used resources, such as CPU usage.\n+* link:../admin_solutions/user_role_mgmt.html#determine-default-user-roles[Determine which roles users get by default]\n+* link:../admin_solutions/user_role_mgmt.html#control-user-roles[Apply roles to users and service accounts],\n+enabling you to control what they are able to do in OpenShift projects and in\n+the cluster.\n+* link:../admin_solutions/user_role_mgmt.html#share-templates-cluster[Share templates with all projects in the cluster]\n+* link:../admin_solutions/user_role_mgmt.html#create-cluster-admin[Create other cluster administrators]\n+\n+== Limiting and Monitoring Users and Projects\n+\n+[[setting-limits-users-projects]]\n+=== Setting Limits for Users and Projects\n+\n+*How can I create limits for users and projects?*\n+\n+You can place limits within your OpenShift cluster using link:../admin_guide/quota.html[ResourceQuotas]\n+and\n+link:../admin_guide/limits.html[LimitRanges],\n+These quotas and limits allow you to control pod and container limits, object\n+counts, and compute resources. Currently, these limits and quotas only apply to\n+projects and not to users. However, you can make a quota-like\n+link:../admin_solutions/user_role_mgmt.html#limit-number-projects[limit on how many project requests a user can make].\n+\n+*Use Case: I want to create a quota in my \"awesomeproject\", so that there is a maximum of only 10 pods that can be created in the project.*\n+\n+. Create a *_resource-quota.yaml_* file with the following contents:\n++\n+----\n+apiVersion: v1\n+kind: ResourceQuota\n+metadata:\n+  name: compute-resources\n+spec:\n+  hard:\n+    pods: \"10\"\n+----\n++\n+. Create the quota using the file you just wrote to apply it to the \"awesomeproject\":\n++\n+----\n+$ oc create -f resource-quota.yaml -n awesomeproject\n+----\n++\n+. After the quota has been in effect for a little while, you can view the usage statistics for the hard limit set on pods. If required, list the quotas defined in the project to see the names of all defined quotas:\n++\n+====\n+----\n+$ oc get quota -n awesomeproject\n+NAME                AGE\n+resource-quota      39m\n+----\n+====\n++\n+. Describe the resource quota for which you want statistics:\n++\n+====\n+----\n+$ oc describe quota resource-quota -n awesomeproject\n+Name:\t\t\tresource-quota\n+Namespace:\t\tawesomeproject\n+Resource\t\tUsed\tHard\n+--------\t\t----\t----\n+pods     \t\t3\t10\n+----\n+====\n++\n+. Optionally, you can\n+link:../admin_guide/quota.html#configuring-quota-sync-period[configure the quota synchronization period], which controls how long to wait before restoring quota usage after resources are deleted.\n+. If you want to remove an active quota to no longer enforce the limits of a project:\n++\n+----\n+$ oc delete quota <quota_name>\n+----\n+\n+*Now let's walk through that process and examine all the available options:*\n+\n+. To create project limits or quotas, you must first write a .yaml file that describes the resource that you want to restrict:\n+\n+* This *_LimitRange.yaml_* example explains all the\n+link:../admin_guide/limits.html#container-limits[container limits] and\n+link:../admin_guide/limits.html#pod-limits[pod limits] that you can place within\n+your project:\n++\n+include::admin_guide/limits.adoc[tag=admin_limits_sample_definition]\n++\n+* These *_ResourceQuota.yaml_* examples explain all the\n+link:../admin_guide/quota.html#sample-resource-quota-definitions[Object Counts]\n+and\n+link:../admin_guide/quota.html#sample-resource-quota-definitions[Compute Resources] that you can place within your project:\n++\n+include::admin_guide/quota.adoc[tag=admin_quota_object_counts]\n++\n+include::admin_guide/quota.adoc[tag=admin_quota_compute_resources]","path":"admin_solutions/user_role_mgmt.adoc","position":115,"original_position":115,"commit_id":"9bf309d5d2e764b6383a947c5a220c912cf8e3e7","original_commit_id":"9bf309d5d2e764b6383a947c5a220c912cf8e3e7","user":{"login":"tpoitras","id":8109928,"avatar_url":"https://avatars.githubusercontent.com/u/8109928?v=3","gravatar_id":"","url":"https://api.github.com/users/tpoitras","html_url":"https://github.com/tpoitras","followers_url":"https://api.github.com/users/tpoitras/followers","following_url":"https://api.github.com/users/tpoitras/following{/other_user}","gists_url":"https://api.github.com/users/tpoitras/gists{/gist_id}","starred_url":"https://api.github.com/users/tpoitras/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpoitras/subscriptions","organizations_url":"https://api.github.com/users/tpoitras/orgs","repos_url":"https://api.github.com/users/tpoitras/repos","events_url":"https://api.github.com/users/tpoitras/events{/privacy}","received_events_url":"https://api.github.com/users/tpoitras/received_events","type":"User","site_admin":false},"body":"@bfallonf  I'm just going to pull the .yaml off the \"these ______.yaml examples\" parts. The wasn't really intended to be the exact file name. More like \"these ResourceQuota YAML examples\" or something. The file name is clearly identified within the object definition itself.","created_at":"2016-05-27T01:49:22Z","updated_at":"2016-05-27T01:49:23Z","html_url":"https://github.com/openshift/openshift-docs/pull/2030#discussion_r64847685","pull_request_url":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030","_links":{"self":{"href":"https://api.github.com/repos/openshift/openshift-docs/pulls/comments/64847685"},"html":{"href":"https://github.com/openshift/openshift-docs/pull/2030#discussion_r64847685"},"pull_request":{"href":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030"}}},"pull_request":{"url":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030","id":69323997,"html_url":"https://github.com/openshift/openshift-docs/pull/2030","diff_url":"https://github.com/openshift/openshift-docs/pull/2030.diff","patch_url":"https://github.com/openshift/openshift-docs/pull/2030.patch","issue_url":"https://api.github.com/repos/openshift/openshift-docs/issues/2030","number":2030,"state":"open","locked":false,"title":"Admin Solutions guide","user":{"login":"tpoitras","id":8109928,"avatar_url":"https://avatars.githubusercontent.com/u/8109928?v=3","gravatar_id":"","url":"https://api.github.com/users/tpoitras","html_url":"https://github.com/tpoitras","followers_url":"https://api.github.com/users/tpoitras/followers","following_url":"https://api.github.com/users/tpoitras/following{/other_user}","gists_url":"https://api.github.com/users/tpoitras/gists{/gist_id}","starred_url":"https://api.github.com/users/tpoitras/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpoitras/subscriptions","organizations_url":"https://api.github.com/users/tpoitras/orgs","repos_url":"https://api.github.com/users/tpoitras/repos","events_url":"https://api.github.com/users/tpoitras/events{/privacy}","received_events_url":"https://api.github.com/users/tpoitras/received_events","type":"User","site_admin":false},"body":"(2nd attempt at a PR, mistakenly pushed the first one to upstream instead of my fork)\r\n\r\nRE: Bug 1254844: https://bugzilla.redhat.com/show_bug.cgi?id=1254844\r\n\r\nJust doing some last-minute tweaking on the Master & Node config chapter, incorporating details from SME and notes from the code.\r\n\r\nThe other 2 chapters are done.","created_at":"2016-05-09T10:22:59Z","updated_at":"2016-05-27T01:49:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e3ab0fafbc96f62c53b4f1da1a602fbd8076d73c","assignee":null,"milestone":{"url":"https://api.github.com/repos/openshift/openshift-docs/milestones/30","html_url":"https://github.com/openshift/openshift-docs/milestones/OSE%203.2","labels_url":"https://api.github.com/repos/openshift/openshift-docs/milestones/30/labels","id":1724008,"number":30,"title":"OSE 3.2","description":"","creator":{"login":"adellape","id":3442316,"avatar_url":"https://avatars.githubusercontent.com/u/3442316?v=3","gravatar_id":"","url":"https://api.github.com/users/adellape","html_url":"https://github.com/adellape","followers_url":"https://api.github.com/users/adellape/followers","following_url":"https://api.github.com/users/adellape/following{/other_user}","gists_url":"https://api.github.com/users/adellape/gists{/gist_id}","starred_url":"https://api.github.com/users/adellape/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adellape/subscriptions","organizations_url":"https://api.github.com/users/adellape/orgs","repos_url":"https://api.github.com/users/adellape/repos","events_url":"https://api.github.com/users/adellape/events{/privacy}","received_events_url":"https://api.github.com/users/adellape/received_events","type":"User","site_admin":false},"open_issues":2,"closed_issues":0,"state":"open","created_at":"2016-04-21T22:14:58Z","updated_at":"2016-05-16T16:06:40Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030/commits","review_comments_url":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030/comments","review_comment_url":"https://api.github.com/repos/openshift/openshift-docs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openshift/openshift-docs/issues/2030/comments","statuses_url":"https://api.github.com/repos/openshift/openshift-docs/statuses/9bf309d5d2e764b6383a947c5a220c912cf8e3e7","head":{"label":"tpoitras:adminsolutions","ref":"adminsolutions","sha":"9bf309d5d2e764b6383a947c5a220c912cf8e3e7","user":{"login":"tpoitras","id":8109928,"avatar_url":"https://avatars.githubusercontent.com/u/8109928?v=3","gravatar_id":"","url":"https://api.github.com/users/tpoitras","html_url":"https://github.com/tpoitras","followers_url":"https://api.github.com/users/tpoitras/followers","following_url":"https://api.github.com/users/tpoitras/following{/other_user}","gists_url":"https://api.github.com/users/tpoitras/gists{/gist_id}","starred_url":"https://api.github.com/users/tpoitras/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpoitras/subscriptions","organizations_url":"https://api.github.com/users/tpoitras/orgs","repos_url":"https://api.github.com/users/tpoitras/repos","events_url":"https://api.github.com/users/tpoitras/events{/privacy}","received_events_url":"https://api.github.com/users/tpoitras/received_events","type":"User","site_admin":false},"repo":{"id":29233055,"name":"openshift-docs","full_name":"tpoitras/openshift-docs","owner":{"login":"tpoitras","id":8109928,"avatar_url":"https://avatars.githubusercontent.com/u/8109928?v=3","gravatar_id":"","url":"https://api.github.com/users/tpoitras","html_url":"https://github.com/tpoitras","followers_url":"https://api.github.com/users/tpoitras/followers","following_url":"https://api.github.com/users/tpoitras/following{/other_user}","gists_url":"https://api.github.com/users/tpoitras/gists{/gist_id}","starred_url":"https://api.github.com/users/tpoitras/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpoitras/subscriptions","organizations_url":"https://api.github.com/users/tpoitras/orgs","repos_url":"https://api.github.com/users/tpoitras/repos","events_url":"https://api.github.com/users/tpoitras/events{/privacy}","received_events_url":"https://api.github.com/users/tpoitras/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tpoitras/openshift-docs","description":"OpenShift Documentation","fork":true,"url":"https://api.github.com/repos/tpoitras/openshift-docs","forks_url":"https://api.github.com/repos/tpoitras/openshift-docs/forks","keys_url":"https://api.github.com/repos/tpoitras/openshift-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tpoitras/openshift-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tpoitras/openshift-docs/teams","hooks_url":"https://api.github.com/repos/tpoitras/openshift-docs/hooks","issue_events_url":"https://api.github.com/repos/tpoitras/openshift-docs/issues/events{/number}","events_url":"https://api.github.com/repos/tpoitras/openshift-docs/events","assignees_url":"https://api.github.com/repos/tpoitras/openshift-docs/assignees{/user}","branches_url":"https://api.github.com/repos/tpoitras/openshift-docs/branches{/branch}","tags_url":"https://api.github.com/repos/tpoitras/openshift-docs/tags","blobs_url":"https://api.github.com/repos/tpoitras/openshift-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tpoitras/openshift-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tpoitras/openshift-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/tpoitras/openshift-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tpoitras/openshift-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/tpoitras/openshift-docs/languages","stargazers_url":"https://api.github.com/repos/tpoitras/openshift-docs/stargazers","contributors_url":"https://api.github.com/repos/tpoitras/openshift-docs/contributors","subscribers_url":"https://api.github.com/repos/tpoitras/openshift-docs/subscribers","subscription_url":"https://api.github.com/repos/tpoitras/openshift-docs/subscription","commits_url":"https://api.github.com/repos/tpoitras/openshift-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/tpoitras/openshift-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/tpoitras/openshift-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/tpoitras/openshift-docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/tpoitras/openshift-docs/contents/{+path}","compare_url":"https://api.github.com/repos/tpoitras/openshift-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tpoitras/openshift-docs/merges","archive_url":"https://api.github.com/repos/tpoitras/openshift-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tpoitras/openshift-docs/downloads","issues_url":"https://api.github.com/repos/tpoitras/openshift-docs/issues{/number}","pulls_url":"https://api.github.com/repos/tpoitras/openshift-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/tpoitras/openshift-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/tpoitras/openshift-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tpoitras/openshift-docs/labels{/name}","releases_url":"https://api.github.com/repos/tpoitras/openshift-docs/releases{/id}","deployments_url":"https://api.github.com/repos/tpoitras/openshift-docs/deployments","created_at":"2015-01-14T07:40:46Z","updated_at":"2016-01-11T03:37:15Z","pushed_at":"2016-05-26T01:26:10Z","git_url":"git://github.com/tpoitras/openshift-docs.git","ssh_url":"git@github.com:tpoitras/openshift-docs.git","clone_url":"https://github.com/tpoitras/openshift-docs.git","svn_url":"https://github.com/tpoitras/openshift-docs","homepage":null,"size":12249,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"openshift:master","ref":"master","sha":"53b1a1f35eb9deded085df310feba2e02c64590c","user":{"login":"openshift","id":792337,"avatar_url":"https://avatars.githubusercontent.com/u/792337?v=3","gravatar_id":"","url":"https://api.github.com/users/openshift","html_url":"https://github.com/openshift","followers_url":"https://api.github.com/users/openshift/followers","following_url":"https://api.github.com/users/openshift/following{/other_user}","gists_url":"https://api.github.com/users/openshift/gists{/gist_id}","starred_url":"https://api.github.com/users/openshift/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openshift/subscriptions","organizations_url":"https://api.github.com/users/openshift/orgs","repos_url":"https://api.github.com/users/openshift/repos","events_url":"https://api.github.com/users/openshift/events{/privacy}","received_events_url":"https://api.github.com/users/openshift/received_events","type":"Organization","site_admin":false},"repo":{"id":21740844,"name":"openshift-docs","full_name":"openshift/openshift-docs","owner":{"login":"openshift","id":792337,"avatar_url":"https://avatars.githubusercontent.com/u/792337?v=3","gravatar_id":"","url":"https://api.github.com/users/openshift","html_url":"https://github.com/openshift","followers_url":"https://api.github.com/users/openshift/followers","following_url":"https://api.github.com/users/openshift/following{/other_user}","gists_url":"https://api.github.com/users/openshift/gists{/gist_id}","starred_url":"https://api.github.com/users/openshift/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openshift/subscriptions","organizations_url":"https://api.github.com/users/openshift/orgs","repos_url":"https://api.github.com/users/openshift/repos","events_url":"https://api.github.com/users/openshift/events{/privacy}","received_events_url":"https://api.github.com/users/openshift/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openshift/openshift-docs","description":"OpenShift Documentation","fork":false,"url":"https://api.github.com/repos/openshift/openshift-docs","forks_url":"https://api.github.com/repos/openshift/openshift-docs/forks","keys_url":"https://api.github.com/repos/openshift/openshift-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openshift/openshift-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openshift/openshift-docs/teams","hooks_url":"https://api.github.com/repos/openshift/openshift-docs/hooks","issue_events_url":"https://api.github.com/repos/openshift/openshift-docs/issues/events{/number}","events_url":"https://api.github.com/repos/openshift/openshift-docs/events","assignees_url":"https://api.github.com/repos/openshift/openshift-docs/assignees{/user}","branches_url":"https://api.github.com/repos/openshift/openshift-docs/branches{/branch}","tags_url":"https://api.github.com/repos/openshift/openshift-docs/tags","blobs_url":"https://api.github.com/repos/openshift/openshift-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openshift/openshift-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openshift/openshift-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/openshift/openshift-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openshift/openshift-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/openshift/openshift-docs/languages","stargazers_url":"https://api.github.com/repos/openshift/openshift-docs/stargazers","contributors_url":"https://api.github.com/repos/openshift/openshift-docs/contributors","subscribers_url":"https://api.github.com/repos/openshift/openshift-docs/subscribers","subscription_url":"https://api.github.com/repos/openshift/openshift-docs/subscription","commits_url":"https://api.github.com/repos/openshift/openshift-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/openshift/openshift-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/openshift/openshift-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/openshift/openshift-docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/openshift/openshift-docs/contents/{+path}","compare_url":"https://api.github.com/repos/openshift/openshift-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openshift/openshift-docs/merges","archive_url":"https://api.github.com/repos/openshift/openshift-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openshift/openshift-docs/downloads","issues_url":"https://api.github.com/repos/openshift/openshift-docs/issues{/number}","pulls_url":"https://api.github.com/repos/openshift/openshift-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/openshift/openshift-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/openshift/openshift-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openshift/openshift-docs/labels{/name}","releases_url":"https://api.github.com/repos/openshift/openshift-docs/releases{/id}","deployments_url":"https://api.github.com/repos/openshift/openshift-docs/deployments","created_at":"2014-07-11T15:14:42Z","updated_at":"2016-05-18T14:49:12Z","pushed_at":"2016-05-27T00:45:21Z","git_url":"git://github.com/openshift/openshift-docs.git","ssh_url":"git@github.com:openshift/openshift-docs.git","clone_url":"https://github.com/openshift/openshift-docs.git","svn_url":"https://github.com/openshift/openshift-docs","homepage":"https://docs.openshift.org/latest/welcome/index.html","size":16686,"stargazers_count":45,"watchers_count":45,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":211,"mirror_url":null,"open_issues_count":186,"forks":211,"open_issues":186,"watchers":45,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030"},"html":{"href":"https://github.com/openshift/openshift-docs/pull/2030"},"issue":{"href":"https://api.github.com/repos/openshift/openshift-docs/issues/2030"},"comments":{"href":"https://api.github.com/repos/openshift/openshift-docs/issues/2030/comments"},"review_comments":{"href":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030/comments"},"review_comment":{"href":"https://api.github.com/repos/openshift/openshift-docs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openshift/openshift-docs/pulls/2030/commits"},"statuses":{"href":"https://api.github.com/repos/openshift/openshift-docs/statuses/9bf309d5d2e764b6383a947c5a220c912cf8e3e7"}}}}
{"actor":{"display_login":"tpoitras"}}