Hello Fabio Soares
Welcome to Microsoft Q&A Platform, thanks for posting your query here.
Thank you for clarifying that the issue only seems to be happening with Windows containers. There are several factors that contribute to container startup time in Azure Container Instances, including image size, image location, and cached images. The issue may be related to specific Windows Server version that you are using or the container image that you are trying to run.
Few reason could be:
-The container image you are using is too large, which can cause the container to take a long time to start and eventually get killed. You can check the size of your container image by using the docker images command in the Docker CLI.
-The container is not able to connect to the underlying Docker API or run privileged containers<sup>.</sup> You can check the logs to see if there are any errors related to this issue.
- It's also possible that there is an issue with the Azure region you are using. If the region is experiencing heavy load, it may not be able to allocate the resources required for your container.
Sharing some troubleshooting steps that you can try and see if these help resolve your issue:
- Make sure that you are using a version of Windows Server that is supported by the container image you are trying to run. Some container images may only work with specific versions of Windows Server, so it is important to check the compatibility.
- You can try using a different container image that is designed for Windows.
- Make sure that the container host has the necessary components and features installed to support Windows containers. The host must be running Windows Server 2016 or later, and must have the Docker engine installed with support for Windows containers.
- Make sure that the container configuration is correct and includes all the required parameters, such as the entry point and command. You can check the configuration by inspecting the container using the Docker CLI.
- Checking the container logs can provide valuable information about why the container is failing to start or crashing. Look for any error messages or warnings in the logs that might indicate the cause of the issue.
Note: Windows containers may have no inbound or outbound connectivity for up to 30 seconds (or longer, in rare cases) on initial creation. If your container application needs an Internet connection, add delay and retry logic to allow 30 seconds to establish Internet connectivity.
Hope this helps.
If you are still not able to get the issue resolved, I would recommend to open a support case to get this checked.
If you need further help on this, tag me in a comment.
If the suggested response helped you resolve your issue, please 'Accept as answer', so that it can help others in the community looking for help on similar topics.