add script for syncing docs
This commit is contained in:
@ -1,3 +1,4 @@
|
||||
---
|
||||
documents:
|
||||
- html_location: docs/antiddos/api-ref
|
||||
pdf_name: antiddos-api-ref
|
||||
@ -956,6 +957,9 @@ services:
|
||||
- repo: docs/elastic-cloud-server
|
||||
type: gitea
|
||||
environment: internal
|
||||
- repo: opentelekomcloud-docs/elastic-cloud-server
|
||||
type: github
|
||||
environment: public
|
||||
service_category: compute
|
||||
service_title: Elastic Cloud Server
|
||||
service_type: ecs
|
||||
@ -993,7 +997,8 @@ services:
|
||||
type: gitea
|
||||
environment: internal
|
||||
service_category: database
|
||||
service_title: GaussDB Enterprise-class Distributed Database compatible with MySQL
|
||||
service_title: |
|
||||
GaussDB Enterprise-class Distributed Database compatible with MySQL
|
||||
service_type: gaussdb_mysql
|
||||
- repositories:
|
||||
- environment: internal
|
||||
@ -1063,7 +1068,8 @@ services:
|
||||
repo: docs/gaussdb-opengauss
|
||||
type: gitea
|
||||
service_category: database
|
||||
service_title: GaussDB Enterprise-grade Relational Database on the openGauss ecosystem
|
||||
service_title: |
|
||||
GaussDB Enterprise-grade Relational Database on the openGauss ecosystem
|
||||
service_type: opengauss
|
||||
- repositories:
|
||||
- environment: internal
|
||||
|
@ -141,6 +141,17 @@ class Services(object):
|
||||
res.append(res_doc)
|
||||
return res
|
||||
|
||||
def docs_by_service_type(self, service_type):
|
||||
"""List documents of the service
|
||||
|
||||
:param str service_type: Service type
|
||||
:returns: generator for documents
|
||||
"""
|
||||
for doc in self.all_docs:
|
||||
if doc["service_type"] != service_type:
|
||||
continue
|
||||
yield copy.deepcopy(doc)
|
||||
|
||||
def all_docs_full(self, environment):
|
||||
"""Return list or documents with full service data
|
||||
"""
|
||||
|
Reference in New Issue
Block a user