如何将 POST 请求发送到 Docker 容器的 运行 ACI 实例
How to send POST request to running ACI instance of Docker container
我有一个 运行 Azure 容器实例 (ACI),该实例基于 Docker 图像,并公开了一个端口。容器实例是一个 API 接受基本 JSON 请求和 returns 一个 JSON 响应。我目前无法收到 ACI 的回复。
我正在使用 Postman 发送测试 POST 请求。目前,我没有收到回复。我听说 headers 中可能需要一些 keys/values,但我不确定这些键是什么。我还想知道是否还有什么我需要知道的(例如,我需要添加或附加到容器的 fully-qualified 域名的任何内容)。
如果请求成功,我希望看到 JSON 响应。
您似乎想向 ACI 上的 Docker API 主机发送 POST 请求。参考this,注意是
Azure Container Instances does not expose direct access to the
underlying infrastructure that hosts container groups. This includes
access to the Docker API running on the container's host and running
privileged containers.
如果您需要 Docker 互动,请勾选 REST reference documentation to see what the ACI API supports. If you're meant to know how to call Azure REST API with the postman, you can follow this and the step-by-step blog。
我有一个 运行 Azure 容器实例 (ACI),该实例基于 Docker 图像,并公开了一个端口。容器实例是一个 API 接受基本 JSON 请求和 returns 一个 JSON 响应。我目前无法收到 ACI 的回复。
我正在使用 Postman 发送测试 POST 请求。目前,我没有收到回复。我听说 headers 中可能需要一些 keys/values,但我不确定这些键是什么。我还想知道是否还有什么我需要知道的(例如,我需要添加或附加到容器的 fully-qualified 域名的任何内容)。
如果请求成功,我希望看到 JSON 响应。
您似乎想向 ACI 上的 Docker API 主机发送 POST 请求。参考this,注意是
Azure Container Instances does not expose direct access to the underlying infrastructure that hosts container groups. This includes access to the Docker API running on the container's host and running privileged containers.
如果您需要 Docker 互动,请勾选 REST reference documentation to see what the ACI API supports. If you're meant to know how to call Azure REST API with the postman, you can follow this and the step-by-step blog。