A method for releasing, deploying and upgrading container images and software system resources separately
Through the separation, release, deployment and upgrade methods of container mirroring and software system resources, the problem of version binding between container mirroring and software system programs is solved, the release efficiency of software system is improved, and the energy overhead is reduced, and the digitalization of software system is realized. Service-oriented evolution.
Patent Information
- Application Number
- CN202210329839.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-31
- Publication Date
- 2024-11-26
- Estimated Expiration
- 2042-03-31
AI Technical Summary
The existing container image is bound to the software system program and the basic container image version, which leads to difficulty in offline release, crevice solidification, frequent software modification, and repeated packaging, which consumes time and energy, especially in the case of multi-vendor collaboration, which affects the software system. Release efficiency.
Using the separation, deployment and upgrade methods of container mirroring and software system resources, by selecting mirroring, programming, configuration, and data type upload, software vendor and version information are created, providing access addresses, and decompressing in container instances through lightweight bootloaders. and load resources, independently manage the updates of container images and software system resources.
It improves the research and development and release efficiency of software systems, reduces energy overhead, solves the technical difficulties of application containers in multi-vendor collaboration and offline environments, and promotes the digitalization and service evolution of software systems.
Smart Images

Figure CN114610357B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of container cloud technology, and in particular to a method for separately publishing, deploying and upgrading container images and software system resources. Background Art
[0002] For service integration platforms based on container cloud technology, container images are the basis for the release, deployment, and upgrade of software system services. Container images use a layered stacking, parent-child dependency, and data read-only model, which well encapsulates the software system's operating dependencies and configurations, reducing the problems caused by dependencies on development environments, test environments, and production environments, as well as inconsistent configurations.
[0003] However, since the software system program is bound to the basic container image version, there are the following problems: ① For offline release and multi-vendor collaboration, the overall container image of the software system is often too large and inconvenient to release; ② Vulnerability fixation problem. When upgrading the software system program vulnerabilities, it is also necessary to upgrade the vulnerabilities of the basic container image; ③ Frequent software modifications and repeated packaging of container images are time-consuming and energy-consuming. Therefore, it is necessary to innovate and optimize the release methods and processes of container-based software system programs to improve the efficiency of version collaboration and software release. Summary of the invention
[0004] In view of the above-mentioned deficiencies in the prior art, a method for separately publishing, deploying and upgrading container images and software system resources provided by the present invention solves the problem of difficulty in applying container technology in multi-vendor collaboration and offline environments.
[0005] In order to achieve the above-mentioned invention object, the technical solution adopted by the present invention is: a method for separating and distributing container images and software system resources, comprising the following steps:
[0006] A1. Select the image type to upload the container image, select the program type to upload the software system program, select the configuration type to upload the software system configuration, and select the data type to upload the software system data;
[0007] A2. Create software vendor information;
[0008] A3. Create software name information and select associated software manufacturer information;
[0009] A4. Create software version information, find the associated software name information, and select four types of resources: associated image, program, configuration, and data;
[0010] A5. Release the software system and provide access address to the outside world.
[0011] A method for deploying container images and software system resources, comprising the following steps:
[0012] B1. Parse the software system resource parameter information passed into the container through the container instance resource object, and determine whether it has been downloaded;
[0013] B2. If it is not downloaded, assemble the download address by passing in parameter information and download the corresponding software system resources;
[0014] B3. Decompress the software system application data to a temporary directory in the container instance, and execute the data loading program or script in the temporary directory to load the data;
[0015] B4. Unzip the software system program to the software running directory in the container instance;
[0016] B5. Decompress the software system configuration to the software running configuration file storage directory under the software running directory in the container instance;
[0017] B6. Load the software startup program or startup script in the software running directory in the container instance.
[0018] A method for upgrading container images and software system resources comprises the following steps:
[0019] C1. Parse the software system resource parameter information passed into the container through the container instance resource object, compare the versions and determine the upgrade content;
[0020] C2. If the software system data needs to be upgraded, download the data package for update;
[0021] C3. If you need to upgrade the software system program, download the program package to update;
[0022] C4. If you need to upgrade the software system configuration, download the configuration package for update;
[0023] C5. Load the software startup program or startup script in the software running directory in the container instance.
[0024] Further: the downloading of the data package for updating specifically includes: decompressing the software system application data to a temporary directory in the container instance, and executing a data loading program or script in the temporary directory to load the data.
[0025] Further: the downloading of the program package for updating specifically includes: decompressing the software system program to the software running directory in the container instance.
[0026] Further: the downloading of the configuration package for updating specifically includes: decompressing the software system configuration to the software running configuration file storage directory under the software running directory in the container instance.
[0027] The beneficial effects of the present invention are as follows: compared with the existing software system publishing, deployment, and upgrading methods based on the container platform, the present invention proposes a method for separate publishing of container images and software system resources, integrated deployment of container images and software system resources, and independent upgrading of container images and software system resources based on a container image and software system resource separation mapping model, which solves the difficulties in applying container technology in multi-vendor collaboration and offline environments, improves the efficiency of software system research and development and publishing, reduces the energy overhead of the research and development environment, and can effectively promote the digitalization and service-oriented evolution of software systems. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Figure 1 A schematic diagram of the relationship between the software system version and the software system resources in the present invention;
[0029] Figure 2 This is a schematic diagram of the container image and software system resource separation mapping model in the present invention;
[0030] Figure 3 A schematic diagram of the association between container images and software systems for separate publishing indexes in the present invention;
[0031] Figure 4 This is a schematic diagram of the integrated deployment of container images and software systems in the present invention;
[0032] Figure 5 This is a schematic diagram of independent upgrade of container images in the present invention;
[0033] Figure 6 This is a schematic diagram of independent upgrade of the software system in the present invention. DETAILED DESCRIPTION
[0034] The specific implementation modes of the present invention are described below so that those skilled in the art can understand the present invention. However, it should be clear that the present invention is not limited to the scope of the specific implementation modes. For those of ordinary skill in the art, as long as various changes are within the spirit and scope of the present invention as defined and determined by the attached claims, these changes are obvious, and all inventions and creations utilizing the concept of the present invention are protected.
[0035] When a software system is released, it usually includes five parts: system environment, dependencies, programs, configuration, and data. After the rise of container technology, the system environment, dependencies, and programs are packaged together for release. However, the present invention packages the system environment and dependencies together, and separates the programs and releases them together with the configuration and data. Therefore, the relationship between the software system version and the software system resources based on this idea is as follows: Figure 1 shown.
[0036] Based on the above relationship, the container image (system environment, dependency) and software system resources (programs, configurations, data) separation mapping model is as follows: Figure 2As shown, a container image and software system resource separation mapping model includes a container image and software system resources that are mapped to each other, the container image includes a system environment and dependencies, the software system resources include programs, configurations and data, the container image is mapped to the program, and the program is also mapped to the configuration and data respectively.
[0037] In this model, the container image encapsulates the basic system environment and the libraries, tools, and basic applications that the software system depends on, and has a one-to-many relationship with the software system program; the software system program has a one-to-many relationship with its configuration and data, respectively.
[0038] Based on the container image and software system resource separation mapping model, the present invention designs a container image and software system separation publishing method: using file object storage method, respectively storing container images, software system resources (programs, configurations, data), setting "image", "program", "configuration", "data" four types of corresponding resources to upload, through the index association method, different storage container images, software system resources (programs, configurations, data) are combined to form a software system version, which is stored in the service resource warehouse. Based on the container image and software system resource separation mapping model, such as Figure 3 shown.
[0039] The specific process is as follows:
[0040] 1. Select the "Image" type to upload the container image, select the "Program" type to upload the software system program, select the "Configuration" type to upload the software system configuration, and select the "Data" type to upload the software system data;
[0041] 2. Create software vendor information;
[0042] 3. Create software name information and select associated software manufacturer information;
[0043] 4. Create software version information, select the associated software name information, and select the associated four types of resources: "Image", "Program", "Configuration", and "Data";
[0044] 5. Release the software system and provide access address to the outside world.
[0045] Based on the container image and software system resource separation mapping model, the present invention designs a container image and software system fusion deployment method: by formulating directory specifications and designing a lightweight boot program, the container image repository and software system resources (programs, configurations, data) are obtained from the service resource repository through over-the-air loading, such as Figure 4 shown.
[0046] Based on the original process of the container platform, a new lightweight boot program is added to load software system resources in the air and initialize and start the software system. The specific process is as follows:
[0047] 1. Parse the software system resource (program, configuration, data) parameter information passed into the container through the container instance resource object and determine whether it has been downloaded;
[0048] 2. If it is not downloaded, assemble the download address by passing in parameter information and download the corresponding software system resources (program, configuration, data);
[0049] 3. Decompress the software system application data to the / tmp directory in the container instance, and execute / tmp / loaddata to load the data;
[0050] 4. Unzip the software system program to the / opt / app directory in the container instance;
[0051] 5. Unzip the software system configuration to the / opt / app / persistent / conf directory in the container instance.
[0052] 6. Load the / opt / app / runapp startup program in the container instance.
[0053] Based on the container image and software system resource separation mapping model, the present invention designs a container image and software system independent upgrade method: by updating the resource objects created in the container platform, the container image repository and software system resource updates are triggered.
[0054] Container images can be upgraded independently. Figure 5 The independent upgrade process of the container image does not change the original process of upgrading the container instance through the container image of the container platform. Only after the container instance is upgraded through the container image, the newly added lightweight boot program determines whether the software system resource over-the-air loading process has been completed and starts the software system.
[0055] Software system independent upgrade such as Figure 5 The independent software system upgrade process updates the software system resources (programs, configurations, and data) defined in the container instance resource object on the container platform and transfers them to the container instance. The newly added lightweight boot program compares the version to determine the software system resources (programs, configurations, and data) that need to be updated, and then loads the software system resources from the service resource warehouse in the air and updates the software system's programs, configurations, or data. The specific process is as follows:
[0056] 1. Parse the software system resource (program, configuration, data) parameter information passed into the container through the container instance resource object and compare the version and determine the upgrade content;
[0057] 2. If you need to upgrade the software system data, download the data package to update:
[0058] ① Unzip the software system application data to the / tmp directory in the container instance, and execute / tmp / loaddata to load the data;
[0059] 3. If you need to upgrade the software system program, download the program package to update:
[0060] ① Unzip the software system program to the / opt / app directory in the container instance;
[0061] 4. If you need to upgrade the software system configuration, download the configuration package to update:
[0062] ① Unzip the software system configuration to the / opt / app / persistent / conf directory in the container instance.
[0063] 5. Load the / opt / app / runapp startup program in the container instance.
[0064] Compared with the existing software system publishing, deployment and upgrading methods based on container platforms, the present invention establishes a container image and software system resource separation mapping model, and based on the model proposes container image and software system resource separation publishing, container image and software system resource fusion deployment, and container image and software system resource independent upgrading methods, which solves the difficulties in applying container technology in multi-vendor collaboration and offline environments, improves the efficiency of software system research and development and publishing, reduces the energy overhead of the research and development environment, and can effectively promote the digitalization and service-oriented evolution of software systems.
Claims
1. A container image and software system resource upgrade method, characterized in that: The following steps are involved: A1. Select the image type to upload the container image, select the program type to upload the software system program, select the configuration type to upload the software system configuration, and select the data type to upload the software system data; A2. Create software vendor information; A3. Create software name information and select associated software manufacturer information; A4. Create software version information, find the associated software name information, and select four types of resources: associated image, program, configuration, and data; A5. Release the software system and provide access address to the outside world; B1. Parse the software system resource parameter information passed into the container through the container instance resource object, and determine whether it has been downloaded; B2. If it is not downloaded, assemble the download address by passing in parameter information and download the corresponding software system resources; B3. Decompress the software system application data to a temporary directory in the container instance, and execute the data loading program or script in the temporary directory to load the data; B4. Unzip the software system program to the software running directory in the container instance; B5. Decompress the software system configuration to the software running configuration file storage directory under the software running directory in the container instance; B6. Load the software startup program or startup script in the software running directory in the container instance; C1. Parse the software system resource parameter information passed into the container through the container instance resource object, compare the versions and determine the upgrade content; C2. If the software system data needs to be upgraded, download the data package for update; C3. If you need to upgrade the software system program, download the program package to update; C4. If you need to upgrade the software system configuration, download the configuration package for update; C5. Load the software startup program or startup script in the software running directory in the container instance.
2. The container image and software system resource upgrade method according to claim 1, characterized in that: The downloading of the data package for updating specifically includes: decompressing the software system application data to a temporary directory in the container instance, and executing a data loading program or script in the temporary directory to load the data.
3. The container image and software system resource upgrade method according to claim 1, characterized in that: The downloading of the program package for updating specifically includes: decompressing the software system program to the software running directory in the container instance.
4. The container image and software system resource upgrade method according to claim 1, characterized in that: The downloading of the configuration package for updating specifically includes: decompressing the software system configuration to a software running configuration file storage directory under a software running directory in the container instance.
Citation Information
Patent Citations
Virtual machine mirror image generating method and device based on software preinstallation in cloud environment
CN103092650A
Container platform-based application delivery method, container platform and application delivery system
CN106802807A
Container generation method, device and system, terminal and server
CN107797807A
SCADA system and protocol layer data configuration method
CN108306963A
Secondary mirroring-free publishing method for containerized JavaEE application server
CN111597014A
