From 42d14389b023611f8b624b5a82347a9cc39c5cb7 Mon Sep 17 00:00:00 2001 From: Olivier Bourdon Date: Tue, 29 May 2018 12:06:01 +0200 Subject: [PATCH] Prevent duplicated lines In case where /etc/network/interfaces already contains a similar line, it is superseeded. Change-Id: I38f244d093e002f8bc90412c1eacd254ffe31514 --- multi-node-aio/playbooks/setup-host.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/multi-node-aio/playbooks/setup-host.yml b/multi-node-aio/playbooks/setup-host.yml index a7c55afa..e144a426 100644 --- a/multi-node-aio/playbooks/setup-host.yml +++ b/multi-node-aio/playbooks/setup-host.yml @@ -140,6 +140,7 @@ lineinfile: line: "source /etc/network/interfaces.d/*.cfg" dest: "/etc/network/interfaces" + regexp: "^source /etc/network/interfaces.d/.*" - name: Set the host intefaces up command: "/sbin/ifup {{ item.value.iface }}"