-
Notifications
You must be signed in to change notification settings - Fork 0
/
post_install.yml
39 lines (33 loc) · 999 Bytes
/
post_install.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
---
- hosts: localhost
connection: local
tasks:
- name: "check if 'roles/post_install/defaults/main.yml' exists"
stat:
path: "{{ playbook_dir }}/roles/post_install/defaults/main.yml"
register: stat_response
- fail:
msg: "YOU MUST TO DECRYPT '{{ playbook_dir }}/roles/post_install/defaults/main.yml.gpg"
when: not stat_response.stat.exists
tags:
- always
- name: "[CHECK OP] check if OP_SESSION_* is defined"
import_playbook: playbooks/check_op.yml
tags:
- always
- name: "[LOAD VARS] setting ansible variables"
import_playbook: playbooks/load_distro_vars.yml
tags:
- always
####################
# POST INSTALACION #
####################
- hosts: localhost
connection: local
become: false
vars:
disable_updates: "{{ lookup('env', 'REPO_DISABLE_UPDATES') | default(false) | bool }}"
ansible_user: "{{ lookup('env', 'USER') }}"
ansible_user_dir: "/home/{{ lookup('env', 'USER') }}"
roles:
- post_install