From aeecc940179b91599e15ab1c708742eb29221a78 Mon Sep 17 00:00:00 2001 From: Jeff Geerling Date: Tue, 26 May 2020 16:13:14 -0500 Subject: [PATCH] Issue #42: Make sure redis is listening on TCP port. --- roles/tower/tasks/main.yml | 2 +- roles/tower/templates/tower_config.yaml.j2 | 6 ------ roles/tower/templates/tower_redis.yaml.j2 | 18 ------------------ 3 files changed, 1 insertion(+), 25 deletions(-) diff --git a/roles/tower/tasks/main.yml b/roles/tower/tasks/main.yml index 96cac97..086b477 100644 --- a/roles/tower/tasks/main.yml +++ b/roles/tower/tasks/main.yml @@ -6,8 +6,8 @@ with_items: - tower_memcached.yaml.j2 - tower_postgres.yaml.j2 - - tower_redis.yaml.j2 - tower_config.yaml.j2 + - tower_redis.yaml.j2 - tower_web.yaml.j2 - tower_task.yaml.j2 diff --git a/roles/tower/templates/tower_config.yaml.j2 b/roles/tower/templates/tower_config.yaml.j2 index 5ba5664..e1b501c 100644 --- a/roles/tower/templates/tower_config.yaml.j2 +++ b/roles/tower/templates/tower_config.yaml.j2 @@ -121,12 +121,6 @@ data: USE_X_FORWARDED_PORT = True - redis_conf: | - unixsocket /var/run/redis/redis.sock - unixsocketperm 777 - port 0 - bind 127.0.0.1 - nginx_conf: | worker_processes 1; pid /tmp/nginx.pid; diff --git a/roles/tower/templates/tower_redis.yaml.j2 b/roles/tower/templates/tower_redis.yaml.j2 index 64680c7..f0aee39 100644 --- a/roles/tower/templates/tower_redis.yaml.j2 +++ b/roles/tower/templates/tower_redis.yaml.j2 @@ -20,29 +20,12 @@ spec: containers: - image: '{{ tower_redis_image }}' name: redis - args: ["/usr/local/etc/redis/redis.conf"] ports: - containerPort: 6379 - volumeMounts: - - name: redis-config - mountPath: /usr/local/etc/redis/redis.conf - subPath: redis.conf - readOnly: true - - name: redis-socket - mountPath: "/var/run/redis" resources: requests: memory: "{{ tower_redis_mem_request }}" cpu: "{{ tower_redis_cpu_request }}" - volumes: - - name: redis-config - configMap: - name: "{{ meta.name }}-tower-configmap" - items: - - key: redis_conf - path: redis.conf - - name: redis-socket - emtpyDir: {} # Redis Service. --- @@ -54,7 +37,6 @@ metadata: labels: app: tower-redis spec: - clusterIP: None ports: - port: 6379 protocol: TCP