Software automatic management and release method and device and electronic equipment
By building a continuous integration/continuous delivery module chain and dynamic configuration components, the problem of insufficient integration of the container release platform and container orchestration module is solved, and the container life cycle management is achieved is highly automated, and the efficiency and quality of software development, testing and deployment are improved. .
Patent Information
- Application Number
- CN202411443882.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-16
- Publication Date
- 2025-02-18
AI Technical Summary
The existing container publishing platform has limitations in integrating with mainstream container orchestration modules, which makes it difficult to achieve high automation of container life cycle management, increases the frequency and complexity of manual intervention, reduces operation and maintenance efficiency and increases the risk of errors. At the same time, the high learning threshold and complex configuration requirements of containerized technology have become obstacles to widespread adoption by enterprises, affecting the market competitiveness of products.
By building a continuous integration/continuous delivery module chain, integrating project management module, version control module, continuous integration module, automated testing module, containerized module, deployment module and security scanning module, we realize a fully automated process from code submission to application deployment. Dynamic configuration components define automated process details and generate YAML files to improve process configurability and transparency.
It realizes a fully automated process from code submission to application deployment, improves the efficiency and quality of software development, testing and deployment, reduces the frequency of manual intervention, enhances operation and maintenance efficiency, and reduces the risk of errors.
Smart Images

Figure CN119473375A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a method, device and electronic equipment for automatic management and publishing of software. Background Art
[0002] With the rapid development of information technology, cloud computing, microservice architecture and containerization technology (especially the widespread application of Docker and OCI standards) have become the core trends of modern software development, deployment and operation and maintenance. These technologies greatly simplify the deployment, expansion and maintenance of applications by providing a highly portable and lightweight runtime environment, accelerate the iteration speed of software products, and improve the flexibility and scalability of the system. However, while enjoying the benefits of these technologies, enterprises are also facing a series of new challenges, especially in the field of automated management and release of containerized applications.
[0003] First, although the container publishing platforms on the current market support the creation and deployment of containers, they have limitations in integrating with mainstream container orchestration modules (such as Kubernetes). This deficiency makes it difficult to achieve high automation of container lifecycle management (including start, stop, upgrade, rollback, etc.), which in turn increases the frequency and complexity of manual intervention, reduces operation and maintenance efficiency, and increases the risk of errors. Secondly, although containerization technology brings many advantages, its high learning threshold and complex configuration requirements have become obstacles to its widespread adoption by enterprises. For frequent code iteration and rapid release requirements, enterprises often find it difficult to quickly adapt and effectively manage, resulting in cumbersome and error-prone release processes, affecting the market competitiveness of products. Furthermore, the lack of project management functions: existing container release systems generally lack comprehensive project management functions, such as version control, task allocation, progress tracking, and team collaboration. The lack of these functions makes it difficult for enterprises to cope with multi-team collaboration, rapid iteration, and complex project management, increasing communication costs, reducing collaboration efficiency, and making it difficult to form an efficient and orderly development and release process.
[0004] Therefore, a method, device and electronic device for automatic management and release of software are proposed. Summary of the invention
[0005] This specification provides a method, device and electronic device for automated software management and release, which strengthens the underlying release capabilities through a continuous integration / continuous delivery module chain, starts the build and test process immediately after the code is submitted, provides rapid feedback, and helps developers discover and fix problems in a timely manner, thereby shortening the iteration cycle.
[0006] This specification provides a method for automatic management and release of software, including:
[0007] Build a continuous integration / continuous delivery module chain, which integrates a project management module, a version control module, a continuous integration module, an automated testing module, a containerization module, a deployment module, and a security scanning module;
[0008] The project management module obtains the code and its event-related work orders by monitoring the version control module, and publishes the code and its event-related work orders through the continuous integration module;
[0009] The continuous integration module pulls the latest code from the version control module, and generates configuration information in real time based on the latest code;
[0010] The security scanning module scans the latest code, generates a first security report and uploads it to the project management module;
[0011] The automated testing module performs automated testing based on the latest code. If the test passes, a script is built and compiled based on the latest code to obtain the application and its dependencies;
[0012] The containerization module packages the application and its dependencies into image data, and pushes the image template to the image warehouse;
[0013] The deployment module pulls the image data from the image repository, deploys the application in the image data to the target environment, and feeds back the deployment result to the continuous integration module;
[0014] When the deployment result is successful, the security scanning module scans the configuration information and static web pages, generates a second security report and uploads it to the project management module.
[0015] Optionally, the continuous integration module includes a dynamic configuration component, which can define all details of the automated process and output a YAML file containing the configuration information; the YAML file includes the image data, execution commands, and environment variables of each step of the release;
[0016] The fields of the dynamic configuration of the dynamic configuration component include: configuration information of the release component, files and directories that need to be mounted on the build host, the latest mirror address of the release plug-in, software information, project management information, and configuration information required for the temporary build environment.
[0017] Optionally, the dynamic configuration component uses SpringBoot as a development framework and uses the DAMO database for data storage.
[0018] Optional, including:
[0019] The version control module uses GitLab as the underlying code repository component. Before release, the deployment module automatically creates a temporary release branch based on dynamic configuration; when the operating environment successfully pulls the new code, the temporary release branch is deleted and the submission record of the temporary release branch is saved.
[0020] Optionally, the security scanning tool uses SonarQube as an underlying code scanning component, sets a quality threshold during release to check code quality, and determines whether to interrupt the release based on configuration information of the project management.
[0021] Optionally, the automated testing module includes a JUnit component.
[0022] This specification provides a device for automatic management and release of software, including:
[0023] Build a continuous integration / continuous delivery module chain, which integrates a project management module, a version control module, a continuous integration module, an automated testing module, a containerization module, a deployment module, and a security scanning module;
[0024] The project management module is used to monitor the version control module to obtain the code and its event-related work orders, and publish the code and its event-related work orders through the continuous integration module;
[0025] The continuous integration module is used to pull the latest code from the version control module and generate configuration information in real time based on the latest code;
[0026] The security scanning module is used to scan the latest code, generate a first security report and upload it to the project management module;
[0027] The automated testing module is used to perform automated testing based on the latest code. If the test passes, a script is built and compiled based on the latest code to obtain the application and its dependencies;
[0028] The containerization module is used to package the application and its dependencies into image data and push the image template to the image warehouse;
[0029] The deployment module is used to pull the image data from the image repository, deploy the application in the image data to the target environment, and feed back the deployment result to the continuous integration module; when the deployment result is successful, the security scanning module scans the configuration information and static web pages, generates a second security report and uploads it to the project management module.
[0030] Optionally, the continuous integration module includes a dynamic configuration component, which can define all details of the automated process and output a YAML file containing the configuration information; the YAML file includes the image data, execution commands, and environment variables of each step of the release;
[0031] The fields of the dynamic configuration of the dynamic configuration component include: configuration information of the release component, files and directories that need to be mounted on the build host, the latest mirror address of the release plug-in, software information, project management information, and configuration information required for the temporary build environment.
[0032] Optionally, the dynamic configuration component uses SpringBoot as a development framework and uses the DAMO database for data storage.
[0033] Optional, including:
[0034] The version control module uses GitLab as the underlying code repository component. Before release, the deployment module automatically creates a temporary release branch based on dynamic configuration; when the operating environment successfully pulls the new code, the temporary release branch is deleted and the submission record of the temporary release branch is saved.
[0035] Optionally, the security scanning tool uses SonarQube as an underlying code scanning component, sets a quality threshold during release to check code quality, and determines whether to interrupt the release based on configuration information of the project management.
[0036] Optionally, the automated testing module includes a JUnit component.
[0037] This specification also provides an electronic device, wherein the electronic device includes:
[0038] processor; and,
[0039] A memory storing computer executable instructions, which when executed cause the processor to perform any of the above methods.
[0040] The present specification also provides a computer-readable storage medium, wherein the computer-readable storage medium stores one or more programs, and when the one or more programs are executed by a processor, any of the above methods is implemented.
[0041] In the present invention, multiple modules such as project management, version control, continuous integration, automated testing, containerization, deployment and security scanning are integrated to build an efficient continuous integration / continuous delivery module chain, realizing a fully automated process from code submission to application deployment. The automation details are flexibly defined and YAML files are generated through dynamic configuration components, thereby improving the configurability and transparency of the process. At the same time, GitLab is used for version control to ensure the security and traceability of the code; SonarQube is used for code quality inspection to ensure the release quality; JUnit components are also integrated for automated testing, and containerization technology is used to improve the consistency and portability of deployment, thereby greatly improving the efficiency and quality of software development, testing and deployment. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0043] Figure 1 A schematic diagram of the principle of a method for automatic software management and release provided in an embodiment of this specification;
[0044] Figure 2 A use case diagram of dynamic publishing configuration provided in the embodiments of this specification;
[0045] Figure 3 An integrated project management use case diagram provided for the embodiments of this specification;
[0046] Figure 4 A schematic diagram of the structure of a device for automatic management and release of software provided in an embodiment of this specification;
[0047] Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of this specification;
[0048] Figure 6 A schematic diagram of a computer-readable medium provided for an embodiment of this specification. DETAILED DESCRIPTION
[0049] The following description is used to disclose the present invention so that those skilled in the art can implement the present invention. The preferred embodiments described below are only examples, and those skilled in the art can think of other obvious variations. The basic principles of the present invention defined in the following description can be applied to other embodiments, variations, improvements, equivalents, and other technical solutions that do not deviate from the spirit and scope of the present invention.
[0050] The following is combined with Figure 1-6 The exemplary embodiments of the present invention are described more fully. However, the exemplary embodiments can be implemented in various forms, and it should not be understood that the present invention is limited to the embodiments set forth herein. On the contrary, providing these exemplary embodiments can make the present invention more comprehensive and complete, and it is more convenient to fully convey the inventive concept to those skilled in the art. The same reference numerals in the figures represent the same or similar elements, components or parts, and thus their repeated description will be omitted.
[0051] Under the premise of being consistent with the technical concept of the present invention, the features, structures, characteristics or other details described in a specific embodiment do not exclude that they can be combined in one or more other embodiments in a suitable manner.
[0052] In the description of specific embodiments, the features, structures, characteristics or other details described in the present invention are intended to enable those skilled in the art to fully understand the embodiments. However, it does not exclude that those skilled in the art can practice the technical solutions of the present invention without one or more of the specific features, structures, characteristics or other details.
[0053] The flowcharts shown in the accompanying drawings are only exemplary and do not necessarily include all the contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps can be decomposed, and some operations / steps can be combined or partially combined, so the actual execution order may change according to actual conditions.
[0054] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities may be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.
[0055] The term "and / or" or "and / or" includes all combinations of any one or more of the associated listed items.
[0056] Figure 1 A schematic diagram of the principle of a method for automatic management and release of software provided in an embodiment of this specification, the method may include:
[0057] Build a continuous integration / continuous delivery module chain, which integrates a project management module, a version control module, a continuous integration module, an automated testing module, a containerization module, a deployment module, and a security scanning module;
[0058] In a specific implementation of the present specification, the continuous integration / continuous delivery module chain includes a CI / CD chain, which reduces manual intervention, accelerates code building, testing and deployment, and shortens the delivery cycle; automated testing and deployment reduce the risk of human error and improve software quality; the CI / CD process provides fast feedback, enabling developers to quickly identify and fix problems.
[0059] S110: The project management module obtains the code and the event-related work order by monitoring the version control module, and publishes the code and the event-related work order through the continuous integration module;
[0060] In a specific implementation of this specification, the project management module includes an integrated R&D and operation platform for managing project tasks, issues, requirements and defects, tracking project progress and work assignments of team members, and providing reports and dashboards so that project managers and team members can understand the project status.
[0061] After the developer finishes writing the code, he / she uses the version control system (such as Git) to submit the code. When submitting the code, the developer adds the work order number or description information associated with this code submission in the remarks information. The R&D and Operation Integration Platform can obtain code submission events in real time based on the hook mechanism of the version control system, such as Git's pre-commit, post-commit, push and other hooks.
[0062] S120: the continuous integration module pulls the latest code from the version control module, and generates configuration information in real time based on the latest code;
[0063] In a specific implementation of the present specification, the continuous integration module includes a publishing platform for isolating and reusing the environment through container technology, automatically triggering build tasks, and performing testing and deployment operations after the build is completed.
[0064] The release platform pulls the latest code from the continuous integration module through a hook or polling mechanism, and generates build, test, deployment, scan and other configuration information in real time through dynamic configuration management components (such as Nacos, Apollo, etc.), which greatly improves the efficiency and accuracy of software release and reduces the risk of human error.
[0065] S140: The security scanning module scans the latest code, generates a first security report and uploads it to the project management module;
[0066] In the specific implementation of this specification, the security scanning module includes the open source SonarQube and the commercial NetShen. SonarQube can detect whether the source code follows specific coding standards. By integrating tools such as PMD, CheckStyle, FindBugs, etc., SonarQube can check the naming standards, comment standards, code styles, etc. in the code to ensure the readability and consistency of the code. In addition to code specification checking, SonarQube can also identify potential security vulnerabilities in the code. It can detect common security threats such as SQL injection, cross-site scripting (XSS), command injection, etc. Through static code analysis technology, SonarQube can analyze security vulnerabilities in the code without running the code, helping developers to find and fix these problems before the code is submitted. SonarQube can also evaluate the complexity of the code and detect duplicate code. Excessive code complexity will reduce the readability and maintainability of the code, while duplicate code may lead to increased maintenance costs and potential security risks. Through SonarQube, developers can identify and refactor these parts to improve the overall quality of the code. SonarQube can be easily integrated into the continuous integration (CI) process to achieve automated quality inspection after code submission. This helps developers find and fix problems in a timely manner, preventing them from accumulating in the production environment.
[0067] NetShen can conduct a comprehensive security scan of web applications deployed on the server, identify and report possible security vulnerabilities. These vulnerabilities may include SQL injection, cross-site scripting (XSS), cross-site request forgery (CSRF), etc. In addition to code-level security scanning, NetShen may also audit the server configuration of the web application to ensure the security of the server configuration. This includes checking whether the server has enabled the necessary security measures, whether there are unnecessary services or ports open, etc.
[0068] The security scanning module provides valuable security information to the project management team by scanning the latest code and generating security reports. Uploading the security reports to the project management module further promotes collaboration and communication between project teams, helping to ensure the security and stability of the project.
[0069] S150: the automated testing module performs automated testing based on the latest code. If the test passes, a script is constructed and compiled based on the latest code to obtain an application and its dependencies.
[0070] Optionally, the automated testing module includes a JUnit component.
[0071] In the specific implementation of this specification, the JUnit component provides a convenient way to write, execute and verify test cases, which helps to ensure the quality and stability of the code.
[0072] The automated testing module performs automated testing based on the latest code, and builds and compiles scripts after the test passes to obtain the application and its dependencies. This process ensures the quality and stability of the code, laying a solid foundation for subsequent deployment and distribution.
[0073] S160: The containerization module packages the application and its dependencies into image data, and pushes the image template to the image repository;
[0074] In a specific implementation of this specification, the containerization module includes the open source Docker, which is used to package applications into containers, achieve rapid deployment of applications, and ensure a consistent environment.
[0075] S170: The deployment module pulls the image data from the image repository, deploys the application in the image data to the target environment, and feeds back the deployment result to the continuous integration module;
[0076] In a specific implementation of this specification, the deployment module includes a space-based platform for deploying applications to a test environment or a production environment to achieve automated deployment.
[0077] The Tianji platform successfully pulled the application image from the image repository and deployed it to the target environment. At the same time, it also fed back the deployment results to the continuous integration module, providing strong support for the entire software development and operation and maintenance process.
[0078] S180: When the deployment result is successful, the security scanning module scans the configuration information and static web pages, generates a second security report and uploads it to the project management module.
[0079] In the specific implementation of this specification, each step of the release platform is packaged into independent plug-ins, which ensure the universal applicability and consistency of the temporary environment. Independent plug-ins are implemented by creating custom Docker images. When the release process needs to be changed, the release platform does not need to be updated as a whole, but simply updates or adds the corresponding plug-ins. In this way, the release platform can easily integrate new tools and services, thereby maintaining its flexibility and scalability.
[0080] Optionally, the continuous integration module includes a dynamic configuration component, which can define all details of the automated process and output a YAML file containing the configuration information; the YAML file includes the image data, execution commands, and environment variables of each step of the release;
[0081] The fields of the dynamic configuration of the dynamic configuration component include: configuration information of the release component, files and directories that need to be mounted on the build host, the latest mirror address of the release plug-in, software information, project management information, and configuration information required for the temporary build environment.
[0082] In the specific implementation of this specification, software information is pre-entered by the configuration personnel; project management information is set by the release personnel when executing the software release; other release configuration information is provided by the release platform. By assembling these three types of information, the release configuration can be dynamically generated. By isolating the software information and the release configuration information, the configuration personnel no longer need to understand the release logic. Even if the release process or the underlying architecture changes, the configuration personnel only need to provide the software information of the project itself.
[0083] Optionally, the dynamic configuration component uses SpringBoot as a development framework and uses the DAMO database for data storage.
[0084] In the specific implementation of this specification, SpringBoot follows the concept of "habit is better than configuration" and reduces the configuration workload in the development process through a large number of default configurations, allowing developers to focus more on the implementation of business logic. SpringBoot applications can be packaged into independent executable jar packages without being deployed to external containers, simplifying the deployment process. SpringBoot provides a wealth of starter dependencies. Developers only need to introduce the corresponding starter in the project, and SpringBoot will automatically configure the required components, greatly improving development efficiency. SpringBoot provides an Actuator module for monitoring and managing applications, including health checks, metric information collection, etc., which is convenient for developers to monitor and optimize the performance of applications in real time.
[0085] DAMO Database is a domestic database with independent intellectual property rights. It supports multiple operating systems and platforms, and provides strong support for the construction of domestic information systems. DAMO Database adopts advanced database architecture and optimization technology, which can provide efficient data storage and query performance to meet the needs of large-scale data processing. DAMO Database provides a rich data backup and recovery mechanism, as well as high-availability cluster solutions to ensure data reliability and business continuity. DAMO Database has high compatibility with mainstream databases in terms of SQL standards, data types, functions, etc., which is convenient for developers to migrate and integrate.
[0086] In the dynamic configuration component, SpringBoot, as a development framework, is responsible for providing the application's infrastructure and automatic assembly functions. By defining a series of beans and configuration classes, SpringBoot can manage the various components and dependencies of the application. At the same time, SpringBoot also provides a wealth of annotations and configuration methods, allowing developers to flexibly define the behavior and characteristics of the application. In terms of data storage, the dynamic configuration component uses the DAMO database to store configuration information. This configuration information may include the configuration of the release component, the mount information of the build host, the mirror address of the release plug-in, etc. By defining the appropriate database table structure and index strategy, the DAMO database can efficiently store and query this data. In addition, the DAMO database also supports advanced functions such as transaction processing and concurrency control to ensure the consistency and integrity of the configuration information.
[0087] Optional, including:
[0088] The version control module uses GitLab as the underlying code repository component. Before release, the deployment module automatically creates a temporary release branch based on dynamic configuration; when the operating environment successfully pulls the new code, the temporary release branch is deleted and the submission record of the temporary release branch is saved.
[0089] In the specific implementation of this specification, before release, the deployment module will rely on the powerful function of the dynamic configuration component to automatically create a temporary release branch, allowing an independent and verifiable environment to be prepared for the upcoming release without interfering with the main branch or other stable branches. On the one hand, it reduces the impact on other development work during the release process; on the other hand, it also provides a more convenient way to roll back or track problems.
[0090] When the runtime environment successfully pulls the new code from the temporary release branch and confirms that it is correct, the deployment module will immediately delete the temporary branch. The purpose of this operation is to clean up useless branches, keep the code repository tidy, and prevent possible version confusion in the future. However, although the temporary branch is deleted, its submission records will be carefully preserved. These records are like the historical archives of the project, providing a basis for tracking version changes and auditing code changes.
[0091] Optionally, the security scanning tool uses SonarQube as an underlying code scanning component, sets a quality threshold during release to check code quality, and determines whether to interrupt the release based on configuration information of the project management.
[0092] In the specific implementation of this specification, when the code is submitted to the release process, SonarQube will use its powerful scanning capabilities to conduct a meticulous analysis of the code. It will not only check for potential errors and vulnerabilities in the code, but also conduct a comprehensive assessment of the structure, readability, and performance of the code. By setting a quality threshold, it is ensured that only code that meets or exceeds this standard can smoothly enter the subsequent release phase. In addition, the security scanning tool also fully considers the actual needs of project management. It will intelligently determine whether to interrupt the release based on the configuration information of project management. If the code quality does not meet the preset standards, or there are serious security vulnerabilities, the tool will immediately issue a warning and has the right to interrupt the release process based on the configuration information, thereby preventing the problem code from entering the production environment and effectively ensuring the stability and security of the project.
[0093] The publishing system mainly includes the following functions:
[0094] ①CI / CD tool integration
[0095] ②Dynamic configuration management
[0096] ③Containerization and orchestration
[0097] ④Project management tool integration
[0098] ⑤ Intelligent scheduling and release strategy
[0099] ⑥Project code quality control
[0100] Specifically, Figure 2 As shown in the figure, the process of dynamically publishing configuration includes:
[0101] ①Configuration personnel pre-enter the software configuration through the configuration web page.
[0102] ② The configuration web page will save the configuration to the database
[0103] ③ The publisher executes the software release on the release web page.
[0104] ④The published web page calls the dynamic configuration module and reads the corresponding software configuration.
[0105] ⑤The dynamic configuration module generates release configuration based on the latest release environment.
[0106] like Figure 3 As shown, the process of integrated project management includes:
[0107] ① The publisher releases the software through the publishing web page.
[0108] ②Publish tasks associated with the project management system on the web page and update the task status.
[0109] ③ The release web page creates a temporary release branch through the code warehouse component.
[0110] ④The code warehouse component notifies the publishing component of the event.
[0111] ⑤ Release components and check code quality through code scanning components.
[0112] ⑥The code scanning component notifies the project management system of the scanning report, updates the task, and determines whether to interrupt the release based on the quality threshold configuration.
[0113] In the present invention, multiple modules such as project management, version control, continuous integration, automated testing, containerization, deployment and security scanning are integrated to build an efficient continuous integration / continuous delivery module chain, realizing a fully automated process from code submission to application deployment. The automation details are flexibly defined and YAML files are generated through dynamic configuration components, thereby improving the configurability and transparency of the process. At the same time, GitLab is used for version control to ensure the security and traceability of the code; SonarQube is used for code quality inspection to ensure the release quality; JUnit components are also integrated for automated testing, and containerization technology is used to improve the consistency and portability of deployment, thereby greatly improving the efficiency and quality of software development, testing and deployment.
[0114] Figure 4 A schematic diagram of a device for automatic software management and release provided in an embodiment of this specification, the device may include:
[0115] Constructing a continuous integration / continuous delivery module chain, wherein the continuous integration / continuous delivery module chain integrates a project management module 10, a version control module 20, a continuous integration module 30, an automated testing module 40, a containerization module 50, a deployment module 60, and a security scanning module 70;
[0116] The project management module 10 is used to monitor the version control module 20 to obtain the code and its event-related work orders, and publish the code and its event-related work orders through the continuous integration module 30;
[0117] The continuous integration module 30 is used to pull the latest code from the version control module 20 and generate configuration information in real time based on the latest code;
[0118] The security scanning module 70 is used to scan the latest code and generate a first security report to upload to the project management module 10;
[0119] The automated testing module 40 is used to perform automated testing based on the latest code. If the test passes, a script is built and compiled based on the latest code to obtain the application and its dependencies;
[0120] The containerization module 50 is used to package the application and its dependencies into image data and push the image template to the image repository;
[0121] The deployment module 60 is used to pull the image data from the image repository, deploy the application in the image data to the target environment, and feed back the deployment result to the continuous integration module 30; when the deployment result is successful, the security scanning module 70 scans the configuration information and static web pages, generates a second security report and uploads it to the project management module 10.
[0122] Optionally, the continuous integration module 30 includes a dynamic configuration component, which can define all details of the automation process and output a YAML file containing the configuration information; the YAML file includes the image data, execution commands, and environment variables of each step of the release;
[0123] The fields of the dynamic configuration of the dynamic configuration component include: configuration information of the release component, files and directories that need to be mounted on the build host, the latest mirror address of the release plug-in, software information, project management information, and configuration information required for the temporary build environment.
[0124] Optionally, the dynamic configuration component uses SpringBoot as a development framework and uses the DAMO database for data storage.
[0125] Optional, including:
[0126] The version control module 20 uses GitLab as the underlying code repository component. Before publishing, the deployment module automatically creates a temporary publishing branch based on dynamic configuration; when the operating environment successfully pulls the new code, the temporary publishing branch is deleted and the submission record of the temporary publishing branch is saved.
[0127] Optionally, the security scanning tool uses SonarQube as an underlying code scanning component, sets a quality threshold during release to check code quality, and determines whether to interrupt the release based on configuration information of the project management.
[0128] Optionally, the automated testing module 40 includes a JUnit component.
[0129] The functions of the device in the embodiment of the present invention have been described in the above method embodiment, so for details not provided in the description of this embodiment, please refer to the relevant description in the above embodiment, and no further description will be given here.
[0130] Based on the same inventive concept, an embodiment of this specification also provides an electronic device.
[0131] The following describes an electronic device embodiment of the present invention, which can be regarded as a specific physical implementation of the method and device embodiments of the present invention. The details described in the electronic device embodiment of the present invention should be regarded as a supplement to the above method or device embodiments; details not disclosed in the electronic device embodiment of the present invention can be implemented with reference to the above method or device embodiments.
[0132] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this specification. Figure 5 The electronic device 300 according to the embodiment of the present invention is described. Figure 5 The electronic device 300 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0133] like Figure 5 As shown, the electronic device 300 is in the form of a general computing device. The components of the electronic device 300 may include, but are not limited to: at least one processing unit 310, at least one storage unit 320, a bus 330 connecting different system components (including the storage unit 320 and the processing unit 310), a display unit 340, etc.
[0134] The storage unit stores program codes, which can be executed by the processing unit 310, so that the processing unit 310 performs the steps according to various exemplary embodiments of the present invention described in the above processing method section of this specification. For example, the processing unit 310 can perform the following steps: Figure 1 Steps shown.
[0135] The storage unit 320 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 3201 and / or a cache memory unit 3202 , and may further include a read-only memory unit (ROM) 3203 .
[0136] The storage unit 320 may also include a program / utility module 3204 having a set (at least one) of program modules 3205, such program modules 3205 including but not limited to: an operating system, one or more application programs, other program modules and program data, each of which or some combination may include the implementation of a network environment.
[0137] Bus 330 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0138] The electronic device 300 may also communicate with one or more external devices 400 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), one or more devices that enable viewers to interact with the electronic device 300, and / or any device that enables the electronic device 300 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed through an input / output (I / O) interface 350. Furthermore, the electronic device 300 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 360. The network adapter 360 may communicate with other modules of the electronic device 300 through the bus 330. It should be understood that although Figure 5 Not shown, other hardware and / or software modules may be used in conjunction with the electronic device 300, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0139] Through the description of the above implementation methods, it is easy for those skilled in the art to understand that the exemplary embodiments described in the present invention can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation method of the present invention can be embodied in the form of a software product, which can be stored in a computer-readable storage medium (which can be a CD-ROM, USB flash drive, mobile hard disk, etc.) or on a network, including a number of instructions to enable a computing device (which can be a personal computer, server, or network device, etc.) to execute the above method according to the present invention. When the computer program is executed by a data processing device, the computer-readable medium can implement the above method of the present invention, that is: Figure 1 The method shown.
[0140] Figure 6 A schematic diagram of a computer-readable medium provided in accordance with an embodiment of the present specification.
[0141] accomplish Figure 1The computer program of the method shown can be stored on one or more computer readable media. The computer readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, but not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0142] The computer readable storage medium may include a data signal propagated in a baseband or as part of a carrier wave, wherein a readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The readable storage medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by an instruction execution system, an apparatus, or a device or used in combination with it. The program code contained on the readable storage medium may be transmitted with any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the above.
[0143] Program code for performing the operations of the present invention may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the viewer computing device, partially on the viewer device, as a stand-alone software package, partially on the viewer computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving a remote computing device, the remote computing device may be connected to the viewer computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., via the Internet using an Internet service provider).
[0144] In summary, the present invention can be implemented in hardware, or in a software module running on one or more processors, or in a combination thereof. It should be understood by those skilled in the art that general data processing devices such as microprocessors or digital signal processors (DSPs) can be used in practice to implement some or all of the functions of some or all of the components in the embodiments of the present invention. The present invention can also be implemented as a device or apparatus program (e.g., a computer program and a computer program product) for executing part or all of the methods described herein. Such a program implementing the present invention can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.
[0145] The specific embodiments described above further describe the purpose, technical solutions and beneficial effects of the present invention in detail. It should be understood that the present invention is not inherently related to any specific computer, virtual device or electronic device, and various general devices can also implement the present invention. The above description is only a specific embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
[0146] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from other embodiments.
[0147] The above is only an embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.
Claims
1. A method for automated software management and release, characterized in that: include: Build a continuous integration / continuous delivery module chain, which integrates a project management module, a version control module, a continuous integration module, an automated testing module, a containerization module, a deployment module, and a security scanning module; The project management module obtains the code and its event-related work orders by monitoring the version control module, and publishes the code and its event-related work orders through the continuous integration module; The continuous integration module pulls the latest code from the version control module, and generates configuration information in real time based on the latest code; The security scanning module scans the latest code, generates a first security report and uploads it to the project management module; The automated testing module performs automated testing based on the latest code. If the test passes, a script is built and compiled based on the latest code to obtain the application and its dependencies; The containerization module packages the application and its dependencies into image data, and pushes the image template to the image warehouse; The deployment module pulls the image data from the image repository, deploys the application in the image data to the target environment, and feeds back the deployment result to the continuous integration module; When the deployment result is successful, the security scanning module scans the configuration information and static web pages, generates a second security report and uploads it to the project management module.
2. The method for automatic software management and release according to claim 1, characterized in that: The continuous integration module includes a dynamic configuration component, which can define all details of the automation process and output a YAML file containing the configuration information; the YAML file includes the image data, execution commands, and environment variables of each step of the release; The fields of the dynamic configuration of the dynamic configuration component include: configuration information of the release component, files and directories that need to be mounted on the build host, the latest mirror address of the release plug-in, software information, project management information, and configuration information required for the temporary build environment.
3. The method for automatic software management and release as claimed in claim 2, characterized in that: The dynamic configuration component uses SpringBoot as the development framework and uses the DAMO database for data storage.
4. The method for automatic software management and release according to claim 1, characterized in that: include: The version control module uses GitLab as the underlying code repository component, and the deployment module automatically creates a temporary release branch based on dynamic configuration before release; When the operating environment successfully pulls the new code, the temporary release branch is deleted and the submission record of the temporary release branch is saved.
5. The method for automatic software management and release as claimed in claim 4, characterized in that: include: The security scanning tool uses SonarQube as the underlying code scanning component, sets a quality threshold to check the code quality during release, and determines whether to interrupt the release based on the configuration information of the project management.
6. The method for automatic software management and release according to claim 1, characterized in that: The automated testing module includes a JUnit component.
7. A device for automatic management and release of software, characterized in that: include: Build a continuous integration / continuous delivery module chain, which integrates a project management module, a version control module, a continuous integration module, an automated testing module, a containerization module, a deployment module, and a security scanning module; The project management module is used to monitor the version control module to obtain the code and its event-related work orders, and publish the code and its event-related work orders through the continuous integration module; The continuous integration module is used to pull the latest code from the version control module and generate configuration information in real time based on the latest code; The security scanning module is used to scan the latest code, generate a first security report and upload it to the project management module; The automated testing module is used to perform automated testing based on the latest code. If the test passes, a script is built and compiled based on the latest code to obtain the application and its dependencies; The containerization module is used to package the application and its dependencies into image data and push the image template to the image warehouse; The deployment module is used to pull the image data from the image repository, deploy the application in the image data to the target environment, and feed back the deployment result to the continuous integration module; When the deployment result is successful, the security scanning module scans the configuration information and static web pages, generates a second security report and uploads it to the project management module.
8. An electronic device, wherein: The electronic device includes: processor; and, A memory storing computer executable instructions which, when executed, cause the processor to perform the method according to any one of claims 1-6.
9. A computer-readable storage medium, wherein: The computer-readable storage medium stores one or more programs, and when the one or more programs are executed by a processor, the method of any one of claims 1 to 6 is implemented.