chef / ohai

Ohai profiles your system and emits JSON
https://docs.chef.io/ohai.html
Apache License 2.0
681 stars 452 forks source link

determine if we are an Apple Virtualization Framework guest #1814

Closed jazaval closed 10 months ago

jazaval commented 10 months ago

Determine if we are an Apple Virtualization Framework guest based on machine_model data.

Description

Apple provides a virtualization framework that supports arm64 and x86_64 guests depending on the host hardware. The virtual? method does not work if we are outside the Vagrant paradigm, so this change looks for the specific substring Apple sets in machine_model when creating guest hardware.

Types of changes

Checklist:

sonarcloud[bot] commented 10 months ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication