From 753dc0b756b9963404a17640a625fd826513bee5 Mon Sep 17 00:00:00 2001
From: Emil Renner Berthing <esmil@labitat.dk>
Date: Thu, 6 Dec 2018 21:36:52 +0100
Subject: space_server: networkd: fix unneeded calculation

---
 roles/space_server/tasks/networkd.yml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/roles/space_server/tasks/networkd.yml b/roles/space_server/tasks/networkd.yml
index deada30..85cc1e2 100644
--- a/roles/space_server/tasks/networkd.yml
+++ b/roles/space_server/tasks/networkd.yml
@@ -24,8 +24,8 @@
 
 - name: Delete unneeded network configuration
   file:
-    path: '{{ item }}'
+    path: '/etc/systemd/network/{{ item }}'
     state: absent
-  with_items: "{{ networkd_existing.files|map(attribute='path')|difference(networkd_created.results|map(attribute='dest'))|list }}"
+  with_items: "{{ networkd_existing.files|map(attribute='path')|map('basename')|difference(networkd_created.results|map(attribute='item')|map('basename'))|list }}"
 
 # vim: set ts=2 sw=2 et:
-- 
cgit v1.2.1