2023-04-12 01:18:12,658 p=30375 u=pservice TASK [general/check/conf : Check generated…
- User
2023-04-12 01:18:12,658 p=30375 u=pservice | TASK [general/check/conf : Check generated "cnc.json" file by schema with json validator] ************************************************************************************************************* 2023-04-12 01:18:12,660 p=30375 u=pservice | task path: /opt/pservice/ansible/cnc_7_35_1/install/common/general/check/conf/tasks/main.yml:28 2023-04-12 01:18:12,661 p=30375 u=pservice | fatal: [cnc_subs_test1 -> localhost]: FAILED! => { "censored": "the output has been hidden due to the fact that 'no_log: true' was specified for this result", "changed": true }
- Assistant
The task at path /opt/pservice/ansible/cnc_7_35_1/install/common/general/check/conf/tasks/main.yml failed to generate the "cnc.json" file by schema with json validator. The output has been hidden due to the fact that 'no_log: true' was specified for this result.
- User
- name: Check generated "{{ product_name }}.json" file by schema with json validator shell: > command {{ zloader_java_path | default('java') }} -Xms200m -jar {{ role_path }}/../schema/files/json-schema-validator-2.2.6-lib.jar {{ playbook_dir }}/schemas/{{ product_name }}-schema.json {{ tmp_path }}/{{ product_name }}.json no_log: "{{ not debug_log | bool }}" ignore_errors: true register: internal_check_result delegate_to: localhost become: False
- Assistant
This task checks the validity of the generated "{{ product_name }}.json" file by using a json validator. It uses the zloader java path to run the validator and passes the path to the schema and the path to the generated file to the validator. The no_log option is set to suppress output in case the task fails. The ignore_errors option is set to true to allow the play to continue even if the validation fails. The task is registered to internal_check_result, which can be used in subsequent tasks. The task is delegated to the localhost and does not execute as root.
- User
как отключить no_log
- Assistant
To disable
no_logfor a particular task, you need to remove theno_log: trueparameter from that task. For example, if you want to disableno_logfor the task mentioned in your previous message, you need to remove theno_log: "{{ not debug_log | bool }}"line from the task. Keep in mind that this will make the output of the task visible in the Ansible logs, including any sensitive data that might be present in the output.