From 3ff81e0ab45b3119ac33d15e2e157bd082368abb Mon Sep 17 00:00:00 2001 From: Aaron Hetherington Date: Tue, 5 Dec 2023 10:18:37 +0000 Subject: [PATCH] Add directoy option for receptors data --- config/crd/bases/awx.ansible.com_awxs.yaml | 3 +++ .../manifests/bases/awx-operator.clusterserviceversion.yaml | 5 +++++ roles/installer/defaults/main.yml | 2 ++ roles/installer/templates/configmaps/config.yaml.j2 | 3 +++ 4 files changed, 13 insertions(+) diff --git a/config/crd/bases/awx.ansible.com_awxs.yaml b/config/crd/bases/awx.ansible.com_awxs.yaml index 1fb2d61ec6..a7b8b90276 100644 --- a/config/crd/bases/awx.ansible.com_awxs.yaml +++ b/config/crd/bases/awx.ansible.com_awxs.yaml @@ -1792,6 +1792,9 @@ spec: receptor_log_level: description: Set log level of receptor service type: string + receptor_persist_dir: + description: Set directory for receptor logs + type: string extra_settings: description: Extra settings to specify for the API items: diff --git a/config/manifests/bases/awx-operator.clusterserviceversion.yaml b/config/manifests/bases/awx-operator.clusterserviceversion.yaml index c9ae90698d..fb5d733d0b 100644 --- a/config/manifests/bases/awx-operator.clusterserviceversion.yaml +++ b/config/manifests/bases/awx-operator.clusterserviceversion.yaml @@ -889,6 +889,11 @@ spec: x-descriptors: - urn:alm:descriptor:com.tectonic.ui:advanced - urn:alm:descriptor:com.tectonic.ui:hidden + - displayName: Receptor Persistant Data Directory + path: receptor_persist_dir + x-descriptors: + - urn:alm:descriptor:com.tectonic.ui:advanced + - urn:alm:descriptor:com.tectonic.ui:hidden - displayName: API Extra Settings path: extra_settings x-descriptors: diff --git a/roles/installer/defaults/main.yml b/roles/installer/defaults/main.yml index bd5d403910..7448243652 100644 --- a/roles/installer/defaults/main.yml +++ b/roles/installer/defaults/main.yml @@ -458,6 +458,8 @@ host_aliases: '' receptor_log_level: info +receptor_persist_dir: /tmp/receptor/ + # UWSGI default values uwsgi_processes: 5 # NOTE: to increase this value, net.core.somaxconn must also be increased diff --git a/roles/installer/templates/configmaps/config.yaml.j2 b/roles/installer/templates/configmaps/config.yaml.j2 index 649f3dd4fa..63f10fa5c6 100644 --- a/roles/installer/templates/configmaps/config.yaml.j2 +++ b/roles/installer/templates/configmaps/config.yaml.j2 @@ -86,6 +86,8 @@ data: RECEPTOR_LOG_LEVEL = '{{ receptor_log_level }}' + RECEPTOR_PERSIST_DIR = '{{ receptor_persist_dir }}' + {% for item in extra_settings | default([]) %} {{ item.setting }} = {{ item.value }} @@ -247,6 +249,7 @@ data: - action: reject tonode: HOSTNAME toservice: control + datadir: {{ receptor_persist_dir }} - control-service: service: control filename: /var/run/receptor/receptor.sock