Skip to content

Latest commit

 

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

Auto Deploy On Nginx with Shell Script

1. Auto Static Files Deployment

It will install and configure all dependencies(nginx, node, etc.). For example, built angular, react, vue, etc. project.

Directory tree for static project

├── run-static.sh
│
├── static-nginx.conf
|
└── dist
      |
      └── <PROJECT_NAME>
              |
              └── PROJECT FILES...

2. Auto Angular Project Deployment

Install all required dependencies (nginx, node, npm, @angular/cli, etc.), build project, and then deploy.

IMPORTANT NOTE: The script will run npm run build. so change the scripts -> build in package.json

Example:

  "scripts": {
    ...
    "build": "ng build --prod --base-href /example",
    ...
  }

Directory tree for Angular project

├── <PROJECT_FOLDER>
│       │
│       ├── run-angular.sh
│       │
│       ├── angular-nginx.conf
│       │
│       └── PROJECT FILES...
│

3. Auto SSL Certificate

It will install and configure all! Use Let's encrypt and Certbot in background. redirecting from HTTP to HTTPS will configure if you want.

About

Auto Deploy on Nginx web server

Topics

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages