From 5a83b46cde940e8b8b65316253485ecbaaa7a1c5 Mon Sep 17 00:00:00 2001 From: "ffleureau@qovery.com" Date: Thu, 1 Aug 2024 18:50:16 +0200 Subject: [PATCH 1/2] feat(cor-1017): add access_key fields for aws and scw credentials --- openapi.yaml | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) diff --git a/openapi.yaml b/openapi.yaml index 935436bf..7f20dafe 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -12191,16 +12191,86 @@ components: region: type: string ClusterCredentials: + oneOf: + - $ref: '#/components/schemas/AwsClusterCredentials' + - $ref: '#/components/schemas/ScalewayClusterCredentials' + - $ref: '#/components/schemas/GenericClusterCredentials' + discriminator: + propertyName: job_type + mapping: + AWS: '#/components/schemas/AwsClusterCredentials' + SCW: '#/components/schemas/ScalewayClusterCredentials' + OTHER: '#/components/schemas/GenericClusterCredentials' + AwsClusterCredentials: + x-stoplight: + id: s0aosg7la96hp + title: AwsClusterCredentials + type: object + required: + - id + - name + - access_key_id + - object_type + properties: + id: + type: string + x-stoplight: + id: en79y0yc76xhp + format: uuid + name: + type: string + x-stoplight: + id: mx0mwek4ubieo + access_key_id: + type: string + x-stoplight: + id: 6g20j0ggu8nqc + object_type: + x-stoplight: + id: ravczabg8e2sp + enum: + - AWS + ScalewayClusterCredentials: + title: ScalewayClusterCredentials + x-stoplight: + id: j3ep46eyah9p5 type: object required: - id - name + - scaleway_access_key + - object_type properties: id: type: string format: uuid name: type: string + scaleway_access_key: + type: string + x-stoplight: + id: 4db3031sq6tea + object_type: + enum: + - SCW + GenericClusterCredentials: + title: GenericClusterCredentials + x-stoplight: + id: gtibx4nzrvxm9 + type: object + required: + - id + - name + - object_type + properties: + id: + type: string + format: uuid + name: + type: string + object_type: + enum: + - OTHER ClusterCredentialsResponseList: type: object properties: @@ -17960,6 +18030,7 @@ components: $ref: '#/components/schemas/OrganizationAnnotationsGroupResponseList' labels_groups: $ref: '#/components/schemas/OrganizationLabelsGroupResponseList' + title: '' CronJobResponse: allOf: - $ref: '#/components/schemas/BaseJobResponse' From 18322f894c37d2de34d3bd5a9ea1227c0b31fdb1 Mon Sep 17 00:00:00 2001 From: Fabien Fleureau Date: Fri, 2 Aug 2024 10:04:44 +0200 Subject: [PATCH 2/2] fix: fix propertyName Co-authored-by: Melvin Zottola <37779145+mzottola@users.noreply.github.com> --- openapi.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openapi.yaml b/openapi.yaml index 7f20dafe..d839d7f7 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -12196,7 +12196,7 @@ components: - $ref: '#/components/schemas/ScalewayClusterCredentials' - $ref: '#/components/schemas/GenericClusterCredentials' discriminator: - propertyName: job_type + propertyName: object_type mapping: AWS: '#/components/schemas/AwsClusterCredentials' SCW: '#/components/schemas/ScalewayClusterCredentials'