Move supervisor and rsyslog sock files to their own dirs under /var/run

This commit is contained in:
Christian Adams
2020-03-12 13:43:43 -04:00
parent 7040fcfd88
commit 996d7ce054
6 changed files with 27 additions and 20 deletions

View File

@@ -47,7 +47,7 @@ stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0
[program:awx-rsyslogd]
command = rsyslogd -n -i /var/run/tower/sockets/rsyslog.pid -f /var/lib/awx/rsyslog/rsyslog.conf
command = rsyslogd -n -i /var/run/rsyslog/rsyslog.pid -f /var/lib/awx/rsyslog/rsyslog.conf
autostart = true
autorestart = true
stopwaitsecs = 1
@@ -74,10 +74,10 @@ events=TICK_60
priority=0
[unix_http_server]
file=/var/run/tower/sockets/supervisor.web.sock
file=/var/run/supervisor/supervisor.web.sock
[supervisorctl]
serverurl=unix:///var/run/tower/sockets/supervisor.web.sock ; use a unix:// URL for a unix socket
serverurl=unix:///var/run/supervisor/supervisor.web.sock ; use a unix:// URL for a unix socket
[rpcinterface:supervisor]
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface

View File

@@ -94,9 +94,11 @@ spec:
ports:
- containerPort: 8052
volumeMounts:
- name: sockets
mountPath: "/var/run/tower/sockets/"
- name: rsyslog
- name: supervisor-socket
mountPath: "/var/run/supervisor"
- name: rsyslog-socket
mountPath: "/var/run/rsyslog"
- name: rsyslog-config
mountPath: "/var/lib/awx/rsyslog/"
{% if ca_trust_dir is defined %}
- name: {{ kubernetes_deployment_name }}-ca-trust-dir
@@ -178,9 +180,11 @@ spec:
- /usr/bin/launch_awx_task.sh
imagePullPolicy: Always
volumeMounts:
- name: sockets
mountPath: "/var/run/tower/sockets/"
- name: rsyslog
- name: supervisor-socket
mountPath: "/var/run/supervisor"
- name: rsyslog-socket
mountPath: "/var/run/rsyslog"
- name: rsyslog-config
mountPath: "/var/lib/awx/rsyslog/"
{% if ca_trust_dir is defined %}
- name: {{ kubernetes_deployment_name }}-ca-trust-dir
@@ -323,9 +327,11 @@ spec:
{{ affinity | to_nice_yaml(indent=2) | indent(width=8, indentfirst=True) }}
{% endif %}
volumes:
- name: sockets
- name: supervisor-socket
emptyDir: {}
- name: rsyslog
- name: rsyslog-socket
emptyDir: {}
- name: rsyslog-config
emptyDir: {}
{% if ca_trust_dir is defined %}
- name: {{ kubernetes_deployment_name }}-ca-trust-dir

View File

@@ -20,8 +20,8 @@ services:
user: root
restart: unless-stopped
volumes:
- sockets:/var/run/tower/sockets/
- rsyslog:/var/lib/awx/rsyslog/
- rsyslog-socket:/var/run/rsyslog/
- rsyslog-config:/var/lib/awx/rsyslog/
- "{{ docker_compose_dir }}/SECRET_KEY:/etc/tower/SECRET_KEY"
- "{{ docker_compose_dir }}/environment.sh:/etc/tower/conf.d/environment.sh"
- "{{ docker_compose_dir }}/credentials.py:/etc/tower/conf.d/credentials.py"
@@ -77,8 +77,8 @@ services:
user: root
restart: unless-stopped
volumes:
- sockets:/var/run/tower/sockets/
- rsyslog:/var/lib/awx/rsyslog/
- rsyslog-socket:/var/run/rsyslog/
- rsyslog-config:/var/lib/awx/rsyslog/
- "{{ docker_compose_dir }}/SECRET_KEY:/etc/tower/SECRET_KEY"
- "{{ docker_compose_dir }}/environment.sh:/etc/tower/conf.d/environment.sh"
- "{{ docker_compose_dir }}/credentials.py:/etc/tower/conf.d/credentials.py"
@@ -163,5 +163,6 @@ services:
no_proxy: {{ no_proxy | default('') }}
{% endif %}
volumes:
sockets:
rsyslog:
supervisor-socket:
rsyslog-socket:
rsyslog-config: