diff --git a/radius-client/templates/wpa_supplicant.j2 b/radius-client/templates/wpa_supplicant.j2
index ffc4de996b25ef542e5f9432391b1b0dc7f9ad5e..130c35222644a9a4a7077eb965b367a57aab1796 100644
--- a/radius-client/templates/wpa_supplicant.j2
+++ b/radius-client/templates/wpa_supplicant.j2
@@ -9,7 +9,7 @@ ap_scan=0
 network={
 	key_mgmt=IEEE8021X
 	eap=TLS
-	identity="{{ inventory_hostname }}@ssl.asta.rwth-aachen.de"
+	identity="{{ ansible_hostname }}@ssl.asta.rwth-aachen.de"
 	ca_cert="/etc/ssl/certs/asta_ca.pem"
 	client_cert="/etc/wpa_supplicant/{{ inventory_hostname }}.pem"
 	private_key="/etc/wpa_supplicant/{{ inventory_hostname }}.key"