ctorgalson.macos_hostname
Ansible Role macOS Hostname
A simple Ansible role to set HostName, LocalHostName, and ComputerName on macOS.
Requirements
No special requirements.
Role Variables
| Variable name | Default value | Description |
|---|---|---|
mh_hostname |
'' |
The HostName to set. |
mh_localhostname |
MhLocalHostName |
The LocalHostName to set. |
mh_computername |
MhComputerName |
The ComputerName to set. |
- The properties
HostName,LocalHostName, andComputerNamereferred to in the table are keywords used with thescutilcommand on macOS. - Setting a value for
HostNamemay have unpredictable or confusing results. See the answers to this Stack Overflow question for more information.
Example Playbook
- hosts: servers
roles:
- role: ansible-role-macos-hostname
License
GPLv3
Author Information
Christopher Torgalson
About
A role to set HostName, LocalHostName, and ComputerName on macOS.
Install
ansible-galaxy install ctorgalson.macos_hostnameLicense
gpl-3.0
Downloads
21k
Owner
