Permalink
Fetching contributors…
Cannot retrieve contributors at this time
43 lines (35 sloc) 1.07 KB
---
- meta: flush_handlers
- name: Inspect the VM before final image preparation begins
pause:
when: image_debug is defined and image_debug
- name: Register OS information (CentOS)
shell: cat /etc/redhat-release
register: os_info_centos
when: ansible_distribution == "CentOS"
- name: Register OS information (SmartOS)
shell: cat /etc/pkgsrc_version
register: os_info_smartos
when: ansible_distribution == "SmartOS"
- name: Prepare virtual machine for snapshotting (CentOS)
shell: |
rm -f /root/.ssh/authorized_keys
prepare-image
when: ansible_distribution == "CentOS"
- name: Prepare virtual machine for snapshotting (SmartOS)
shell: |
rm -f /root/.ssh/authorized_keys
export yn_start="y"
export yn_nfs="y"
export yn_subips="y"
export yn_halt="n"
sm-prepare-image
when: ansible_distribution == "SmartOS"
- name: Display OS information (CentOS)
debug:
var: os_info_centos
when: ansible_distribution == "CentOS"
- name: Display OS information (SmartOS)
debug:
var: os_info_smartos
when: ansible_distribution == "SmartOS"