diff --git a/deployment/kubernetes/deforestation-api.yaml b/deployment/kubernetes/deforestation-api.yaml index 7dcc898..9d11eb0 100644 --- a/deployment/kubernetes/deforestation-api.yaml +++ b/deployment/kubernetes/deforestation-api.yaml @@ -60,6 +60,19 @@ spec: forceSlash: true --- apiVersion: traefik.io/v1alpha1 +kind: Middleware +metadata: + name: cors-deforestation +spec: + headers: + accessControlAllowMethods: + - "GET" + accessControlAllowHeaders: + - "*" + accessControlAllowOriginList: + - "*" +--- +apiVersion: traefik.io/v1alpha1 kind: IngressRoute metadata: name: deforestation-api @@ -75,4 +88,5 @@ spec: port: 80 middlewares: - name: stripprefix-deforestation + - name: cors-deforestation