diff --git a/roles/bootstrap-os/tasks/bootstrap-centos.yml b/roles/bootstrap-os/tasks/bootstrap-centos.yml index 1b5224f347ec97e88ef428b756b6cc200ac3f9f2..3e74e0d3736560715cb5d84e20a205e896ea6fb6 100644 --- a/roles/bootstrap-os/tasks/bootstrap-centos.yml +++ b/roles/bootstrap-os/tasks/bootstrap-centos.yml @@ -30,6 +30,7 @@ - name: Add proxy to /etc/yum.conf if http_proxy is defined lineinfile: path: "/etc/yum.conf" + regexp: "^proxy=.*$" line: "proxy={{ http_proxy }}" create: true state: present