CN111611054A - Application deployment method and device - Google Patents

Application deployment method and device Download PDF

Info

Publication number
CN111611054A
CN111611054A CN202010435078.1A CN202010435078A CN111611054A CN 111611054 A CN111611054 A CN 111611054A CN 202010435078 A CN202010435078 A CN 202010435078A CN 111611054 A CN111611054 A CN 111611054A
Authority
CN
China
Prior art keywords
management system
container management
image file
edge
embedded equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010435078.1A
Other languages
Chinese (zh)
Other versions
CN111611054B (en
Inventor
胡建锋
朱少武
阮兆银
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Wangsu Science and Technology Co Ltd
Original Assignee
Wangsu Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Wangsu Science and Technology Co Ltd filed Critical Wangsu Science and Technology Co Ltd
Priority to CN202010435078.1A priority Critical patent/CN111611054B/en
Publication of CN111611054A publication Critical patent/CN111611054A/en
Application granted granted Critical
Publication of CN111611054B publication Critical patent/CN111611054B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • G06F8/63Image based installation; Cloning; Build to order
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5061Partitioning or combining of resources
    • G06F9/5072Grid computing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45591Monitoring or debugging support

Abstract

The embodiment of the invention discloses an application deployment method and device, wherein the method comprises the following steps: the embedded equipment is accessed to the edge container management system; the embedded equipment is a working node of the edge container management system; the embedded equipment receives the mirror image file sent by the edge container management system; the mirror image file is obtained by the edge container management system from the central container management system; and the embedded equipment deploys the image file through a built-in container engine. Thus, the purpose of deploying applications in the embedded device is achieved.

Description

Application deployment method and device
Technical Field
The invention relates to the field of edge computing, in particular to an application deployment method and device.
Background
As edge computing technology matures, devices used for edge computing are also more represented as devices with embedded systems, ARM architectures.
The edge calculation is a distributed open platform which integrates network, calculation, storage and application core capabilities at the edge side of a network close to an object or a data source, edge intelligent services are provided nearby, and key requirements of industry digitization on aspects of agile connection, real-time business, data optimization, application intelligence, safety, privacy protection and the like are met. It can be used as a bridge to connect physical and digital worlds, enabling intelligent assets, intelligent gateways, intelligent systems and intelligent services. The application of the internet of things industry is the push for edge computing.
An embedded system, which is a special computer system, is defined by Institute of Electrical and Electronics Engineers (IEEE) as a means for controlling, monitoring, or assisting in the operation of machines and equipment; the commonly accepted definition of the embedded system in China is a special computer system which takes application as a center, is based on computer technology, can cut software and hardware and adapts to strict requirements of the application system on functions, reliability, cost, volume, power consumption and the like; the embedded system is defined by the application object, is a complex of software and hardware, and can also cover auxiliary devices such as machines. An embedded system, which is part of a device or apparatus, is an embedded processor control board with control programs stored in ROM. In fact, all devices with digital interfaces, such as watches, microwave ovens, video recorders, automobiles, etc., use embedded systems, some of which also contain operating systems, but most of which implement the entire control logic from a single program. The ARM architecture, formerly known as the Advanced Reduced Instruction Set Machine (Advanced RISC Machine), is a 32-bit Reduced Instruction Set Computing (RISC) processor architecture.
However, it has become a challenge how to simply and conveniently deploy applications on embedded devices.
Disclosure of Invention
The embodiment of the invention provides an application deployment method and device, which are used for realizing the aim of simply and conveniently deploying applications on embedded equipment.
In a first aspect, an embodiment of the present invention provides an application deployment method, where the method includes: the embedded equipment is accessed to the edge container management system; the embedded equipment is a working node of the edge container management system; the embedded equipment receives the mirror image file sent by the edge container management system; the image file is acquired by the edge container management system from a central container management system; and the embedded equipment deploys the image file through a built-in container engine.
Based on the scheme, the embedded device is accessed to the edge container management system and becomes a working node in the edge container management system after registration, the central container management system provides the image files required by the embedded device, the edge container management system performs application deployment and management on the embedded device, and the container engine built in the embedded device finally completes the deployment of the image files.
In a possible implementation method, the accessing of the embedded device to the edge container management system includes: after the embedded equipment is started, the embedded equipment establishes connection with the edge container management system through a built-in connection agent; and the embedded equipment is registered as a working node of the edge container management system through a built-in container agent.
Based on the scheme, after the embedded equipment is started, connection is established with the edge container management system through a built-in connection agent of the embedded equipment; after the connection between the embedded device and the edge container management system is realized, the embedded device is registered in the edge container management system through the built-in container agent, so that the embedded device becomes a working node, and the management of the edge container management system on the embedded device is conveniently realized in the later period.
In one possible implementation method, the image file is a monitoring application; the embedded device deploys the image file through a built-in container engine, and the method comprises the following steps: the embedded equipment generates a monitoring object corresponding to the mirror image file through the container engine; the monitoring object is used for monitoring the embedded equipment.
Based on the scheme, the image file of the monitoring application is deployed to any embedded device, and the embedded device is monitored through the created monitoring object.
In a possible implementation method, after the embedded device deploys the image file through a built-in container engine, the method further includes: the embedded equipment determines that version upgrading information of the image file exists, wherein the version upgrading information comprises an address of an upgrading version corresponding to the image file in the central container management system; and the embedded equipment carries out version upgrading on the image file according to the address of the upgrading version corresponding to the image file in the central container management system.
Based on the scheme, when the version of the image file in the embedded equipment is upgraded, the address of the upgraded version corresponding to the image file in the central container management system is obtained from the version upgrading information of the image file, so that the version of the image file is upgraded. The scheme simplifies the version upgrading step of the application in the embedded device.
In a second aspect, an embodiment of the present invention provides an application deployment method, where the method includes: the edge container management system acquires the mirror image file from the central container management system; the edge container management system determines embedded equipment corresponding to the mirror image file; the embedded equipment is a working node registered in the edge container management system; the edge container management system sends the mirror image file to the embedded equipment; the embedded device is used for deploying the image file through a built-in container engine.
Based on the scheme, the edge container management system determines the embedded equipment corresponding to the image file according to the image file acquired from the central container management system, wherein the embedded equipment is a working node registered in the edge container management system, the edge container management system sends the image file to the embedded equipment, and then the embedded equipment deploys the image file through a built-in container engine.
In a possible implementation method, before the edge container management system obtains the image file from the central container management system, the method further includes: the edge container management system establishes connection with the embedded equipment through a connection agent built in the embedded equipment; and the edge container management system determines the embedded equipment as a working node of the edge container management system through a container agent built in the embedded equipment.
Based on the scheme, before the edge container management system acquires the image file from the central container management system, a connection channel between the edge container management system and the embedded device needs to be established, specifically: the edge container management system establishes connection with the embedded device through a connection agent built in the embedded device, and determines the embedded device as a working node of the edge container management system through a container agent built in the embedded device.
In one possible implementation, the image file is a monitoring application; the monitoring application is used for generating a monitoring object of the embedded equipment; the method further comprises the following steps: and the edge container management system receives the monitoring data reported by the monitoring object of the embedded equipment and reports the monitoring data to the central container management system.
Based on the scheme, deploying the monitoring application in the embedded equipment to generate a monitoring object of the embedded equipment; and the edge container management system receives the monitoring data reported by the monitoring object of the embedded equipment and forwards the monitoring data to the central container management system, so that the central container management system monitors the equipment state of the embedded equipment.
In one possible implementation, the edge container management system further includes a monitoring agent; the method further comprises the following steps: the edge container management system sends own state data to the central container management system through the monitoring agent; and the central container management system is used for managing the edge container management system according to the state data.
Based on the scheme, the monitoring agent is deployed in the edge container management system, so that the edge container management platform can send own state data to the central container management system through the monitoring agent, and the aim of unified management of the central container management system on the edge container management system is fulfilled.
In one possible implementation, the image file is implemented by persistent integration/persistent deployment of the central container management system.
Based on the scheme, the image file is generated in the central container management system in a continuous integration/continuous deployment mode, and an extremely convenient implementation mode is provided for deployment of the application and later update of the application version.
In a third aspect, an embodiment of the present invention provides an application deployment apparatus, where the apparatus includes: the access unit is used for accessing the edge container management system; the embedded equipment is a working node of the edge container management system; the receiving unit is used for receiving the mirror image file sent by the edge container management system; the image file is acquired by the edge container management system from a central container management system; and the deployment unit is used for deploying the image file through a built-in container engine.
Based on the scheme, the embedded device is accessed to the edge container management system and becomes a working node in the edge container management system after registration, the central container management system provides the image files required by the embedded device, the edge container management system performs application deployment and management on the embedded device, and the container engine built in the embedded device finally completes the deployment of the image files.
In a possible implementation method, the access unit is specifically configured to: after the system is started, a connection is established with the edge container management system through a built-in connection agent; and registering the edge container management system as a working node of the edge container management system through a built-in container agent.
Based on the scheme, after the embedded equipment is started, connection is established with the edge container management system through a built-in connection agent of the embedded equipment; after the connection between the embedded device and the edge container management system is realized, the embedded device is registered in the edge container management system through the built-in container agent, so that the embedded device becomes a working node, and the management of the edge container management system on the embedded device is conveniently realized in the later period.
In one possible implementation method, the image file is a monitoring application; the deployment unit is specifically configured to: generating a monitoring object corresponding to the mirror image file through the container engine; the monitoring object is used for monitoring the embedded equipment.
Based on the scheme, the image file of the monitoring application is deployed to any embedded device, and the embedded device is monitored through the created monitoring object.
In one possible implementation, the deployment unit is further configured to: determining that version upgrading information of the image file exists, wherein the version upgrading information comprises an address of an upgrading version corresponding to the image file in the central container management system; and upgrading the version of the image file according to the address of the upgrading version corresponding to the image file in the central container management system.
Based on the scheme, when the version of the image file in the embedded equipment is upgraded, the address of the upgraded version corresponding to the image file in the central container management system is obtained from the version upgrading information of the image file, so that the version of the image file is upgraded. The scheme simplifies the version upgrading step of the application in the embedded device.
In a fourth aspect, an embodiment of the present invention provides an application deployment apparatus, where the apparatus includes: the acquisition unit is used for acquiring the mirror image file from the central container management system; the determining unit is used for determining the embedded equipment corresponding to the image file; the embedded equipment is a working node registered in the edge container management system; the sending unit is used for sending the mirror image file to the embedded equipment; the embedded device is used for deploying the image file through a built-in container engine.
Based on the scheme, the edge container management system determines the embedded equipment corresponding to the image file according to the image file acquired from the central container management system, wherein the embedded equipment is a working node registered in the edge container management system, the edge container management system sends the image file to the embedded equipment, and then the embedded equipment deploys the image file through a built-in container engine, so that interconnection and intercommunication among the central container system, the edge container management system and the embedded equipment are realized.
In a possible implementation method, the obtaining unit is further configured to: establishing connection with the embedded equipment through a connection agent built in the embedded equipment; and determining that the embedded equipment is a working node of the edge container management system through a container agent arranged in the embedded equipment.
Based on the scheme, before the edge container management system acquires the image file from the central container management system, a connection channel between the edge container management system and the embedded device needs to be established, specifically: the edge container management system establishes connection with the embedded device through a connection agent built in the embedded device, and determines the embedded device as a working node of the edge container management system through a container agent built in the embedded device.
In one possible implementation method, the image file is a monitoring application; the monitoring application is used for generating a monitoring object of the embedded equipment; the device also comprises a processing unit, wherein the processing unit is used for receiving the monitoring data reported by the monitoring object of the embedded equipment and reporting the monitoring data to the central container management system.
Based on the scheme, deploying the monitoring application in the embedded equipment to generate a monitoring object of the embedded equipment; and the edge container management system receives the monitoring data reported by the monitoring object of the embedded equipment and forwards the monitoring data to the central container management system, so that the central container management system monitors the equipment state of the embedded equipment.
In one possible implementation, the edge container management system further includes a monitoring agent; the processing unit is further to: sending own state data to the central container management system through the monitoring agent; and the central container management system is used for managing the edge container management system according to the state data.
Based on the scheme, the monitoring agent is deployed in the edge container management system, so that the edge container management platform can send own state data to the central container management system through the monitoring agent, and the aim of unified management of the central container management system on the edge container management system is fulfilled.
In one possible implementation, the image file is implemented by persistent integration/persistent deployment of the central container management system.
Based on the scheme, the image file is generated in the central container management system in a continuous integration/continuous deployment mode, and an extremely convenient implementation mode is provided for deployment of the application and later update of the application version.
In a fifth aspect, an embodiment of the present invention provides a computing device, including:
a memory for storing program instructions;
a processor for calling program instructions stored in said memory and executing the method according to the obtained program as described in any of the first and second aspects.
In a sixth aspect, the present invention provides a computer-readable storage medium storing computer-executable instructions for causing a computer to perform the method according to any one of the first and second aspects.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
FIG. 1 is a diagram of a possible system architecture according to an embodiment of the present invention;
fig. 2 is a method for deploying an application according to an embodiment of the present invention;
FIG. 3 is a diagram of an embedded device architecture according to an embodiment of the present invention;
fig. 4 is a schematic diagram of application deployment according to an embodiment of the present invention;
fig. 5 is an application deployment apparatus according to an embodiment of the present invention;
fig. 6 is another application deployment apparatus provided in the embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a diagram illustrating a possible system architecture according to an embodiment of the present invention. The system includes a central container management system 100, at least one edge container management system 110, and at least one embedded device 120.
Illustratively, in the embodiment of the present invention, two edge container management systems 111 and 112 are taken as an example, wherein 111 is called edge container management system No. 1 (K8s system is taken as an example, K8s-edge1), and 112 is called edge container management system No. 2 (K8s-edge 2); in the embodiment of the present invention, two embedded devices 121 and 122 are taken as an example, where 121 is called a number 1 embedded device, and 122 is called a number 2 embedded device.
One possible implementation is that the system architecture further comprises at least one terminal 130, which uses the functionality provided by the embedded device to implement a specific functionality. Taking fig. 1 as an example, the system includes terminals 131 and 132, wherein 131 is assigned as terminal No. 1 using embedded device No. 1, and 132 is assigned as terminal No. 2 using embedded device No. 2.
The central container management system manages each edge container management system, and long connection can be kept between the two edge container management systems. One possible implementation is by installing agent-manager proxy components on the central container management system, and by installing agent-edge proxy components on the edge container management systems K8s-edge1 and K8s-edge2, respectively, whereby K8s-edge1 and K8s-edge2, respectively, remain in long connection with the central container management system through the gPRC.
The edge container management system manages each embedded device deployed below the edge container management system, and long connection can be kept between the embedded devices and the edge container management system. One possible implementation is by deploying K8s-edge cluster in the edge container management system for managing embedded devices on the edge side; the edge container management system and the embedded device keep long connection through a specified port Websocket, and task issuing and device state reporting are achieved. For example, K8s-edge1 and K8s-edge2 maintain long links with embedded device # 1 and embedded device # 2, respectively, through Websocket.
The terminal, such as a camera and a sensor, is accessed into the embedded equipment through MQTT/IP and other related protocols, and when videos or related data need to be processed, the terminal directly uploads the data to the embedded equipment and the embedded equipment processes the data; and after the processing is finished, the embedded equipment directly returns the processing result to the terminal. For example, the number 1 terminal is accessed to the number 1 embedded device through a relevant protocol, when the number 1 terminal reports the data to be processed acquired by the number 1 terminal to the number 1 embedded device, the number 1 embedded device processes the data to be processed, and directly returns the processed result to the number 1 terminal. Wherein, related protocols include but are not limited to MQTT, Modbus, HTTP, OPC-UA, Steam; terminal devices, i.e., clients, include, but are not limited to, IoT devices in an internet of things scenario, devices in industrial manufacturing, IoT devices, smart homes, sensors, and car networking.
Based on the system architecture shown in fig. 1, an embodiment of the present invention provides an application deployment method. As shown in fig. 2, the method includes:
step 201, an embedded device accesses to an edge container management system; the embedded equipment is a working node of the edge container management system;
step 202, the edge container management system acquires a mirror image file from the central container management system;
step 203, the edge container management system determines the embedded device corresponding to the image file;
step 204, the edge container management system sends a mirror image file to the embedded device; correspondingly, the embedded equipment receives the mirror image file sent by the edge container management system;
step 205, the embedded device deploys the image file through a built-in container engine.
In step 201, the embedded device in the embodiment of the present invention has the capability of accessing to the public network; further, before the embedded device leaves the factory, the connection agent (agent keeper), the container engine (Docker engine), and the container agent (K8s-edge agent) are solidified in the embedded operating system. The agent keeper is used for authentication when the embedded equipment is accessed to the edge container management system; after the authentication is successful, the Docker engine and the K8s-edgeagent are started continuously. The Docker engine is used for creating an environment for application deployment so as to realize the installation of the image file on the embedded equipment; the K8s-edge agent is used to provide a channel for data interaction with the edge container management system.
As shown in fig. 3, an embedded device architecture diagram provided for an embodiment of the present invention includes a bottommost hardware device; an embedded system is installed on a hardware device, and as an example, the embedded system may be a Linux OS; a Docker engine, a lightweight Database (Database), an MQTT protocol and the like are solidified in the embedded system; the Docker engine is used for creating an application deployment environment to achieve installation of image files on the embedded equipment, the Database is used for achieving edge autonomy, and protocols such as MQTT are used for enabling the terminal to be accessed into the embedded equipment.
On the other hand, a K8s-edge cluster is deployed in the edge container management system and is used for managing embedded equipment on the edge side; the edge container management system and the embedded device keep long connection through a specified port Websocket, and task issuing and device state reporting are achieved. For example, K8s-edge1 and K8s-edge2 maintain long links with embedded device # 1 and embedded device # 2, respectively, through Websocket.
Optionally, the accessing of the embedded device to the edge container management system includes: after the embedded equipment is started, the embedded equipment establishes connection with the edge container management system through a built-in connection agent; and the embedded equipment is registered as a working node of the edge container management system through a built-in container agent.
For the starting process of the embedded device, for example, with the embedded device No. 1, after the embedded device No. 1 is powered on, the agent keeper is started first; after the agent keeper is started, the embedded device No. 1 is automatically connected to the edge container management systems K8s-edge1 and K8s-edge 2; after the embedded device No. 1 is connected to the edge container management system, the K8s-edge agent is started, and the matching between the embedded device No. 1 and the K8s-edge1 and the mismatching between the embedded device No. 1 and the K8s-edge2 are determined by verifying the verification certificate information of the accessed embedded device No. 1 at K8s-edge1 and K8s-edge2, so that the embedded device No. 1 completes the registration of the device on the K8s-edge1 and is automatically added as a working node after the registration is successful. Therefore, the embedded equipment and the edge container management system are connected and registered to the matched edge container management system, authentication is realized through certificate information verification when the edge container management system manages the embedded equipment, and the access safety and compliance of the embedded equipment are guaranteed.
In step 202 above, the edge container management system obtains the image file from the central container management system.
Optionally, the image file is implemented by persistent integration/persistent deployment of the central container management system.
Based on a Continuous Integration Continuous Deployment (CICD) tool, the automatic compiling, packaging, testing and deployment capabilities of the application codes are realized. The concrete can be represented as follows: after the developer completes the development of the application code, the developed application code is placed in a code base, such as a git/svn code base; then, the CICD tool directly interfaces the code base developed by the application, automatically pulls the code from the code base for compiling, automatically packages the code into a Docker mirror image, and automatically completes the test in the test environment, thereby obtaining the version after the test is passed.
In step 203, the edge container management system determines the embedded device corresponding to the image file;
for the version after the test in the example of step 202 passes, the version is automatically deployed to the embedded device in the designated edge container management system cluster, so that a complete flow of the flow item is constructed in the embedded scene on the edge side.
The edge container management system determines the embedded device corresponding to the image file, and mainly shows that the matching degree of the image file and the multi-aspect attributes of the embedded device to be deployed and applied is determined, that is, a screening process exists, and the method specifically can be shown as follows: and deploying the application in the embedded equipment meeting the conditions. Such as screening around the hardware resources of the embedded device so that the application to be deployed is deployed in the most suitable embedded device. The embodiment of the present invention does not limit the specific screening content. Of course, in practical application, the embedded device may also be required to actively initiate image file acquisition.
In the step 204, the edge container management system sends the image file to the embedded device; correspondingly, the embedded equipment receives the mirror image file sent by the edge container management system; and in step 205, the embedded device deploys the image file through the built-in container engine.
Optionally, the application to be run by the embedded device is compiled, packaged, and uploaded to a mirror image warehouse of the central container management system, and the application is released to an application store of the central container management system by a Helm Chart application editing tool.
The process of the application in the application store becoming the application on the embedded device may be specifically expressed as follows:
install agent-manager proxy components in the central container management system and agent-edge proxy components in the edge container management system, with long connections maintained between them through the gPRC.
Through a screening mode, namely when the edge container management system determines that the embedded device needs to install the specified application, the central container management system issues an arranging template of Chart in an application store to the edge container management system, wherein the arranging template of Helm Chart includes information such as an address and an application version of an image file to be deployed by the application, namely the central container management system issues an arranging task to the edge container management system.
And then, when the scheduling task is issued to the edge container management system, the APIServer of the edge container management system is changed, and further a master communication interface module which is used for monitoring the state of the API Server and is positioned in the edge container management system monitors that the API Server of the edge container management platform is changed and other changed items are changed, and sends a scheduling task message to a K8s-edge agent in the embedded device through a long connection channel of Websocket.
As a possible implementation manner, when the edge container management system determines that the embedded device needs to install the specified application, the edge container management system informs the central container management system through the long link between the edge container management system and the central container management system, so that the central container management system can directly issue the image file to the matched embedded device through the edge container management system.
And finally, when the embedded equipment receives the application deployment task, starting application deployment and starting the deployed application. In this way, deployment of applications on embedded devices is enabled.
When the embedded device deploys the application, the embedded device is deployed through a built-in Docker engine.
Optionally, after the embedded device deploys the image file through a built-in container engine, the method further includes: the embedded equipment determines that version upgrading information of the image file exists, wherein the version upgrading information comprises an address of an upgrading version corresponding to the image file in the central container management system; and the embedded equipment carries out version upgrading on the image file according to the address of the upgrading version corresponding to the image file in the central container management system.
In addition, aiming at the scene that the version of the application in the embedded equipment is changed, a programmer uploads a new version image file of the application to an image warehouse, modifies a Yaml file in Helm Chart, and modifies the version of the application into a new version, such as a v1 version to a v2 version; in the central container management system, the deployed application version of the embedded equipment is checked, and whether the current application needs to be updated or not is prompted by comparing and determining that the new version of the application is available for selection; therefore, the embedded device receives a prompt whether the current application needs to be updated, that is, the embedded device determines that version upgrading information in the image asking price exists, wherein the version upgrading information comprises the address of the upgrading version corresponding to the image file in the central container management system; and after the updating is determined to be needed, clicking to update, and acquiring the latest version of the image file by the embedded equipment according to the address of the updated version corresponding to the image file in the central container management system, thereby realizing the version updating of the image file. By the method, the unified update of the application can be realized, so that the problems of deployment, update, management and the like of the application of the embedded equipment are greatly simplified.
Optionally, the image file is a monitoring application; the embedded device deploys the image file through a built-in container engine, and the method comprises the following steps: the embedded equipment generates a monitoring object corresponding to the mirror image file through the container engine; the monitoring object is used for monitoring the embedded equipment.
Optionally, the edge container management system receives monitoring data reported by the monitoring object of the embedded device and reports the monitoring data to the central container management system.
The method comprises the steps that an image file serving as a monitoring application function is stored in an application store, an API Server calls a daemon controller to create a daemon object through a device management component of an embedded device deployed in the application store, and the daemon object can ensure that a created pod runs a copy on each embedded device in a cluster. The process monitors and acquires the hardware running state of the equipment, the health state of the equipment in real time, and remotely ssh logs in a tool, so that the capability of the edge container management platform in uniformly managing, monitoring, operating and maintaining the embedded equipment is realized.
The mechanism for this copy is to ensure that each embedded device is installed with a daemon. With 10 embedded devices, there will be one copy on each device for the 10 embedded devices.
daemonset is designed as a special application type, and is a deployment mode designed for simplifying unified management, monitoring and operation and maintenance of edge-side embedded devices in an embedded device scene.
If the daemoset of one embedded device is hung, another daemoset is operated for the embedded device. The specific process can be expressed as follows: determining whether the operating state of the daemon set of the embedded equipment is hung up or not, wherein the daemon set of the embedded equipment is monitored in real time through an API Server; reconfiguring a daemonset for an embedded device with the daemonset hung is realized through a daemonset controller. When the API Server monitors that the damset of an embedded device is hung, the API Server immediately calls the daemoset controller, and the daemoset controller immediately creates a daemoset to ensure that a copy of the daemoset is running.
Optionally, the edge container management system further includes a monitoring agent; the method further comprises the following steps: the edge container management system sends own state data to the central container management system through the monitoring agent; and the central container management system is used for managing the edge container management system according to the state data.
A set of unified management system for the edge container management system is developed and deployed in the central container management system, and agent agents, such as monitoring agent agents and log agent agents, are installed in the edge container management system, so that the targets of unified management, unified task issuing, unified operation and maintenance and monitoring of the central container management system for the edge container management system can be realized, and the method specifically comprises the following steps: the edge container management system can report the self state data of the cluster at regular time, and the central container management system can manage the self state data of the cluster according to the state data of the edge container management system, including control task issuing, adjustment of monitoring strength and the like.
The scenes applied by the embodiment of the invention can comprise the intelligent security monitoring field and the edge P2P scene. By way of example, the following describes a method according to an embodiment of the present invention, taking the field of smart security monitoring as an example.
1. An application developer needs to form a mirror image file by using a developed or trained face/sound detection application, upload the mirror image file to a cloud mirror image warehouse, arrange the application through a Helm Chart application arrangement tool, and then release the application to a cloud application store; the cloud end is equivalent to a central container management system;
2. an administrator solidifies an agentkeeper, a Docker engine and a K8s-edge agent in advance when an embedded device needing to be accessed to the edge container management system leaves a factory;
3. when the embedded device is started, the embedded device can be automatically registered in a specified edge container management system and registered as a working node;
4. an administrator or a business party selects a human face/audio detection application to be deployed in an application store, and deploys the human face/audio detection application to a specified edge container management system, and the edge container management system can automatically deploy the application to embedded equipment meeting deployment conditions;
5. the terminal, such as a camera and a sensor, is accessed into the embedded equipment through MQTT/IP and related protocols, when videos or related data need to be processed, the terminal directly uploads the data to the embedded equipment for processing, and the processing result is directly returned to the terminal equipment;
6. the embedded equipment also transmits the processed data back to the cloud, the data are intensively aggregated and retrained by using tools such as an analysis tool, a machine learning tool and the like in a center at the cloud, and then the data are processed, the application is continuously optimized through continuous deep precipitation and optimization of a large amount of data, the original mirror image is updated, and the data are issued to an application store;
7. if the automatic deployment and update scheme based on the CICD tool is adopted, when the application has an update version, the application of the edge equipment is automatically updated;
8. since the device management component (such as the monitoring application) is deployed in the embedded device, the embedded device can be remotely monitored in real time at the cloud, including checking the state of the device and the health state of the application.
Fig. 4 is a schematic diagram of application deployment according to an embodiment of the present invention, which includes a central container management system 410, an edge container management system 420, at least one embedded device 430, and at least one terminal 440.
The central container management system 410 includes an ETCD, a Controller Manager, an API Server, and a Schedule; the edge container management system 320 includes Database, API Server, Proxy, Schedule, ControllerManager; the embedded device 430 includes a plurality of applications, Docker, daemon, device IP; the terminal 440 includes IoT devices, sensors.
Based on the steps, the cloud edge-side cooperative architecture of 'cloud end-edge-device end' is realized in the scheme.
Based on the same conception, the embodiment of the invention provides an application deployment device. As shown in fig. 5, the apparatus includes:
an access unit 501, configured to access an edge container management system; the embedded equipment is a working node of the edge container management system;
a receiving unit 502, configured to receive an image file sent by the edge container management system; the image file is acquired by the edge container management system from a central container management system;
a deployment unit 503, configured to deploy the image file through a built-in container engine.
Further, for the apparatus, the access unit 501 is specifically configured to: after the system is started, a connection is established with the edge container management system through a built-in connection agent; and registering the edge container management system as a working node of the edge container management system through a built-in container agent.
Further, for the apparatus, the image file is a monitoring application; the deployment unit 503 is specifically configured to: generating a monitoring object corresponding to the mirror image file through the container engine; the monitoring object is used for monitoring the embedded equipment.
Further to this apparatus, the deployment unit 503 is further configured to: determining that version upgrading information of the image file exists, wherein the version upgrading information comprises an address of an upgrading version corresponding to the image file in the central container management system; and upgrading the version of the image file according to the address of the upgrading version corresponding to the image file in the central container management system.
Based on the same conception, the embodiment of the invention provides another application deployment device. As shown in fig. 6, the apparatus includes:
an obtaining unit 601, configured to obtain an image file from a central container management system;
a determining unit 602, configured to determine an embedded device corresponding to the image file; the embedded equipment is a working node registered in the edge container management system;
a sending unit 603, configured to send the image file to the embedded device; the embedded device is used for deploying the image file through a built-in container engine.
Further, for the apparatus, the obtaining unit 601 is further configured to: establishing connection with the embedded equipment through a connection agent built in the embedded equipment; and determining that the embedded equipment is a working node of the edge container management system through a container agent arranged in the embedded equipment.
Further, for the apparatus, the image file is a monitoring application; the monitoring application is used for generating a monitoring object of the embedded equipment; the apparatus further includes a processing unit 604, where the processing unit 604 is configured to receive monitoring data reported by the monitoring object of the embedded device and report the monitoring data to the central container management system.
Further, for the apparatus, the edge container management system further comprises a monitoring agent; the processing unit 604 is further configured to: sending own state data to the central container management system through the monitoring agent; and the central container management system is used for managing the edge container management system according to the state data. Further, for the apparatus, the image file is implemented by persistent integration/persistent deployment of the central container management system.
The embodiment of the invention also provides a computing device, which can be specifically a desktop computer, a portable computer, a smart phone, a tablet computer, a Personal Digital Assistant (PDA) and the like. The computing device may include a Central Processing Unit (CPU), memory, input/output devices, etc., the input devices may include a keyboard, mouse, touch screen, etc., and the output devices may include a display device, such as a Liquid Crystal Display (LCD), a Cathode Ray Tube (CRT), etc.
Memory, which may include Read Only Memory (ROM) and Random Access Memory (RAM), provides the processor with program instructions and data stored in the memory. In embodiments of the invention, the memory may be used to store program instructions for a method of application deployment;
and the processor is used for calling the program instructions stored in the memory and executing the application deployment method according to the obtained program.
An embodiment of the present invention further provides a computer-readable storage medium, where computer-executable instructions are stored, and the computer-executable instructions are used to enable a computer to execute the application deployment method.
It should be apparent to those skilled in the art that embodiments of the present invention may be provided as a method, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (13)

1. An application deployment method, comprising:
the embedded equipment is accessed to the edge container management system; the embedded equipment is a working node of the edge container management system;
the embedded equipment receives the mirror image file sent by the edge container management system; the image file is acquired by the edge container management system from a central container management system;
and the embedded equipment deploys the image file through a built-in container engine.
2. The method of claim 1,
the embedded device access edge container management system comprises:
after the embedded equipment is started, the embedded equipment establishes connection with the edge container management system through a built-in connection agent;
and the embedded equipment is registered as a working node of the edge container management system through a built-in container agent.
3. The method of claim 1, wherein the image file is a monitoring application;
the embedded device deploys the image file through a built-in container engine, and the method comprises the following steps:
the embedded equipment generates a monitoring object corresponding to the mirror image file through the container engine; the monitoring object is used for monitoring the embedded equipment.
4. The method of claim 1,
after the embedded device deploys the image file through a built-in container engine, the method further includes:
the embedded equipment determines that version upgrading information of the image file exists, wherein the version upgrading information comprises an address of an upgrading version corresponding to the image file in the central container management system;
and the embedded equipment carries out version upgrading on the image file according to the address of the upgrading version corresponding to the image file in the central container management system.
5. An application deployment method, comprising:
the edge container management system acquires the mirror image file from the central container management system;
the edge container management system determines embedded equipment corresponding to the mirror image file; the embedded equipment is a working node registered in the edge container management system;
the edge container management system sends the mirror image file to the embedded equipment; the embedded device is used for deploying the image file through a built-in container engine.
6. The method of claim 5,
before the edge container management system acquires the image file from the central container management system, the method further comprises the following steps:
the edge container management system establishes connection with the embedded equipment through a connection agent built in the embedded equipment;
and the edge container management system determines the embedded equipment as a working node of the edge container management system through a container agent built in the embedded equipment.
7. The method of claim 5, wherein the image file is a monitoring application; the monitoring application is used for generating a monitoring object of the embedded equipment;
the method further comprises the following steps:
and the edge container management system receives the monitoring data reported by the monitoring object of the embedded equipment and reports the monitoring data to the central container management system.
8. The method of claim 5, wherein the edge container management system further comprises a monitoring agent;
the method further comprises the following steps:
the edge container management system sends own state data to the central container management system through the monitoring agent; and the central container management system is used for managing the edge container management system according to the state data.
9. The method of any one of claims 1 to 5,
the image file is realized by the central container management system through continuous integration/continuous deployment.
10. An application deployment apparatus, comprising:
the access unit is used for accessing the edge container management system; the embedded equipment is a working node of the edge container management system;
the receiving unit is used for receiving the mirror image file sent by the edge container management system; the image file is acquired by the edge container management system from a central container management system;
and the deployment unit is used for deploying the image file through a built-in container engine.
11. An application deployment apparatus, comprising:
the acquisition unit is used for acquiring the mirror image file from the central container management system;
the determining unit is used for determining the embedded equipment corresponding to the image file; the embedded equipment is a working node registered in the edge container management system;
the sending unit is used for sending the mirror image file to the embedded equipment; the embedded device is used for deploying the image file through a built-in container engine.
12. A computing device, comprising:
a memory for storing program instructions;
a processor for calling program instructions stored in said memory to execute the method of any one of claims 1-4, 5-9 in accordance with the obtained program.
13. A computer-readable storage medium having stored thereon computer-executable instructions for causing a computer to perform the method of any one of claims 1-4, 5-9.
CN202010435078.1A 2020-05-21 2020-05-21 Application deployment method and device Active CN111611054B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010435078.1A CN111611054B (en) 2020-05-21 2020-05-21 Application deployment method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010435078.1A CN111611054B (en) 2020-05-21 2020-05-21 Application deployment method and device

Publications (2)

Publication Number Publication Date
CN111611054A true CN111611054A (en) 2020-09-01
CN111611054B CN111611054B (en) 2023-05-16

Family

ID=72205182

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010435078.1A Active CN111611054B (en) 2020-05-21 2020-05-21 Application deployment method and device

Country Status (1)

Country Link
CN (1) CN111611054B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112600909A (en) * 2020-12-07 2021-04-02 苏州浪潮智能科技有限公司 Method, system and medium for cluster information push
CN112822444A (en) * 2021-01-05 2021-05-18 浪潮软件科技有限公司 Intelligent home security monitoring system and method based on home edge computing
CN113225214A (en) * 2021-05-07 2021-08-06 浪潮软件科技有限公司 Method and device for cooperative management of edge CDN node and computer readable medium
CN113535555A (en) * 2021-07-12 2021-10-22 中国科学院软件研究所 Containerization testing method and system for reinforcement learning model
CN113568638A (en) * 2021-07-26 2021-10-29 广东电网有限责任公司 Containerization non-stop issuing method for power monitoring system based on mirror image warehouse
CN114679380A (en) * 2021-04-09 2022-06-28 腾讯云计算(北京)有限责任公司 Method and related device for creating edge cluster

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017129106A1 (en) * 2016-01-29 2017-08-03 腾讯科技(深圳)有限公司 Data request processing method, server and system
CN108958927A (en) * 2018-05-31 2018-12-07 康键信息技术(深圳)有限公司 Dispositions method, device, computer equipment and the storage medium of container application
CN109302483A (en) * 2018-10-17 2019-02-01 网宿科技股份有限公司 A kind of management method and system of application program
CN110896404A (en) * 2018-09-12 2020-03-20 华为技术有限公司 Data processing method and device and computing node

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017129106A1 (en) * 2016-01-29 2017-08-03 腾讯科技(深圳)有限公司 Data request processing method, server and system
CN108958927A (en) * 2018-05-31 2018-12-07 康键信息技术(深圳)有限公司 Dispositions method, device, computer equipment and the storage medium of container application
CN110896404A (en) * 2018-09-12 2020-03-20 华为技术有限公司 Data processing method and device and computing node
CN109302483A (en) * 2018-10-17 2019-02-01 网宿科技股份有限公司 A kind of management method and system of application program

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
刘熙;胡志勇;: "基于Docker容器的Web集群设计与实现" *

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112600909A (en) * 2020-12-07 2021-04-02 苏州浪潮智能科技有限公司 Method, system and medium for cluster information push
CN112822444A (en) * 2021-01-05 2021-05-18 浪潮软件科技有限公司 Intelligent home security monitoring system and method based on home edge computing
CN114679380A (en) * 2021-04-09 2022-06-28 腾讯云计算(北京)有限责任公司 Method and related device for creating edge cluster
CN114679380B (en) * 2021-04-09 2024-04-26 腾讯云计算(北京)有限责任公司 Method and related device for creating edge cluster
CN113225214A (en) * 2021-05-07 2021-08-06 浪潮软件科技有限公司 Method and device for cooperative management of edge CDN node and computer readable medium
CN113225214B (en) * 2021-05-07 2023-04-07 浪潮通信技术有限公司 Method and device for cooperative management of edge CDN node and computer readable medium
CN113535555A (en) * 2021-07-12 2021-10-22 中国科学院软件研究所 Containerization testing method and system for reinforcement learning model
CN113535555B (en) * 2021-07-12 2023-06-27 中国科学院软件研究所 Reinforced learning model-oriented containerization test method and system
CN113568638A (en) * 2021-07-26 2021-10-29 广东电网有限责任公司 Containerization non-stop issuing method for power monitoring system based on mirror image warehouse

Also Published As

Publication number Publication date
CN111611054B (en) 2023-05-16

Similar Documents

Publication Publication Date Title
CN111611054B (en) Application deployment method and device
Seitz et al. Fog computing as enabler for blockchain-based IIoT app marketplaces-A case study
US10445142B2 (en) Edge computing platform
US11233826B2 (en) System and method of microservice-based application deployment with automating authorization configuration
CN112448858B (en) Network communication control method and device, electronic equipment and readable storage medium
CN107071052B (en) Device, system and method for providing cloud back-end service for Internet of things equipment
WO2016037479A1 (en) Method, device and system for optimizing virtualized network function (vnf)
CN112988485B (en) Simulation test method and device for electric power Internet of things equipment
EP3128416A1 (en) Sdn application integration, management and control method, system and device
CN112738138B (en) Cloud security hosting method, device, equipment and storage medium
CN111580833A (en) Application updating method and system, local management agent device and cloud server
CN117608825A (en) Resource management method based on multi-cloud management platform and related equipment
CN115514667A (en) Access service processing method, system, device, electronic equipment and storage medium
CN113419818B (en) Basic component deployment method, device, server and storage medium
CN113127009A (en) Automatic deployment method and device for big data management platform
CN113626002A (en) Service execution method and device
CN111935177B (en) Service control method and device
CN105245553A (en) SOA system and business processing method
CN115129574A (en) Code testing method and device
CN112799970A (en) Test data processing method, device, electronic equipment and medium
CN111897565A (en) Data processing method, device and equipment based on Internet of things
CN112448909A (en) Electronic lock management method, device, system and storage medium
CN112367296B (en) Service control method and device
CN110691263A (en) Method, medium, electronic device and system for synchronizing local time and server time
CN114090242A (en) Model training method, device, equipment, storage medium and program product

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant