From 7ce9a607ec5bbed2531556afadeefc81b9fe2cb5 Mon Sep 17 00:00:00 2001 From: user Date: Mon, 30 Oct 2023 13:28:50 +0530 Subject: [PATCH 1/2] API onboarding for Review flow --- ansible/roles/kong-api/defaults/main.yml | 83 ++++++++++++++++++++++++ 1 file changed, 83 insertions(+) diff --git a/ansible/roles/kong-api/defaults/main.yml b/ansible/roles/kong-api/defaults/main.yml index cf51212d15..e792044e04 100644 --- a/ansible/roles/kong-api/defaults/main.yml +++ b/ansible/roles/kong-api/defaults/main.yml @@ -10646,3 +10646,86 @@ kong_apis: config.required: false config.enabled: false +- name: questionSetUpdateComment + uris: "{{ questionset_prefix }}/v1/comment/update" + upstream_url: "{{ assessment_service_url }}/questionset/v4/comment/update" + strip_uri: true + plugins: + - name: jwt + - name: cors + - "{{ statsd_pulgin }}" + - name: acl + config.whitelist: + - contentAdmin + - name: rate-limiting + config.policy: local + config.hour: "{{ medium_rate_limit_per_hour }}" + config.limit_by: credential + - name: request-size-limiting + config.allowed_payload_size: "{{ medium_request_size_limit }}" + - name: opa-checks + config.required: false + config.enabled: false + +- name: questionSetUpdateCommentV2 + uris: "{{ questionset_prefix }}/v2/comment/update" + upstream_url: "{{ assessment_service_url }}/questionset/v5/comment/update" + strip_uri: true + plugins: + - name: jwt + - name: cors + - "{{ statsd_pulgin }}" + - name: acl + config.whitelist: + - contentAdmin + - name: rate-limiting + config.policy: local + config.hour: "{{ medium_rate_limit_per_hour }}" + config.limit_by: credential + - name: request-size-limiting + config.allowed_payload_size: "{{ medium_request_size_limit }}" + - name: opa-checks + config.required: false + config.enabled: false + +- name: questionSetReadComment + uris: "{{ questionset_prefix }}/v1/comment/read" + upstream_url: "{{ assessment_service_url }}/questionset/v4/comment/read" + strip_uri: true + plugins: + - name: jwt + - name: cors + - "{{ statsd_pulgin }}" + - name: acl + config.whitelist: + - contentAdmin + - name: rate-limiting + config.policy: local + config.hour: "{{ medium_rate_limit_per_hour }}" + config.limit_by: credential + - name: request-size-limiting + config.allowed_payload_size: "{{ medium_request_size_limit }}" + - name: opa-checks + config.required: false + config.enabled: false + +- name: questionSetReadCommentV2 + uris: "{{ questionset_prefix }}/v2/comment/read" + upstream_url: "{{ assessment_service_url }}/questionset/v5/comment/read" + strip_uri: true + plugins: + - name: jwt + - name: cors + - "{{ statsd_pulgin }}" + - name: acl + config.whitelist: + - contentAdmin + - name: rate-limiting + config.policy: local + config.hour: "{{ medium_rate_limit_per_hour }}" + config.limit_by: credential + - name: request-size-limiting + config.allowed_payload_size: "{{ medium_request_size_limit }}" + - name: opa-checks + config.required: false + config.enabled: false From 39fabf0e00f2a69fb436730b9c7c187038f5da0f Mon Sep 17 00:00:00 2001 From: Vivek M <125434153+Vivek-M-08@users.noreply.github.com> Date: Tue, 31 Oct 2023 09:56:42 +0530 Subject: [PATCH 2/2] Updated ACL for update read comment --- ansible/roles/kong-api/defaults/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ansible/roles/kong-api/defaults/main.yml b/ansible/roles/kong-api/defaults/main.yml index e792044e04..180ec9828b 100644 --- a/ansible/roles/kong-api/defaults/main.yml +++ b/ansible/roles/kong-api/defaults/main.yml @@ -10698,7 +10698,7 @@ kong_apis: - "{{ statsd_pulgin }}" - name: acl config.whitelist: - - contentAdmin + - contentAccess - name: rate-limiting config.policy: local config.hour: "{{ medium_rate_limit_per_hour }}" @@ -10719,7 +10719,7 @@ kong_apis: - "{{ statsd_pulgin }}" - name: acl config.whitelist: - - contentAdmin + - contentAccess - name: rate-limiting config.policy: local config.hour: "{{ medium_rate_limit_per_hour }}"