Lightweight automatic deployment in offline environment

flow chart:

 

  • Pain points of regular system releases
  1. The server restarts frequently, and the application services deployed on it cannot be restarted accordingly, resulting in frequent downtime of services
  2. Manual deployment of applications is relatively cumbersome and the steps are cumbersome
  3. The application release environment depends on the publisher's local environment, resulting in inconsistent release environments for different publishers each time, resulting in abnormalities in the application
  4. Service exceptions and server downtime cannot be handled automatically, and there is a problem of too long response time in human response
  5. The memory consumption of each server is serious and the pressure is high, which is inconvenient for unified management
  • docker containerization concept
  1. Docker is a lightweight virtualization technology that can package the development environment into a mirror at the same time. Like a virtual machine, an environment can be virtualized, but a virtual machine is a virtual hardware that virtualizes the entire operating system, while docker uses the hardware of the machine and uses a process-level virtual environment. So relatively speaking, docker will be more lightweight and faster.
  2. Docker containerization refers to the process of integrating applications into containers and running them; the core idea of ​​docker is how to integrate applications into containers and actually run them in containers. Once the application containerization is completed, it can be mirrored delivered as a container and run as a container.
  • Advantages of docker containerization
  1. Faster Delivery and Deployment
  2. more efficient virtualization
  3. Easier Migration and Scaling
  4. easier management
  • Automated deployment (CI/CD) concept
  1. All operations during the deployment process are fully automated without manual intervention.
  2. Approaches to frequently deliver applications to customers by introducing automation in the application development phase

  • Automate deployment
  1. Apply for multiple linux servers and unify system configuration
  2. Install the same offline version of docker on a linux server without an external network, and set up the docker environment
  3. Install docker-compose for unified orchestration, and then install swarm to build a cluster
  4. The Linux server is configured with each development environment
  5. Apply for an external network server (windows is also possible), install the agent, and point to the agent directly when compiling the code, so as to download the corresponding package
  6. Install Jenkins (automated build tool), portainer container management tool, etc. in the docker environment
  7. Migrate all systems in the current period to the swarm cluster

Guess you like

Origin blog.csdn.net/yiye2017zhangmu/article/details/129078016