Deployment Method, Device, Equipment and Medium for Domain Name System Cloud Resolution Service
By judging the type of DNS server required by the cloud platform and filling the target pool, combining the container image integrating designate function code and DNS toolkit, the problem that the OpenStack cloud platform DNS cloud resolution service can only connect to the internal DNS servers of the cluster, achieving flexible use of internal and external servers, and improving the flexibility and efficiency of deployment and use.
Patent Information
- Application Number
- CN202310109959.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-10
- Publication Date
- 2025-06-27
- Estimated Expiration
- 2043-02-10
AI Technical Summary
In the existing technology, the DNS cloud resolution service based on k8s can only support the docking of DNS servers within the cluster, and cannot automatically connect to DNS servers outside the cluster, resulting in the inability to use DNS servers outside the cluster for DNS cloud resolution, which brings difficulties to deployment and use.
By determining whether the domain name system server that the cloud platform needs to use is an internal cluster server or an external cluster server, if it is an external cluster server, it will fill its target pool so that it can perform DNS cloud resolution services; if it is an internal cluster server, it will be started as a target server and fill the target pool so that it can perform DNS cloud resolution services. Using pre-fetched container images, the designate feature code and DNS toolkit is integrated, and DNS toolkits are supported for DNS cloud resolution using internal and external servers.
It realizes that DNS cloud resolution services can be performed using internal and external servers on the OpenStack cloud platform, solves the problem that only the DNS servers within the cluster can be connected in the existing technology, and improves the deployment flexibility and usage capabilities of DNS cloud resolution services.
Smart Images

Figure CN116233221B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and particularly to a deployment method, device, equipment and medium for domain name system cloud resolution services. Background Art
[0002] OpenStack is an open-source cloud computing management platform project, which is a combination of a series of software open-source projects. It was developed and initiated by NASA (National Aeronautics and Space Administration of the United States) and Rackspace in cooperation, and is licensed under the Apache License (a free software license issued by the Apache Software Foundation). OpenStack provides scalable and elastic cloud computing services for private clouds and public clouds. The project goal is to provide a cloud computing management platform that is simple to implement, highly scalable, rich, and standardized. The OpenStack project consists of several main components to complete specific tasks, and it is an open-source project aiming to provide software for the construction and management of public and private clouds.
[0003] Kubernetes (k8s) is a container cluster management system open-sourced by Google (Borg internally). It is a brand-new leading solution for distributed architecture based on container technology. On the basis of Docker technology, it provides a series of complete functions such as deployment and operation, resource scheduling, service discovery, and dynamic scaling for containerized applications, improving the convenience of large-scale container cluster management.
[0004] Currently, there are problems with the DNS (Domain Name System) cloud resolution deployment function of the OpenStack cloud platform: Currently, the DNS cloud resolution service function based on k8s in the OpenStack cloud platform only supports docking with the DNS server within the cluster (the cluster is a cluster of domain name system servers within the cloud platform), and cannot automatically dock and deploy the DNS server outside the cluster (that is, outside the cloud platform). That is, the DNS server outside the cluster cannot be used for DNS cloud resolution, which brings difficulties to the deployment of on-site DNS cloud resolution services and the use of DNS cloud resolution service functions.
[0005] In summary, how to implement domain name system cloud resolution services that can utilize both the internal servers of the cloud platform and the external servers of the cloud platform is an urgent problem to be solved currently. Summary of the Invention
[0006] In view of this, the purpose of the present invention is to provide a deployment method, device, equipment and medium for domain name system cloud resolution services, which can utilize both the internal servers of the cloud platform and the external servers for domain name system cloud resolution services. The specific solutions are as follows:
[0007] In a first aspect, the present application discloses a method for deploying a domain name system cloud resolution service, which is applied to a cloud platform and includes:
[0008] Determine whether the domain name system server required by the cloud platform is an internal server of the cluster or an external server of the cluster; the cluster is a cluster of domain name system servers within the cloud platform;
[0009] If it is an external server of the cluster, then fill the target pool corresponding to the domain name system cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service;
[0010] If it is an internal server of the cluster, then start any pre-specified deployment node of the internal server of the cluster as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the domain name system cloud resolution service;
[0011] Based on the pre-obtained container image, and use the target server or the external server of the cluster to perform the domain name system cloud resolution service to complete the deployment of the domain name system cloud resolution service; the container image is an image that integrates the designate function code and the domain name system toolkit in the selected base image and supports the domain name system cloud resolution service and the use of the internal server and the external server of the cluster to perform the domain name system cloud resolution service.
[0012] Optionally, the determining whether the domain name system server required by the cloud platform is an internal server of the cluster or an external server of the cluster includes:
[0013] Create an endpoint corresponding to the domain name system cloud resolution service for communicating with the message queue and the database, and start the first service, the second service, the third service, and the fourth service of the domain name system cloud resolution, and then determine whether the domain name system server required by the cloud platform is an internal server of the cluster or an external server of the cluster.
[0014] Optionally, before creating the endpoint corresponding to the domain name system cloud resolution service for communicating with the message queue and the database, it further includes:
[0015] Determine whether it is necessary to enable the domain name system cloud resolution service, and based on the judgment result, turn on or off the deployment process according to the switch for whether to deploy the domain name system cloud resolution service added in the global control file in advance.
[0016] Optionally, the based on the pre-obtained container image, and use the target server or the external server of the cluster to perform the domain name system cloud resolution service includes:
[0017] Start the fifth service of the domain name system cloud resolution service;
[0018] Based on the container image pre-acquired and stored in the private repository of the cloud platform, and use the target server or the external server of the cluster to perform the domain name system cloud resolution service.
[0019] Optionally, before starting the first service, second service, third service, and fourth service of the domain name system cloud resolution, it further includes:
[0020] Specify the first service, second service, third service, fourth service, and fifth service of the domain name system cloud resolution, and the deployment nodes of several internal servers of the cluster used to perform the domain name system cloud resolution service through the inventory file in advance.
[0021] Optionally, if it is an external server of the cluster, filling the target pool corresponding to the domain name system cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service, includes:
[0022] If it is an external server of the cluster, configure the status of the internal server of the cluster to the disabled state, map the first configuration file of the external server of the cluster to the first ConfigMap, and then mount the first ConfigMap to fill the target pool corresponding to the domain name system cloud resolution service, so that the external server of the cluster has the function of performing the domain name system cloud resolution service.
[0023] Optionally, if it is an internal server of the cluster, start any internal server of the cluster specified in advance as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the domain name system cloud resolution service, includes:
[0024] If it is an internal server of the cluster, configure the status of the internal server of the cluster to the used state, start any internal server of the cluster specified in advance as the target server, then map the second configuration file of the target server to the second ConfigMap, and mount the second ConfigMap to fill the target pool, so that the target server has the function of performing the domain name system cloud resolution service.
[0025] In a second aspect, the present application discloses a deployment device for a domain name system cloud resolution service, which is applied to a cloud platform and includes:
[0026] A judgment module, configured to judge whether the Domain Name System (DNS) server required by the cloud platform is an internal server or an external server of the cluster; the cluster is a cluster of DNS servers within the cloud platform;
[0027] A first filling module, configured to, if it is an external server of the cluster, fill the target pool corresponding to the DNS cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the DNS cloud resolution service;
[0028] A second filling module, configured to, if it is an internal server of the cluster, start any one of the pre-specified deployed nodes of the internal server of the cluster as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the DNS cloud resolution service;
[0029] A resolution service module, configured to perform the DNS cloud resolution service based on a pre-acquired container image and by using the target server or the external server of the cluster, so as to complete the deployment of the DNS cloud resolution service; the container image is an image obtained by integrating the designate function code and the DNS toolkit in a selected base image, which supports the DNS cloud resolution service and supports performing the DNS cloud resolution service by using the internal server and the external server of the cluster.
[0030] In a third aspect, the present application discloses an electronic device, including a processor and a memory; wherein, when the processor executes a computer program stored in the memory, the method for deploying the DNS cloud resolution service disclosed above is implemented.
[0031] In a fourth aspect, the present application discloses a computer-readable storage medium, configured to store a computer program; wherein, when the computer program is executed by a processor, the method for deploying the DNS cloud resolution service disclosed above is implemented.
[0032] It can be seen that this application determines whether the domain name system server required by the cloud platform is an internal server or an external server of the cluster; the cluster is a cluster of domain name system servers within the cloud platform; if it is an external server of the cluster, the target pool corresponding to the domain name system cloud resolution service is filled based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service; if it is an internal server of the cluster, any pre-specified deployment node of the internal server of the cluster is started as the target server, and the target pool is filled based on the target server, so that the target server has the function of performing the domain name system cloud resolution service; based on the pre-obtained container image, the domain name system cloud resolution service is performed using the target server or the external server of the cluster to complete the deployment of the domain name system cloud resolution service; the container image is an image that integrates the designate function code and the domain name system toolkit in the selected base image and supports the domain name system cloud resolution service and the use of the internal server and the external server of the cluster to perform the domain name system cloud resolution service. Thus, it can be seen that since the container image of this application supports the use of the internal server and the external server of the cluster to perform the domain name system cloud resolution service, it can determine whether the domain name system server to be used is an internal server or an external server of the cluster, and enable the target server or the external server of the cluster to have the function of performing the domain name system cloud resolution service, so that the domain name system cloud resolution service can be performed using the internal server (server within the cloud platform) of the cluster, and the domain name system cloud resolution service can also be performed using the external server (server outside the cloud platform) of the cluster. Description of the Drawings
[0033] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only the embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained according to the provided drawings without creative efforts.
[0034] Figure 1 It is a flowchart of a method for deploying a domain name system cloud resolution service provided by this application;
[0035] Figure 2 It is a flowchart of a specific method for deploying a domain name system cloud resolution service provided by this application;
[0036] Figure 3 It is a schematic diagram of the preparatory work for the deployment of a domain name system cloud resolution service provided by this application;
[0037] Figure 4Schematic diagram of the deployment process of a domain name system cloud resolution service provided by this application;
[0038] Figure 5 Schematic diagram of the structure of a deployment device for a domain name system cloud resolution service provided by this application;
[0039] Figure 6 Structural diagram of an electronic device provided by this application. Specific implementation manners
[0040] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0041] Currently, there are problems with the DNS cloud resolution deployment function of the OpenStack cloud platform: At present, the DNS cloud resolution service function based on the k8s OpenStack cloud platform only supports docking with the DNS server inside the cluster (the cluster is a cluster of domain name system servers inside the cloud platform), and cannot automatically dock and deploy the DNS server outside the cluster (that is, outside the cloud platform). That is, the DNS server outside the cluster cannot be used for DNS cloud resolution, which brings difficulties to the deployment of the on-site DNS cloud resolution service and the use of the DNS cloud resolution service function.
[0042] To overcome the above problems, this application provides a deployment solution for the domain name system cloud resolution service, which can utilize the servers inside the cloud platform and also the servers outside the cloud platform for the domain name system cloud resolution service.
[0043] See Figure 1 As shown, an embodiment of this application discloses a deployment method for a domain name system cloud resolution service, which is applied to a cloud platform. The method includes:
[0044] Step S11: Determine whether the domain name system server required by the cloud platform is an internal server of the cluster or an external server of the cluster; the cluster is a cluster of domain name system servers inside the cloud platform.
[0045] In the embodiment of this application, the internal server of the cluster is also the domain name system server within the cluster of domain name system servers located inside the cloud platform, and the external server of the cluster is also the domain name system server outside the cloud platform.
[0046] Step S12: If it is an external server of the cluster, fill the target pool corresponding to the domain name system cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service.
[0047] In the embodiment of the present application, the step of "if it is an external server of the cluster, fill the target pool corresponding to the domain name system cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service" includes: if it is an external server of the cluster, configure the status of the internal server of the cluster to the disabled state, map the first configuration file of the external server of the cluster to the first ConfigMap, and then mount the first ConfigMap to fill the target pool corresponding to the domain name system cloud resolution service, so that the external server of the cluster has the function of performing the domain name system cloud resolution service. It should be noted that ConfigMap can decouple the environment variable configuration information and the container image, facilitating the modification of the application configuration.
[0048] Specifically, if the domain name system server required by the cloud platform is an external server of the cluster, configure the status of the internal domain name system server to no (disabled state), map the rndc.key file (the first configuration file) of the external domain name system server (the external server of the cluster) to configmap, start the worker-init job and mount the external dns rndc.key configmap to fill the designate pool (the target pool).
[0049] Step S13: If it is an internal server of the cluster, start any one of the internal servers of the cluster at a pre-specified deployment node as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the domain name system cloud resolution service.
[0050] In the embodiment of the present application, the step of "if it is an internal server of the cluster, start any one of the internal servers of the cluster at a pre-specified deployment node as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the domain name system cloud resolution service" includes:
[0051] If it is an internal server of the cluster, configure the status of the internal server of the cluster to the used state, start any one of the internal servers of the cluster at a pre-specified deployment node as the target server, then map the second configuration file of the target server to the second ConfigMap, and mount the second ConfigMap to fill the target pool, so that the target server has the function of performing the domain name system cloud resolution service.
[0052] It should be noted that specifically, if the domain name system server required by the cloud platform is an internal server in the cluster, the status of the internal domain name system server is configured as yes (usage status), the DNS server pod is started to select any pre-specified internal DNS server of the deployment node as the target server, the rndc.key file (the second configuration file) of the internal domain name system server (the internal server in the cluster) is mapped as a configmap, and the worker-init job is started and the external dns rndc.key configmap is mounted to populate the designate pool (the target pool).
[0053] Step S14: Based on the pre-obtained container image, and using the target server or the external server of the cluster to perform the domain name system cloud resolution service, so as to complete the deployment of the domain name system cloud resolution service; the container image is an image that integrates the designate function code and the domain name system toolkit in the selected base image and supports the domain name system cloud resolution service and the domain name system cloud resolution service using the internal server and the external server of the cluster.
[0054] In the embodiment of the present application, centos8.2 is selected as the base image of the container images corresponding to designate and the DNS server, and the domain name system toolkit includes, but is not limited to, the Bind9 and PowerDNS 4 installation packages. It should be noted that integrating the designate function code will support the domain name system cloud resolution service, and integrating the domain name system toolkit will support the domain name system cloud resolution service using the internal server and the external server of the cluster.
[0055] It should be noted that the steps of steps S11 to S14 of the present application are completed by running the target code, and the target code is the code obtained by pre-modifying the Designate-related chart deployment code in k8s-based openstack. It should be noted that Helm is a client tool under the command line. It is mainly used for the creation, packaging, release of Kubernetes application charts, and the creation and management of local and remote chart repositories. A chart is the application packaging format of Helm. A chart consists of a series of files that describe the resources required when deploying an application in Kubernetes.
[0056] It can be seen that this application determines whether the Domain Name System (DNS) server required by the cloud platform is an internal server within the cluster or an external server outside the cluster; the cluster is a cluster of DNS servers within the cloud platform; if it is an external server outside the cluster, the target pool corresponding to the DNS cloud resolution service is filled based on the external server outside the cluster, so that the external server outside the cluster has the function of performing the DNS cloud resolution service; if it is an internal server within the cluster, any pre-specified deployed node of the internal server within the cluster is started as the target server, and the target pool is filled based on the target server, so that the target server has the function of performing the DNS cloud resolution service; based on the pre-obtained container image, the DNS cloud resolution service is performed using the target server or the external server outside the cluster to complete the deployment of the DNS cloud resolution service; the container image is an image that integrates the designate function code and the DNS toolkit in the selected base image and supports the DNS cloud resolution service and the use of the internal server within the cluster and the external server outside the cluster to perform the DNS cloud resolution service. Thus, it can be seen that since the container image of this application supports the use of the internal server within the cluster and the external server outside the cluster to perform the DNS cloud resolution service, it is possible to determine whether the DNS server to be used is an internal server within the cluster or an external server outside the cluster, and enable the target server or the external server outside the cluster to have the function of performing the DNS cloud resolution service, so that it is possible to use the internal server within the cluster (the server within the cloud platform) to perform the DNS cloud resolution service, and it is also possible to use the external server outside the cluster (the server outside the cloud platform) to perform the DNS cloud resolution service.
[0057] See Figure 2 As shown, an embodiment of this application discloses a specific method for deploying a DNS cloud resolution service, which is applied to a cloud platform. The method includes:
[0058] Step S21: Create an endpoint corresponding to the DNS cloud resolution service for communicating with the message queue and the database, start the first service, second service, third service, and fourth service of the DNS cloud resolution, and then determine whether the DNS server required by the cloud platform is an internal server within the cluster or an external server outside the cluster.
[0059] In the embodiment of this application, the message queue is rabbitmq, the endpoint is endpoint, and the first service, second service, third service, and fourth service are the api service (i.e., the call interface service), the central service, the producter service, and the mdns service, respectively.
[0060] In the embodiment of the present application, before creating the endpoint corresponding to the domain name system cloud resolution service for communicating with the message queue and the database, it further includes: determining whether it is necessary to enable the domain name system cloud resolution service, and based on the determination result, turning on or off the deployment process according to the switch for whether to deploy the domain name system cloud resolution service added in the global control file in advance. It should be noted that by adding a control switch for the cloud resolution service in the deployment code, the flexibility of deployment is increased.
[0061] Step S22: If it is an external server of the cluster, fill the target pool corresponding to the domain name system cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service.
[0062] Among them, for a more specific processing procedure of step S22, reference can be made to the corresponding content disclosed in the foregoing embodiment, and details will not be elaborated here.
[0063] Step S23: If it is an internal server of the cluster, start any one of the internal servers of the cluster designated in advance as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the domain name system cloud resolution service.
[0064] Among them, for a more specific processing procedure of step S23, reference can be made to the corresponding content disclosed in the foregoing embodiment, and details will not be elaborated here.
[0065] Step S24: Start the fifth service of the domain name system cloud resolution service; based on the container image obtained in advance and stored in the private repository of the cloud platform, and use the target server or the external server of the cluster to perform the domain name system cloud resolution service to complete the deployment of the domain name system cloud resolution service; the container image is an image that integrates the designate function code and the domain name system toolkit in the selected base image and supports the domain name system cloud resolution service and the use of the internal server and the external server of the cluster to perform the domain name system cloud resolution service.
[0066] In the embodiment of the present application, the fifth service is the Worker service, and after the container image is obtained, it is pushed to the private repository of the openstack cloud platform.
[0067] In the embodiments of the present application, before starting the first service, second service, third service, and fourth service for the domain name system cloud resolution, it further includes: respectively specifying, in advance through an inventory file, the first service, the second service, the third service, the fourth service, and the fifth service of the domain name system cloud resolution, as well as the deployment nodes of several internal cluster servers for performing the domain name system cloud resolution service. It should be noted that only when the deployment nodes are set can these services be truly put into use.
[0068] It can be seen that since the container image in the present application supports using the internal cluster servers and the external cluster servers for the domain name system cloud resolution service, it is possible to determine whether the domain name system server that can be used is an internal cluster server or an external cluster server, and enable the target server or the external cluster server to have the function of performing the domain name system cloud resolution service, so that it is possible to use the internal cluster servers (servers within the cloud platform) for the domain name system cloud resolution service, and it is also possible to use the external cluster servers (servers outside the cloud platform) for the domain name system cloud resolution service.
[0069] See Figure 3 As shown, it is a schematic diagram of the preparatory work for the deployment of the domain name system cloud resolution service. Step 1: Select centos8.2 as the base image for the designate and DNS server container images; Step 2: Integrate the designate function code, Bind9, and PowerDNS4 installation packages into the base image to make the image support both DNS cloud resolution and DNS server functions; Step 3: Push the image to the private repository of the openstack cloud platform; Step 4: Add a switch in the global control file to determine whether to deploy the DNS cloud resolution service; Step 5: Specify the deployment nodes of the API, Producer, Central, Worker, MiniDNS services, and DNS server service for the cloud resolution function through the inventory file; finally, the startup process of the DNS cloud resolution service will be designed. Specifically, Steps 1 to 3 are operations on the image. Starting from Step 4, the relevant chart deployment code of Designate in openstack based on k8s is modified to enable the DNS cloud resolution service to support docking with internal and external DNS servers in the cloud platform, that is, to enable internal and external DNS servers in the cloud platform to perform DNS cloud resolution services.
[0070] It should be noted that the present application selects centos8.2 as the base image and integrates the designate function code and BIND9, PowerDNS4 installation packages into the base image to ensure that a container image can support both DNS cloud resolution and DNS server functions.
[0071] See Figure 4 As shown, it is a schematic diagram of the deployment process of the domain name system cloud resolution service. Step 1: Determine whether the cloud platform needs to enable the DNS cloud resolution service; Step 2: Create an endpoint (endpoint) of the designate module (which can be understood as the module corresponding to the DNS cloud resolution service) responsible for communicating with rabbitmq and the database; Step 3: Determine whether the DNS server docked by the cloud platform is a server inside the cluster or a server outside the cluster; Step 4: If the cluster docks with an external DNS server, configure the internal DNS server status as no, map the rndc.key file of the external DNS server to configmap, start the worker-init job and mount the external dns rndc.key configmap, and fill the designate pool; If the cluster docks with an internal DNS server, configure the internal DNS server status as yes, start the DNS server pod as the internal DNS server, start the worker-init job to fill the designate pool; Step 5: Start the worker pod and the designate (cloud resolution) starts to serve.
[0072] In summary, this application selects centos8.2 as the base image, integrates the designate function code and BIND9 and PowerDNS4 installation packages in the base image to ensure that a container image can support both DNS cloud resolution and DNS server functions. By adding a control switch for the cloud resolution service in the deployment code, the flexibility of deployment is increased. Add a designate group in the inventory file to specify the deployment nodes of each designate service. In addition, during the startup process of the designate service, create an endpoint for the service, establish connections with the database and rabbitmq, determine the type of the actual DNS server, respectively perform the docking of the external DNS server or the startup and docking of the internal DNS server service, and finally start the designate worker service to work. Ensure that the DNS cloud resolution function has the ability to dock with internal and external DNS servers during use.
[0073] It should be noted that a complete deployment method for the DNS cloud resolution service of the cloud platform is implemented. By integrating designate and the DNS toolkit in the container image, an image that supports both DNS cloud resolution and DNS server functions is constructed. During the deployment, it is possible to choose to dock with an internal or external DNS server according to the actual situation on-site and populate the designate pool. This greatly reduces the deployment complexity of the cloud platform, improves the on-site delivery ability of the cloud platform, and reduces the work complexity of the implementers.
[0074] See Figure 5 As shown, an embodiment of the present application discloses a deployment device for the DNS cloud resolution service, which is applied to a cloud platform and includes:
[0075] A judgment module 11, configured to judge whether the DNS server required by the cloud platform is an internal server of the cluster or an external server of the cluster; the cluster is a cluster of DNS servers within the cloud platform;
[0076] A first filling module 12, configured to, if it is an external server of the cluster, fill the target pool corresponding to the DNS cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the DNS cloud resolution service;
[0077] A second filling module 13, configured to, if it is an internal server of the cluster, start any one of the internal servers of the cluster designated in advance as the target server, and fill the target pool based on the target server, so that the target server has the function of performing the DNS cloud resolution service;
[0078] A resolution service module 14, configured to, based on a pre-obtained container image, and use the target server or the external server of the cluster to perform the DNS cloud resolution service to complete the deployment of the DNS cloud resolution service; the container image is an image obtained by integrating the designate function code and the DNS toolkit in a selected base image, which supports the DNS cloud resolution service and supports using the internal server of the cluster and the external server of the cluster to perform the DNS cloud resolution service.
[0079] Among them, for the more specific working processes of the above-mentioned various modules, reference can be made to the corresponding content disclosed in the foregoing embodiments, and details will not be elaborated here.
[0080] It can be seen that since the container image of the present application supports using the internal servers and external servers of the cluster for the domain name system cloud resolution service, it can determine whether the domain name system server to be used is an internal server or an external server of the cluster, and enable the target server or the external server of the cluster to have the function of performing the domain name system cloud resolution service, so that the internal server of the cluster (the server within the cloud platform) can be used for the domain name system cloud resolution service, and the external server of the cluster (the server outside the cloud platform) can also be used for the domain name system cloud resolution service.
[0081] Further, an embodiment of the present application also provides an electronic device. Figure 6 It is a structural diagram of an electronic device 20 shown according to an exemplary embodiment, and the content in the figure should not be considered as any limitation to the scope of use of the present application.
[0082] Figure 6 It is a schematic structural diagram of an electronic device 20 provided by an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, an input / output interface 24, a communication interface 25, and a communication bus 26. Among them, the memory 22 is used to store a computer program, and the computer program is loaded and executed by the processor 21 to implement the relevant steps of the domain name system cloud resolution service deployment method disclosed in any of the foregoing embodiments.
[0083] In this embodiment, the power supply 23 is used to provide working voltage for each hardware device on the electronic device 20; the communication interface 25 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows is any communication protocol applicable to the technical solution of the present application, and no specific limitation is made here; the input / output interface 24 is used to obtain external input data or output data to the outside, and its specific interface type can be selected according to specific application needs, and no specific limitation is made here.
[0084] In addition, as a carrier for resource storage, the memory 22 can be a read-only memory, a random access memory, a disk, or an optical disc, etc. The memory 22 can include a random access memory as the running memory and a non-volatile memory for storage purposes of external memory. The storage resources thereon include an operating system 221, a computer program 222, etc., and the storage method can be temporary storage or permanent storage.
[0085] Among them, the operating system 221 is used to manage and control each hardware device and computer program 222 on the electronic device 20 on the source host. The operating system 221 can be Windows, Unix, Linux, etc. In addition to the computer program that can be used to complete the deployment method of the domain name system cloud resolution service executed by the electronic device 20 disclosed in any of the foregoing embodiments, the computer program 222 can further include computer programs that can be used to complete other specific tasks.
[0086] In this embodiment, the input / output interface 24 may specifically include, but is not limited to, a USB interface, a hard disk reading interface, a serial interface, a voice input interface, a fingerprint input interface, etc.
[0087] Furthermore, an embodiment of the present application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, the deployment method of the domain name system cloud resolution service disclosed above is implemented.
[0088] For the specific steps of this method, reference can be made to the corresponding content disclosed in the foregoing embodiments, and details will not be repeated here.
[0089] The computer-readable storage medium mentioned here includes random access memory (RAM), memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, magnetic disks, or optical disks, or any other form of storage medium well-known in the technical field. Among them, when the computer program is executed by a processor, the deployment method of the foregoing domain name system cloud resolution service is implemented. For the specific steps of this method, reference can be made to the corresponding content disclosed in the foregoing embodiments, and details will not be repeated here.
[0090] In this specification, the various embodiments are described in a progressive manner. The key point of each embodiment is to illustrate the differences from other embodiments. For the same or similar parts among the various embodiments, reference can be made to each other. For the device disclosed in the embodiment, since it corresponds to the deployment method of the domain name system cloud resolution service disclosed in the embodiment, the description is relatively simple. For the relevant parts, reference can be made to the description in the method part.
[0091] Those skilled in the art may further realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. To clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described according to functions in the above description. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of this application.
[0092] The steps of the algorithms described in combination with the embodiments disclosed herein can be directly implemented by hardware, software modules executed by a processor, or a combination of the two. The software modules can be placed in a random access memory (RAM), internal memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, removable disks, CD-ROMs, or any other form of storage medium known in the art.
[0093] Finally, it should also be noted that in this text, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the term "comprising", "including" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements not only includes those elements, but also includes other elements not expressly listed, or elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "comprising one..." does not exclude the presence of additional identical elements in the process, method, article or device comprising the element.
[0094] The above has introduced in detail a method, apparatus, device and medium for deploying a domain name system cloud resolution service provided by the present invention. Specific examples are used herein to illustrate the principle and implementation manner of the present invention. The description of the above embodiments is only used to help understand the method and its core idea of the present invention; at the same time, for those of ordinary skill in the art, according to the idea of the present invention, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present invention.
Claims
1. A deployment method for a domain name system cloud resolution service, characterized in that, Applied to a cloud platform, including: Determine whether the Domain Name System (DNS) server required by the cloud platform is an internal server within the cluster or an external server outside the cluster; the cluster is a cluster of DNS servers within the cloud platform; If it is an external server outside the cluster, fill the target pool corresponding to the DNS cloud resolution service based on the external server outside the cluster, so that the external server outside the cluster has the function of performing the DNS cloud resolution service; If it is an internal server within the cluster, start any pre-specified deployed node of the internal server within the cluster as the target server, map the second configuration file of the target server to the second ConfigMap, and mount the second ConfigMap to fill the target pool, so that the target server has the function of performing the DNS cloud resolution service; Based on the pre-acquired container image, and use the target server or the external server outside the cluster to perform the DNS cloud resolution service to complete the deployment of the DNS cloud resolution service; the container image is an image that integrates the designate function code and the DNS toolkit in the selected base image and supports the DNS cloud resolution service and the use of the internal server within the cluster and the external server outside the cluster to perform the DNS cloud resolution service.
2. The deployment method of the domain name system cloud resolution service according to claim 1, wherein The determination of whether the DNS server required by the cloud platform is an internal server within the cluster or an external server outside the cluster includes: Create an endpoint corresponding to the DNS cloud resolution service for communicating with the message queue and the database, start the first service, the second service, the third service, and the fourth service of the DNS cloud resolution, and then determine whether the DNS server required by the cloud platform is an internal server within the cluster or an external server outside the cluster.
3. The deployment method of the domain name system cloud resolution service according to claim 2, characterized in that Before creating the endpoint corresponding to the DNS cloud resolution service for communicating with the message queue and the database, it further includes: Determine whether to enable the DNS cloud resolution service, and based on the judgment result, turn on or off the deployment process according to the switch of whether to deploy the DNS cloud resolution service added in the global control file in advance.
4. The deployment method of the domain name system cloud resolution service according to claim 2, characterized in that The use of the target server or the external server outside the cluster to perform the DNS cloud resolution service based on the pre-acquired container image includes: Start the fifth service of the DNS cloud resolution service; Based on the container image pre-acquired and stored in the private repository of the cloud platform, and use the target server or the external server outside the cluster to perform the DNS cloud resolution service.
5. The deployment method of the domain name system cloud resolution service according to claim 4, wherein Before starting the first service, the second service, the third service, and the fourth service of the DNS cloud resolution, it further includes: Pre-specify the first service, the second service, the third service, the fourth service, and the fifth service of the DNS cloud resolution, and the deployment nodes of several internal servers within the cluster for performing the DNS cloud resolution service through the inventory file respectively.
6. The deployment method of the domain name system cloud resolution service according to any one of claims 1 to 5, characterized in that, If it is an external server of the cluster, the target pool corresponding to the domain name system cloud resolution service is populated based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service, including: If it is an external server of the cluster, configure the status of the internal server of the cluster to the deactivated state, map the first configuration file of the external server of the cluster to the first ConfigMap, and then mount the first ConfigMap to populate the target pool corresponding to the domain name system cloud resolution service, so that the external server of the cluster has the function of performing the domain name system cloud resolution service.
7. The deployment method of the domain name system cloud resolution service according to any one of claims 1 to 5, characterized in that If it is an internal server of the cluster, start the internal server of the cluster at any pre-specified deployment node as the target server, including: If it is an internal server of the cluster, configure the status of the internal server of the cluster to the used state, and start the internal server of the cluster at any pre-specified deployment node as the target server.
8. A deployment device for a domain name system cloud resolution service, characterized in that, Applied to a cloud platform, including: A judgment module for judging whether the domain name system server required by the cloud platform is an internal server or an external server of the cluster; the cluster is a cluster of domain name system servers within the cloud platform; A first population module for, if it is an external server of the cluster, populating the target pool corresponding to the domain name system cloud resolution service based on the external server of the cluster, so that the external server of the cluster has the function of performing the domain name system cloud resolution service; A second population module for, if it is an internal server of the cluster, starting the internal server of the cluster at any pre-specified deployment node as the target server, mapping the second configuration file of the target server to the second ConfigMap, and mounting the second ConfigMap to populate the target pool, so that the target server has the function of performing the domain name system cloud resolution service; A resolution service module for, based on a pre-acquired container image, using the target server or the external server of the cluster to perform the domain name system cloud resolution service to complete the deployment of the domain name system cloud resolution service; the container image is an image obtained by integrating the designate function code and the domain name system toolkit in a selected base image, supporting the domain name system cloud resolution service and supporting the use of the internal server and the external server of the cluster to perform the domain name system cloud resolution service.
9. An electronic device, characterized in that, Including a processor and a memory; wherein, when the processor executes the computer program stored in the memory, the deployment method of the domain name system cloud resolution service according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium, characterized in that, For storing a computer program; wherein, when the computer program is executed by a processor, the deployment method of the domain name system cloud resolution service according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Domain name information processing method and device, computer equipment and computer storage medium
CN112437170A
Domain name resolution for a hybrid cloud cluster
US20120173760A1