From 8f7ae07b7922f71da114425daebdda22000e799e Mon Sep 17 00:00:00 2001 From: Radar231 Date: Thu, 22 Jul 2021 23:14:54 -0400 Subject: [PATCH] initial checkin --- README.md | 13 +++++++++++++ tasks/main.yml | 22 ++++++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 README.md create mode 100644 tasks/main.yml diff --git a/README.md b/README.md new file mode 100644 index 0000000..e0e7df4 --- /dev/null +++ b/README.md @@ -0,0 +1,13 @@ +# Ansible Role: create_user + +## Introduction + +This role will set up a new user account + +NOTE: + +The following variables must be specified in the playbook. + +* {{ username }} +* {{ userpw }} + diff --git a/tasks/main.yml b/tasks/main.yml new file mode 100644 index 0000000..b0320bc --- /dev/null +++ b/tasks/main.yml @@ -0,0 +1,22 @@ +--- +########################################################################### +# +# This role will set up a new user account +# +########################################################################### +# +# NOTE: +# the following variables must be specified in the playbook +# {{ username }} +# {{ userpw }} +# +########################################################################### +# tasks file for create_user + +- name: Create a new user named "{{ username }}" + user: + name: "{{ username }}" + password: "{{ userpw | password_hash('sha512', 'SmrFgsR8') }}" + shell: /bin/bash + +# EOF