Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.8/site-packages/c7n_gcp/resources/secret.py: 100%

15 statements  

« prev     ^ index     » next       coverage.py v7.3.2, created at 2023-12-08 06:51 +0000

1# Copyright The Cloud Custodian Authors. 

2# SPDX-License-Identifier: Apache-2.0 

3from c7n_gcp.provider import resources 

4from c7n_gcp.query import (QueryResourceManager, TypeInfo) 

5 

6 

7@resources.register('secret') 

8class Secret(QueryResourceManager): 

9 """GCP resource: https://cloud.google.com/secret-manager/docs/reference/rest/v1 

10 """ 

11 class resource_type(TypeInfo): 

12 service = 'secretmanager' 

13 version = 'v1' 

14 component = 'projects.secrets' 

15 enum_spec = ('list', 'secrets[]', None) 

16 scope = 'project' 

17 scope_key = 'parent' 

18 scope_template = "projects/{}" 

19 name = id = "name" 

20 asset_type = "secretmanager.googleapis.com/Secret" 

21 default_report_fields = ['name', 'createTime', 'expireTime', 'ttl']