From 67b40fbc616069d489624cfe5eface8ecea51148 Mon Sep 17 00:00:00 2001 From: nono <np@laquadrature.net> Date: Mon, 22 Feb 2021 11:52:51 +0100 Subject: [PATCH] Update README, Added first task ( users & group ) --- README.md | 21 +++++++++++++-------- tasks/install-users.yml | 15 +++++++++++++++ 2 files changed, 28 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 69c9856..4629763 100644 --- a/README.md +++ b/README.md @@ -3,29 +3,34 @@ SSO-LQDN Rôle permettant d'installer un serveur de SSO basé sur Keycloack +Ce rôle se charge d'installer keycloack. À terme, il se chargera aussi de faire la mise à jour. + +Il ne se charge pas d'ajouter des utilisateurices, ni de configurer les intégrations avec les services tiers. + Requirements ------------ -Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required. +Tout est inclus dans ce rôle. Il est fortement inspiré par les rôles suivants : + +- https://github.com/em0lar/ansible-role-keycloak-postgres + Role Variables -------------- -A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well. +TODO Dependencies ------------ -A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles. +Tout est inclus dans ce rôle. Example Playbook ---------------- -Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too: - - - hosts: servers + - hosts: lqdn-sso roles: - - { role: username.rolename, x: 42 } + - sso-lqdn License ------- @@ -35,4 +40,4 @@ BSD Author Information ------------------ -An optional section for the role authors to include contact information, or a website (HTML is not allowed). +Fait chez LQDN ( LQDN.fr ) par nono ( np@laquadrature.net ) diff --git a/tasks/install-users.yml b/tasks/install-users.yml index ed97d53..6cab046 100644 --- a/tasks/install-users.yml +++ b/tasks/install-users.yml @@ -1 +1,16 @@ --- + +- name : Creation of the Keycloak group + group : + name : "{{ keycloak_service_group }}" + system: true + become : true + +- name: Creation of the Keycloak user + user: + name: "{{ keycloak_service_user }}" + group: "{{ keycloak_service_group }}" + home: "{{ keycloak_base_path }}" + create_home: true + system: true + become: true -- GitLab