--- - name: Add user to developer group (allowed to create projects) command: "oc adm groups add-users {{item}} {{ocp_username}}" register: groupadd_register with_items: "{{ocp_user_groups}}" when: - ocp_username is defined - ocp_user_groups | default([]) | length > 0 - name: Test that the command worked debug: var: groupadd_register verbosity: 2 - name: Create user Quota - ClusterResourceQuota command: | oc create clusterresourcequota clusterquota-"{{ocp_username}}-{{guid}}" \ --project-annotation-selector=openshift.io/requester="{{ocp_username}}" \ --hard requests.cpu="{{quota_requests_cpu}}" \ --hard limits.cpu="{{quota_limits_cpu}}" \ --hard requests.memory="{{quota_requests_memory}}" \ --hard limits.memory="{{quota_limits_memory}}" \ --hard configmaps="{{quota_configmaps}}" \ --hard pods="{{quota_pods}}" \ --hard persistentvolumeclaims="{{quota_persistentvolumeclaims}}" \ --hard services="{{quota_services}}" \ --hard secrets="{{quota_secrets}}" \ --hard requests.storage="{{quota_requests_storage}}" ignore_errors: true - name: Allow user view access to gpte-jenkins project command: | oc policy add-role-to-user view {{ocp_username}} -n {{gpte_jenkins_project}} ignore_errors: true - name: pre_workload Tasks Complete debug: msg: "Pre-Software checks completed successfully"