在 M1 MacBook 上,ansible_architecture
and ansible_machine
返回相同的值arm64
:
shuuji3@momo mac-dev-playbook
> ansible -m setup localhost | egrep '_architecture|_machine'
"ansible_architecture": "arm64",
"ansible_machine": "arm64",
在 M1 Mac 上的 Rosetta 2 仿真下怎么样?
在 M1 Mac 上使用 Rosetta 2 仿真(Intel 模式)时,Ansible 返回x86_64
与之前的英特尔 Mac 类似的值:
shuuji3@momo ~ % ansible -m setup localhost | egrep '_architecture|_machine'
"ansible_architecture": "arm64",
"ansible_machine": "arm64",
# Run the shell on the Intel mode
shuuji3@momo ~ % env /usr/bin/arch -x86_64 /bin/zsh --login
shuuji3@momo ~ % ansible -m setup localhost | egrep '_architecture|_machine'
"ansible_architecture": "x86_64",
"ansible_machine": "x86_64",
"ansible_userspace_architecture": "x86_64",
请注意,Ansible 添加了ansible_userspace_architecture
fact.
参考
- 如何在 Apple Silicon 上运行旧版命令行应用程序 |围墙花园农民
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)