mirror of
				https://github.com/kevinveenbirkenbach/computer-playbook.git
				synced 2025-11-04 04:08:15 +00:00 
			
		
		
		
	
		
			
				
	
	
	
		
			673 B
		
	
	
	
	
	
	
	
			
		
		
	
	
			673 B
		
	
	
	
	
	
	
	
Hostname
This Ansible role ensures that the target host’s system hostname is set to the inventory hostname.
Description
- Uses the built-in 
hostnamemodule to apply theinventory_hostnamevalue - Idempotent: only changes the system name if it differs
 - No external dependencies
 
Overview
- Task
set hostname to {{ inventory_hostname }}
Applies the desired hostname.
 - Module
- Leverages Ansible’s 
hostnamemodule. 
 - Leverages Ansible’s 
 
Features
- Simple and lightweight
 - Automatically adapts to your inventory names
 - Safe to run repeatedly