From 87b0dafaa63e81aa1b79836ee1843774909ab000 Mon Sep 17 00:00:00 2001 From: Mike Reeves Date: Wed, 30 May 2018 14:34:54 -0400 Subject: [PATCH] Master Module - Enable apt-cacher-ng --- salt/master/init.sls | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/salt/master/init.sls b/salt/master/init.sls index be522c30e..5a730b3f4 100644 --- a/salt/master/init.sls +++ b/salt/master/init.sls @@ -17,9 +17,32 @@ {% if masterproxy == 1 %} -# Create the config directory for apt-cacher-ng +# Create the directories for apt-cacher-ng +aptcacherconfdir: + file.directory: + - name: /opt/so/conf/aptcacher-ng/cache + - user: 939 + - group: 939 + - makedirs: True + +aptcacherlogdir: + file.directory: + - name: /opt/so/log/aptcacher-ng + - user: 939 + - group: 939 + - makedirs: true # Copy the config # Install the apt-cacher-ng container +so-aptcacherng: + docker_container.running: + - image: deployable/acng:latest-us + - hostname: so-aptcacherng + - user: socore + - port_bindings: + - 0.0.0.0:3142:3142 + - binds: + - /opt/so/conf/aptcacher-ng/cache"/var/cache/apt-cacher-ng:rw + # Create the config directory for the docker registry # Copy the config