-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Linux] Support RHEL CoreOS automation testing (#477)
Signed-off-by: Qi Zhang <qiz@vmware.com>
- Loading branch information
1 parent
e03f031
commit 1c5ae22
Showing
35 changed files
with
404 additions
and
346 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
#!/bin/sh | ||
echo $0 $@ >> /vss.log | ||
echo $0 $@ >> {{ vss_log_path }} | ||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Copyright 2023 VMware, Inc. | ||
# SPDX-License-Identifier: BSD-2-Clause | ||
--- | ||
# Collect VM serial port log file | ||
# | ||
- name: "Collect VM serial port log" | ||
when: | ||
- vm_dir_name is defined | ||
- vm_dir_name | ||
- vm_serial_port_file_path is defined | ||
- vm_serial_port_file_path | ||
block: | ||
- name: "Set fact of VM serial port log file name" | ||
ansible.builtin.set_fact: | ||
vm_serial_port_file_name: "{{ vm_serial_port_file_path.split()[-1] | basename }}" | ||
|
||
- name: "Download VM serial port log file from datastore" | ||
include_tasks: ../../common/esxi_download_datastore_file.yml | ||
vars: | ||
src_datastore: "{{ datastore }}" | ||
src_file_path: "{{ vm_dir_name }}/{{ vm_serial_port_file_name }}" | ||
dest_file_path: "{{ current_test_log_folder }}/{{ vm_serial_port_file_name }}" | ||
download_file_fail_ignore: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,40 @@ | ||
# Copyright 2023 VMware, Inc. | ||
# SPDX-License-Identifier: BSD-2-Clause | ||
--- | ||
# Collect cloud-init logs for deploying Ubuntu live-server, | ||
# cloud image or Photon OVA. | ||
# Collect VM guest info and cloud-init logs for deploying Ubuntu live-server, | ||
# cloud image, VMware Photon OS OVA or Amazon Linux OVA. | ||
# | ||
- name: "Collect VM logs" | ||
- name: "Collect VM deployement logs" | ||
when: | ||
- vm_exists is defined | ||
- vm_exists | ||
block: | ||
- name: "Get VM's power state" | ||
include_tasks: ../../common/vm_get_power_state.yml | ||
|
||
- name: "Collect cloud-init logs" | ||
- name: "Collect VM's guest info and cloud-init logs" | ||
when: | ||
- vm_power_state_get is defined | ||
- vm_power_state_get == "poweredOn" | ||
block: | ||
- name: "Get VMware Tools status" | ||
include_tasks: ../../common/vm_get_vmtools_status.yml | ||
|
||
# VM's guest info will be collected by log plugin | ||
- name: "Get VM's guest info" | ||
include_tasks: ../../common/vm_get_guest_info.yml | ||
when: | ||
- unattend_install_conf is defined | ||
- unattend_install_conf | lower is not match('.*bclinux-for-euler.*') | ||
- vmtools_is_running | ||
|
||
- name: "Collect cloud-init logs" | ||
include_tasks: ../utils/collect_cloudinit_logs.yml | ||
when: | ||
- guestinfo_guest_id is defined | ||
- ((guestinfo_guest_id is match('ubuntu.*') and | ||
unattend_install_conf is defined and | ||
(unattend_install_conf is match('Ubuntu/Server/') or unattend_install_conf is match('Ubuntu/Desktop/Subiquity'))) or | ||
(unattend_install_conf is match('Ubuntu/Server/') or | ||
unattend_install_conf is match('Ubuntu/Desktop/Subiquity'))) or | ||
(ova_guest_os_type is defined and | ||
ova_guest_os_type in ['photon', 'ubuntu', 'amazon'])) | ||
when: | ||
- vm_power_state_get is defined | ||
- vm_power_state_get == "poweredOn" | ||
when: | ||
- vm_exists is defined | ||
- vm_exists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.