Giter VIP home page Giter VIP logo

ansible.users's Introduction

Ansible Role: users

Important Update

Please note that the ansible.users role has been moved to a new collection and will no longer be actively developed in this repository. For the latest version of the role, including new features and updates, please visit the new collection at https://github.com/arillso/ansible.system/tree/main/roles/users. We encourage all users to switch to the updated role in the new collection for ongoing support and improvements.

Description

This is an Ansible role which users and user's authorized keys manages on Linux and Windows.

Installation

ansible-galaxy install arillso.users

Requirements

None

Role Variables

Users

list of users to add

users: []
 list of users to add by host vars
users_list_host: []

list of users to add by group vars

users_list_group: []

Example

 users:
   - username: foobar              (required)
     name: Foo Bar
     uid: 1000
     group: staff
     password: xxxxx               (a hash created with: mkpasswd)
     groups: ["adm", "www-data"]
     append: no                    (only append groups, leave others)
     home_mode: "0750"
     home_create: yes
     home: /path/to/user/home
     system: no
     authorized_keys: []
     authorized_keys_exclusive: yes
     ssh_key_type: rsa
     ssh_key_bits: 2048
     ssh_key_password: ""
     ssh_key_generate: no
     ssh_key: "xxx"
     shell: /bin/bash
     update_password: always
users:
  - username: foobar              (required)
    name: Foo Bar
    description: User
    password: xxxxx
    groups: ['adm', 'www-data']
    hide: true

users home directory

users_home: /home

default user's primary group for users

users_group:

default user's secondary groups

users_groups: []

default user's home directory permissions

users_home_mode: '0755'

default user's ssh key type

users_ssh_key_type: rsa

default user's ssh key bits

users_ssh_key_bits: 2048

default user's setting for authorized keys exclusive

users_authorized_keys_exclusive: 'no'

Dependencies

None

Example Playbook

- hosts: all
  roles:
    - arillso.users

Author

Inspiration

License

This project is under the MIT License. See the LICENSE file for the full license text.

Copyright

(c) 2020, Arillso

ansible.users's People

Contributors

freeminded avatar sbaerlocher avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

ansible.users's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.