Simplify pipeline credential management
This commit is contained in:
@@ -164,34 +164,6 @@ if run_converge "$invalid_key_log" "${baseline_args[@]}" \
|
||||
-e '{"dnd_pipeline_secrets":{"INVALID-KEY":"invalid-key-synthetic-value"}}'; then
|
||||
exit 1
|
||||
fi
|
||||
invalid_value_log="$test_tmp/invalid-value.log"
|
||||
if run_converge "$invalid_value_log" "${baseline_args[@]}" \
|
||||
-e '{"dnd_pipeline_secrets":{"EMPTY_VALUE_KEY":""}}'; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
removal_key=NARRATIO_TEST_REMOVAL_KEY
|
||||
removal_value=removal-synthetic-value
|
||||
removal_present_config="{\"dnd_pipeline_secrets\":{\"AUDITA_LLM_API_KEY\":\"$synthetic_audita_api_key\",\"OPENROUTER_API_KEY\":\"$synthetic_notarius_api_key\",\"$removal_key\":\"$removal_value\"},\"dnd_pipeline_narratio_notarius_llm_api_key\":\"$removal_key\"}"
|
||||
removal_present_log="$test_tmp/removal-present.log"
|
||||
run_converge "$removal_present_log" "${baseline_args[@]}" -e "$removal_present_config"
|
||||
removal_present_validation_log="$test_tmp/removal-present-validation.log"
|
||||
/usr/bin/sudo -u narratio /usr/local/bin/narratio config validate \
|
||||
--config /usr/local/etc/narratio/pipeline.yml --campaign centaurs | tee "$removal_present_validation_log"
|
||||
removal_absent_config="{\"dnd_pipeline_secrets\":{\"AUDITA_LLM_API_KEY\":\"$synthetic_audita_api_key\",\"OPENROUTER_API_KEY\":\"$synthetic_notarius_api_key\",\"$removal_key\":null},\"dnd_pipeline_narratio_notarius_llm_api_key\":\"$removal_key\"}"
|
||||
removal_absent_log="$test_tmp/removal-absent.log"
|
||||
run_converge "$removal_absent_log" "${baseline_args[@]}" -e "$removal_absent_config"
|
||||
removal_absent_validation_log="$test_tmp/removal-absent-validation.log"
|
||||
if /usr/bin/sudo -u narratio /usr/local/bin/narratio config validate \
|
||||
--config /usr/local/etc/narratio/pipeline.yml --campaign centaurs | tee "$removal_absent_validation_log"; then
|
||||
exit 1
|
||||
fi
|
||||
removal_absent_repeat_log="$test_tmp/removal-absent-repeat.log"
|
||||
run_converge "$removal_absent_repeat_log" "${baseline_args[@]}" -e "$removal_absent_config"
|
||||
require_clean_recap "$removal_absent_repeat_log"
|
||||
! grep -Fq "$synthetic_audita_api_key" "$baseline_log" "$removal_present_log" "$removal_absent_log" "$removal_present_validation_log" "$removal_absent_validation_log"
|
||||
! grep -Fq "$synthetic_notarius_api_key" "$baseline_log" "$removal_present_log" "$removal_absent_log" "$removal_present_validation_log" "$removal_absent_validation_log"
|
||||
! grep -Fq "$removal_value" "$removal_present_log" "$removal_absent_log" "$removal_present_validation_log" "$removal_absent_validation_log"
|
||||
|
||||
testing_profile_log="$test_tmp/testing-profile.log"
|
||||
run_converge "$testing_profile_log" "${baseline_args[@]}" \
|
||||
|
||||
Reference in New Issue
Block a user