A dev environment for the mirror.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
mirror-env/mirror/main.yml

33 lines
797 B

- name: setup mirror vm
hosts: 127.0.0.1
gather_facts: no
tasks:
- name: get hostname
command: "hostname"
changed_when: false
ignore_errors: true
register: hostname
- name: fail when hostname is not mirror
fail:
msg: DO NOT run this on your host machine!
when: hostname.stdout != "mirror"
- name: run the system role first
include_role:
name: "../roles/system"
- name: run mirror system role second
include_role:
name: "../roles/mirror"
- name: run the rest of the roles
include_role:
name: "{{ roleinputvar }}"
loop:
- "../roles/ftp"
- "../roles/nginx"
- "../roles/rsync"
- "../roles/ssh"
loop_control:
loop_var: roleinputvar