【发布时间】:2017-07-05 15:35:43
【问题描述】:
我正在运行一个 K8s 集群,通过企业服务代理提供 gRPC 服务,同时通过 HTTPS 服务 gRPC 和 REST。
我正在尝试为此端点启用 CORS,但无法使其正常工作。
这是我的端点配置:
...
endpoints:
- name: <my-service>.endpoints.<my-project>.cloud.goog
target: <ENDPOINT_IP>
allow_cors: true
我已经更新了端点并更新了 ESP 配置。我已确认 /etc/nginx.d/service.json 中有一个部分或包含有关启用 CORS 的内容。
但是,当我向端点发出 OPTIONS 请求时,我会收到错误消息 The service does not allow CORS traffic.
我没有想法。有谁知道如何为我的端点启用 CORS?
【问题讨论】:
标签: google-cloud-platform google-cloud-endpoints