Member-only story

Deploy Angular application on Alibaba Cloud ECS Server with NGINX and Certbot Certificate with Custom domain mapping

Balram Chavan
4 min readNov 24, 2024

In this story, we will deploy an Angular application on an Alibaba ECS instance with NGINX server along with SSL certificate setup with Certbot and custom domain mapping. We will also enable GZip compression to improve the performance.

Create a new Angular application.

I am using Angular 19 CLI to create a new project, but you can choose any Angular CLI version.

ng new ng19-hello-world

Create a production build

Once you are ready to deploy application, create a production build. If you have a different configuration to deploy, check your package.json and angular.json file.

ng build -c production

Zip output folder

Based on angular.json configuration, output folder with all assets shall be created generally in dist folder. Verify the content of the dist folder. In Angular 19, output folder contains browser folder which contains the index.html and main.##.js files.

Alibaba ECS Configuration

Creaet ECS Instance

--

--

Balram Chavan
Balram Chavan

Written by Balram Chavan

Google Developer Expert Angular | Architect | Author | http://www.youtube.com/@angularcloud

No responses yet