homelab/ansible/playbooks/server.yml

29 lines
704 B
YAML
Raw Normal View History

---
2022-11-29 20:23:44 +00:00
- hosts:
- homelab
- VPS
vars:
# certbot_force: true
tasks:
- name: create user
include_role:
name: "ansible-user"
apply:
become: true
vars:
user_name: "{{ create.name }}"
user_home: "{{ create.home }}"
user_groups: "{{ create.groups|default('') }}"
user_shell: "{{ create.shell|default('') }}"
user_authorized_key: "{{ create.authorized_keys|default([]) }}"
user_privatekey: "{{ create.privatekey|default([])}}"
loop: "{{system_user}}"
loop_control:
loop_var: create
roles:
- system
- autofs
2022-10-23 15:31:08 +00:00
- role: msmtp
when: ansible_os_family != "RedHat"
- cronie