Automatic module role assignments in customer tenants
MACMA module features are shared from the main tenant to customer tenants via contracts.
However, role assignments in the customer contracts is not done automatically by MACMA based on the roles required for one module to function.
To simplify this process an Ansible playbook which goes through all customer contracts and assigns module roles based on existing contracts and needed roles automatically is available.
The playbook is delivered in the ansible operator image and, for easiness, it is packed in a cronjon which never executes but it can be used as a job template to create an adhoc job.
The following commands can be used to create the job and watch execution logs:
export ANSIBLE_OPERATOR_NAMESPACE=<ansible-operator-namespace>
CRONJOB=`kubectl -n $ANSIBLE_OPERATOR_NAMESPACE get cj -l app=macma-configuration-job -o name`
kubectl -n $ANSIBLE_OPERATOR_NAMESPACE create job macma-configuration-job --from=$CRONJOB
kubectl -n $ANSIBLE_OPERATOR_NAMESPACE logs -f -l batch.kubernetes.io/job-name=macma-configuration-job