From 17b93d9228dba1e2ac142743968f80a822a0f2b2 Mon Sep 17 00:00:00 2001 From: parithosh Date: Tue, 31 Oct 2023 18:23:14 +0100 Subject: [PATCH] adding validation --- roles/teku/tasks/main.yaml | 3 +++ roles/teku/tasks/validations.yaml | 4 ++++ 2 files changed, 7 insertions(+) create mode 100644 roles/teku/tasks/validations.yaml diff --git a/roles/teku/tasks/main.yaml b/roles/teku/tasks/main.yaml index f0bf4e43..00449c1c 100644 --- a/roles/teku/tasks/main.yaml +++ b/roles/teku/tasks/main.yaml @@ -1,3 +1,6 @@ +- name: Validate inputs + ansible.builtin.import_tasks: validations.yaml + - name: Setup teku ansible.builtin.import_tasks: setup.yaml when: not teku_cleanup diff --git a/roles/teku/tasks/validations.yaml b/roles/teku/tasks/validations.yaml new file mode 100644 index 00000000..4104f3d1 --- /dev/null +++ b/roles/teku/tasks/validations.yaml @@ -0,0 +1,4 @@ +- name: Check if consensus client supports blobber configuration + ansible.builtin.fail: + msg: "Error: Teku cannot run checkpoint sync if the initial-state flag is already defined" + when: "teku_checkpoint_sync_enabled and (teku_container_command_extra_args | default('') | regex_search('initial-state') != None)"