-
Notifications
You must be signed in to change notification settings - Fork 9
/
google-spanner.yml
230 lines (230 loc) · 6.88 KB
/
google-spanner.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
# Copyright 2018 the Service Broker Project Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http:#www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---
version: 1
name: csb-google-spanner
id: 528667ba-8e4e-11ea-954d-47e3237b9109
description: Beta - Fully managed, scalable, relational database service for regional and global application data.
display_name: Google Cloud Spanner (Beta)
image_url: file://service-images/csb.png
documentation_url: https://docs.vmware.com/en/Cloud-Service-Broker-for-VMware-Tanzu/index.html
provider_display_name: VMware
support_url: https://cloud.google.com/support/
tags: [gcp, spanner, beta]
plans:
- name: small
id: 706659ba-8e4f-11ea-a91e-4328fa08a19b
description: 'Beta - Single Node Spanner with 10 GB storage'
display_name: "small (Beta)"
properties:
num_nodes: 1
storage_gb: 10
- name: medium
id: 7564d13a-8e4f-11ea-ac11-5b314921fb4c
description: 'Beta - 2 Nodes Spanner with 20 GB storage'
display_name: "medium (Beta)"
properties:
num_nodes: 2
storage_gb: 10
- name: large
id: 7c172a64-8e4f-11ea-a471-731172c1c00f
description: 'Beta - 3 Nodes and Multi Region Spanner with 100 GB storage'
display_name: "large"
properties:
num_nodes: 3
storage_gb: 10
provision:
plan_inputs:
- field_name: num_nodes
required: true
type: integer
details: Minimum number of cores for service instance.
constraints:
maximum: 64
minimum: 1
- field_name: storage_gb
required: true
type: number
details: Size of storage volume for service instance.
constraints:
maximum: 4096
minimum: 10
user_inputs:
- field_name: config
type: string
details: The name of the instance's configuration
default: us-central1
- field_name: ddl
type: array
details: An optional list of DDL statements to run inside the newly created database.
default: []
- field_name: credentials
type: string
details: GCP credentials
default: ${config("gcp.credentials")}
- field_name: project
type: string
details: GCP project
default: ${config("gcp.project")}
- field_name: instance_name
type: string
details: Name for your spanner instance
default: csb-spanner-${request.instance_id}
constraints:
maxLength: 98
minLength: 6
pattern: ^[a-z][a-z0-9-]+$
- field_name: db_name
type: string
details: Name for your database
default: csb-spanner
constraints:
maxLength: 64
- field_name: region
type: string
details: The region of the spanner instance.
default: us-central1
constraints:
examples:
- us-central1
- asia-northeast1
pattern: ^[a-z][a-z0-9-]+$
# - field_name: authorized_network
# type: string
# details: The name of the Google Compute Engine network to which the instance is connected. If left unspecified, the network named 'default' will be used.
# default: default
# prohibit_update: true
# - field_name: authorized_network_id
# type: string
# details: The id of the Google Compute Engine network to which the instance is connected.
# default: ""
# prohibit_update: true
computed_inputs:
- name: labels
default: ${json.marshal(request.default_labels)}
overwrite: true
type: object
template_refs:
provider: terraform/spanner/provision/provider.tf
versions: terraform/spanner/provision/versions.tf
main: terraform/spanner/provision/main.tf
data: terraform/spanner/provision/data.tf
variables: terraform/spanner/provision/variables.tf
outputs: terraform/spanner/provision/outputs.tf
outputs:
- field_name: instance
type: string
details: The name of the instance.
- field_name: db_name
type: string
details: The name of the database.
bind:
plan_inputs: []
user_inputs:
- field_name: role
type: string
details: The role that should be applied.
default: roles/editor
- field_name: credentials
type: string
details: GCP credentials
default: ${config("gcp.credentials")}
- field_name: project
type: string
details: GCP project
default: ${config("gcp.project")}
computed_inputs:
- name: instance
type: string
default: ${instance.details["instance"]}
overwrite: true
- name: db_name
type: string
default: ${instance.details["db_name"]}
overwrite: true
- name: service_account_name
default: ${str.truncate(20, "pcf-binding-${request.binding_id}")}
overwrite: true
- name: service_account_display_name
default: ""
overwrite: true
template_refs:
main: terraform/spanner/bind/main.tf
data: terraform/spanner/bind/data.tf
provider: terraform/spanner/bind/provider.tf
variables: terraform/spanner/bind/variables.tf
outputs: terraform/spanner/bind/outputs.tf
versions: terraform/spanner/bind/versions.tf
outputs:
- required: true
field_name: Email
type: string
details: Email address of the service account.
- required: true
field_name: Name
type: string
details: The name of the service account.
constraints:
examples:
- pcf-spanner-ex312029
- required: true
field_name: PrivateKeyData
type: string
details: Service account private key data. Base64 encoded JSON.
- required: true
field_name: ProjectId
type: string
details: ID of the project that owns the service account.
constraints:
examples:
- my-project
maxLength: 30
minLength: 6
pattern: ^[a-z0-9-]+$
- required: true
field_name: UniqueId
type: string
details: Unique and stable ID of the service account.
constraints:
examples:
- "112447814736626230844"
- required: true
field_name: policy_etag
type: string
details: Unique and stable ID of the service account.
- required: true
field_name: binding_etag
type: string
details: Unique and stable ID of the service account.
- required: true
field_name: member_etag
type: string
details: Unique and stable ID of the service account.
- field_name: instance
type: string
details: The name of the instance.
- field_name: db_name
type: string
details: The name of the database.
- required: true
field_name: Credentials
type: string
details: Credentials of the service account.
examples:
- name: small configuration
description: Create a small spanner instance
plan_id: 706659ba-8e4f-11ea-a91e-4328fa08a19b
provision_params: {}
bind_params: {}
bind_can_fail: true