Skip to content

Commit e45e306

Browse files
authored
chore: migrate for api change (#113)
1 parent 2fcdc47 commit e45e306

File tree

32 files changed

+111
-131
lines changed

32 files changed

+111
-131
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ using Terraform Bytebase Provider to prepare those instances ready for applicati
1717

1818
- [Go](https://golang.org/doc/install) (1.19 or later)
1919
- [Terraform](https://developer.hashicorp.com/terraform/downloads?product_intent=terraform) (1.3.5 or later)
20-
- [Bytebase](https://github.com/bytebase/bytebase) (3.6.0 or later)
20+
- [Bytebase](https://github.com/bytebase/bytebase) (3.7.0 or later)
2121

2222
> If you have problems running `terraform` in MacOS with Apple Silicon, you can following https://stackoverflow.com/questions/66281882/how-can-i-get-terraform-init-to-run-on-my-apple-silicon-macbook-pro-for-the-go and use the `tfenv`.
2323

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.6.2
1+
3.7.0

api/setting.go

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,5 @@
11
package api
22

3-
// SettingName is the Bytebase setting name without settings/ prefix.
4-
type SettingName string
5-
6-
const (
7-
// SettingWorkspaceApproval is the setting name for workspace approval config.
8-
SettingWorkspaceApproval SettingName = "bb.workspace.approval"
9-
// SettingWorkspaceProfile is the setting name for workspace profile settings.
10-
SettingWorkspaceProfile SettingName = "bb.workspace.profile"
11-
// SettingDataClassification is the setting name for data classification.
12-
SettingDataClassification SettingName = "bb.workspace.data-classification"
13-
// SettingSemanticTypes is the setting name for semantic types.
14-
SettingSemanticTypes SettingName = "bb.workspace.semantic-types"
15-
// SettingEnvironment is the setting name for environments.
16-
SettingEnvironment SettingName = "bb.workspace.environment"
17-
)
18-
193
// RiskLevel is the approval risk level.
204
type RiskLevel string
215

docs/data-sources/instance.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ The instance data source.
2828
- `activation` (Boolean) Whether assign license for this instance or not.
2929
- `data_sources` (Set of Object) (see [below for nested schema](#nestedatt--data_sources))
3030
- `databases` (Set of String) The databases full name in the resource.
31-
- `engine` (String) The instance engine. Support MYSQL, POSTGRES, TIDB, SNOWFLAKE, CLICKHOUSE, MONGODB, SQLITE, REDIS, ORACLE, SPANNER, MSSQL, REDSHIFT, MARIADB, OCEANBASE.
31+
- `engine` (String) The instance engine. Support MYSQL, POSTGRES, TIDB, SNOWFLAKE, CLICKHOUSE, MONGODB, SQLITE, REDIS, ORACLE, SPANNER, MSSQL, REDSHIFT, MARIADB, OCEANBASE, COCKROACHDB.
3232
- `engine_version` (String) The engine version.
3333
- `environment` (String) The environment name for your instance in "environments/{resource id}" format.
3434
- `external_link` (String) The external console URL managing this instance (e.g. AWS RDS console, your in-house DB instance console)

docs/data-sources/setting.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,6 @@ Read-Only:
184184

185185
Read-Only:
186186

187-
- `creator` (String)
188187
- `description` (String)
189188
- `steps` (List of Object) (see [below for nested schema](#nestedobjatt--approval_flow--rules--flow--steps))
190189
- `title` (String)

docs/resources/instance.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ The instance resource.
1818
### Required
1919

2020
- `data_sources` (Block Set, Min: 1) The connection for the instance. You can configure read-only or admin connection account here. (see [below for nested schema](#nestedblock--data_sources))
21-
- `engine` (String) The instance engine. Support MYSQL, POSTGRES, TIDB, SNOWFLAKE, CLICKHOUSE, MONGODB, SQLITE, REDIS, ORACLE, SPANNER, MSSQL, REDSHIFT, MARIADB, OCEANBASE.
21+
- `engine` (String) The instance engine. Support MYSQL, POSTGRES, TIDB, SNOWFLAKE, CLICKHOUSE, MONGODB, SQLITE, REDIS, ORACLE, SPANNER, MSSQL, REDSHIFT, MARIADB, OCEANBASE, COCKROACHDB.
2222
- `environment` (String) The environment full name for the instance in environments/{environment id} format.
2323
- `resource_id` (String) The instance unique resource id.
2424
- `title` (String) The instance title.
@@ -53,9 +53,9 @@ Optional:
5353
- `database` (String) The database for the instance, you can set this if the engine type is POSTGRES.
5454
- `external_secret` (Block List, Max: 1) The external secret to get the database password. Learn more: https://www.bytebase.com/docs/get-started/instance/#use-external-secret-manager (see [below for nested schema](#nestedblock--data_sources--external_secret))
5555
- `password` (String, Sensitive) The connection user password used by Bytebase to perform DDL and DML operations.
56-
- `ssl_ca` (String, Sensitive) The CA certificate. Optional, you can set this if the engine type is MYSQL, POSTGRES, TIDB, CLICKHOUSE or COCKROACHDB.
57-
- `ssl_cert` (String, Sensitive) The client certificate. Optional, you can set this if the engine type is MYSQL, POSTGRES, TIDB, CLICKHOUSE or COCKROACHDB.
58-
- `ssl_key` (String, Sensitive) The client key. Optional, you can set this if the engine type is MYSQL, POSTGRES, TIDB, CLICKHOUSE or COCKROACHDB.
56+
- `ssl_ca` (String, Sensitive) The CA certificate. Optional, you can set this if the engine type is MYSQL, POSTGRES, TIDB or CLICKHOUSE.
57+
- `ssl_cert` (String, Sensitive) The client certificate. Optional, you can set this if the engine type is MYSQL, POSTGRES, TIDB or CLICKHOUSE.
58+
- `ssl_key` (String, Sensitive) The client key. Optional, you can set this if the engine type is MYSQL, POSTGRES, TIDB or CLICKHOUSE.
5959
- `username` (String) The connection user name used by Bytebase to perform DDL and DML operations.
6060

6161
<a id="nestedblock--data_sources--external_secret"></a>

docs/resources/setting.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ Optional:
5454

5555
Required:
5656

57-
- `creator` (String) The creator name in users/{email} format
5857
- `steps` (Block List, Min: 1) Approval flow following the step order. (see [below for nested schema](#nestedblock--approval_flow--rules--flow--steps))
5958
- `title` (String)
6059

examples/database/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
terraform {
33
required_providers {
44
bytebase = {
5-
version = "3.6.0"
5+
version = "3.7.0"
66
# For local development, please use "terraform.local/bytebase/bytebase" instead
77
source = "registry.terraform.io/bytebase/bytebase"
88
}

examples/database_group/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
terraform {
22
required_providers {
33
bytebase = {
4-
version = "3.6.0"
4+
version = "3.7.0"
55
# For local development, please use "terraform.local/bytebase/bytebase" instead
66
source = "registry.terraform.io/bytebase/bytebase"
77
}

examples/environments/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ You should replace the provider initial variables with your own and exec the [se
88

99
```terraform
1010
data "bytebase_setting" "environments" {
11-
name = "bb.workspace.environment"
11+
name = "ENVIRONMENT"
1212
}
1313
```

0 commit comments

Comments
 (0)