Skip to content

Commit 2a05233

Browse files
authored
Merge pull request #88848 from dlepow/acifix2
[ACI] Expanded troubleshooting for ports
2 parents 5e35e4e + 33141d7 commit 2a05233

File tree

1 file changed

+25
-4
lines changed

1 file changed

+25
-4
lines changed

articles/container-instances/container-instances-troubleshooting.md

Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,16 @@ manager: gwallace
77

88
ms.service: container-instances
99
ms.topic: article
10-
ms.date: 04/25/2019
10+
ms.date: 09/25/2019
1111
ms.author: danlep
1212
ms.custom: mvc
1313
---
1414

1515
# Troubleshoot common issues in Azure Container Instances
1616

17-
This article shows how to troubleshoot common issues for managing or deploying containers to Azure Container Instances. See also [Frequently asked questions](container-instances-faq.md).
17+
This article shows how to troubleshoot common issues for managing or deploying containers to Azure Container Instances. See also [Frequently asked questions](container-instances-faq.md).
18+
19+
If you need additional support, see available **Help + support** options in the [Azure portal](https://portal.azure.com/?#blade/Microsoft_Azure_Support/HelpAndSupportBlade).
1820

1921
## Naming conventions
2022

@@ -196,9 +198,28 @@ This error indicates that due to heavy load in the region in which you are attem
196198

197199
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. If you require Docker interaction, check the [REST reference documentation](https://aka.ms/aci/rest) to see what the ACI API supports. If there is something missing, submit a request on the [ACI feedback forums](https://aka.ms/aci/feedback).
198200

199-
## IPs may not be accessible due to mismatched ports
201+
## Container group IP address may not be accessible due to mismatched ports
202+
203+
Azure Container Instances doesn't yet support port mapping like with regular docker configuration. If you find a container group's IP address is not accessible when you believe it should be, ensure you have configured your container image to listen to the same ports you expose in your container group with the `ports` property.
204+
205+
If you want to confirm that Azure Container Instances can listen on the port you configured in your container image, test a deployment of the `aci-helloworld` image that exposes the port. Also run the `aci-helloworld` app so that it listens on the port. `aci-helloworld` accepts an optional environment variable `PORT` to override the default port 80 it listens on. For example, to test port 9000:
206+
207+
1. Set up the container group to expose port 9000, and pass the port number as the value of the environment variable:
208+
```azurecli
209+
az container create --resource-group myResourceGroup \
210+
--name mycontainer --image mcr.microsoft.com/azuredocs/aci-helloworld \
211+
--ip-address Public --ports 9000 \
212+
--environment-variables 'PORT'='9000'
213+
```
214+
1. Find the IP address of the container group in the command output of `az container create`. Look for the value of **ip**.
215+
1. After the container is provisioned successfully, browse to the IP address and port of the container app in your browser, for example: `192.0.2.0:9000`.
216+
217+
You should see the "Welcome to Azure Container Instances!" message displayed by the web app.
218+
1. When you're done with the container, remove it using the `az container delete` command:
200219
201-
Azure Container Instances does not currently support port mapping like with regular docker configuration, however this fix is on the roadmap. If you find IPs are not accessible when you believe it should be, ensure you have configured your container image to listen to the same ports you expose in your container group with the `ports` property.
220+
```azurecli
221+
az container delete --resource-group myResourceGroup --name mycontainer
222+
```
202223
203224
## Next steps
204225

0 commit comments

Comments
 (0)