3
votes

I have created a Docker image by building a Dockerfile from Nodejs application then pushed the Docker image to Azure Container Registry(ACR). Then created linux Azure container instance as service by referring the Docker image that we pushed to ACR. The application is running fine on port 80. Now We have a SSL certificate , now in order to run my application on port 443, How can i attach this SSL certificate to that Azure container Instance.

Thanks in Advance :)

1
Can I write commands to install nginx in the same Dockerfile, which i have written to dockerize my rails application, Because i am running the application in only one container. if Yes, please let me know in detail how can i configure to attach SSL certificate at nginx, to run my Azure container instance run on port 443(https).Bala krishna
I didn't get the configuration and deployment process mentioned in Azure Docs. The deployment process we follow for the application is 1. Including a Dockerfile in applicationa to Dockerize the application. 2. Creating a Docker Image by Building the Dockerfile with a tag 3. Pushing the Docker image to Azure Container Registr. 4. Restarting the Azure Container instance to take the new image. please provide solution based on this scenario. Thanks in Advance :)Bala krishna

1 Answers

1
votes

You could configure Nginx to use SSL as a sidecar container in your application container group. You could create an Nginx configuration file and Base64-encode the Nginx configuration file, the SSL certificate, and the SSL key. Then, you enter the encoded contents in a YAML file used to deploy the container group.

You could follow this document to enable an SSL endpoint in a container group.