Merge branch 'feature/bec_server_config' into 'main'

feat: add separate server and client config

See merge request psd_deployments/roles/psi.bec!5
This commit is contained in:
2025-07-29 12:09:05 +02:00
5 changed files with 42 additions and 24 deletions
+1
View File
@@ -6,6 +6,7 @@ bec_deployments_path: /opt/bec_deployments
deployment_name: production
file_writer_base_path: ./
log_writer_base_path: ./
client_data_base_path: ./
bec_version: main
ophyd_devices_version: main
bec_widgets_version: main
+19 -5
View File
@@ -1,14 +1,14 @@
---
- name: Install redis
ansible.builtin.dnf:
name: '@redis:6'
name: "@redis:6"
state: present
- name: Copy redis config
ansible.builtin.template:
src: redis.conf.j2
dest: /etc/redis.conf
mode: '0644'
mode: "0644"
notify:
- Enable and (re-)start redis
@@ -143,11 +143,25 @@
notify:
- (Re-)start BEC server
- name: Create BEC deployment config directory
become_user: "{{ bec_user }}"
ansible.builtin.file:
path: "{{ bec_path }}/bec/deployment_configs"
state: directory
- name: Copy BEC service config
become_user: "{{ bec_user }}"
ansible.builtin.template:
src: bec_config.yaml.j2
dest: "{{ bec_path }}/bec_config.yaml"
src: bec_config_server.yaml.j2
dest: "{{ bec_path }}/bec/deployment_configs/server.yaml"
notify:
- (Re-)start BEC server
- name: Copy BEC client config
become_user: "{{ bec_user }}"
ansible.builtin.template:
src: bec_config_client.yaml.j2
dest: "{{ bec_path }}/bec/deployment_configs/client.yaml"
notify:
- (Re-)start BEC server
@@ -193,7 +207,7 @@
ansible.builtin.template:
src: bec.j2
dest: /usr/local/bin/bec
mode: '0755'
mode: "0755"
- name: Install vscode
become: true
-19
View File
@@ -1,19 +0,0 @@
redis:
host: {{ ansible_fqdn }}
port: 6379
mongodb:
host: localhost
port: 27017
scibec:
host: http://localhost
port: 3030
beamline: MyBeamline
env_file: {{ bec_path }}
service_config:
file_writer:
plugin: default_NeXus_format
base_path: {{ file_writer_base_path }}
log_writer:
base_path: {{ log_writer_base_path }}
scilog:
env_file: ./
+11
View File
@@ -0,0 +1,11 @@
redis:
host: {{ ansible_fqdn }}
port: 6379
log_writer:
base_path: {{ client_data_base_path }}/logs
user_scripts:
base_path: {{ client_data_base_path }}/scripts
user_macros:
base_path: {{ client_data_base_path }}/macros
widgets_settings:
base_path: {{ client_data_base_path }}/widgets
+11
View File
@@ -0,0 +1,11 @@
redis:
host: {{ ansible_fqdn }}
port: 6379
file_writer:
base_path: {{ file_writer_base_path }}
log_writer:
base_path: {{ log_writer_base_path }}
scilog:
env_file: ./
acl:
acl_file: ./.bec_acl.env