Skip to content

Commit

Permalink
Merge pull request #247 from gridscale/bug/issue-#246
Browse files Browse the repository at this point in the history
Bug/issue #246
  • Loading branch information
ajfriesen authored Dec 12, 2023
2 parents bf359d6 + 928e6a7 commit 7cdf4a3
Show file tree
Hide file tree
Showing 9 changed files with 728 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test MySQL rs
name: Test MySQL8_0 rs

on:
workflow_dispatch:
Expand Down Expand Up @@ -39,5 +39,5 @@ jobs:
- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Run TestAccResourceGridscaleMySQL_Basic
run: make testacc TEST=./gridscale TESTARGS='-run=TestAccResourceGridscaleMySQL_Basic'
- name: Run TestAccResourceGridscaleMySQL8_0_Basic
run: make testacc TEST=./gridscale TESTARGS='-run=TestAccResourceGridscaleMySQL8_0_Basic'
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog


## 1.23.0 (Dec 12, 2023)

FEATURES:
- Add `griscale_mysql8_0` resource [PR #246](https://github.com/gridscale/terraform-provider-gridscale/issues/246)

IMPROVEMENTS:
- Add deprecation notice for `griscale_mysql` (MySQL 5.7)

## 1.22.0 (Sept 26, 2023)

FEATURES:
Expand Down
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,45 @@ To run a specific acceptance test, use `TESTARGS`.
TEST=./gridscale \
TESTARGS='-run=TestAccResourceGridscaleLoadBalancerBasic'

# Override local terraform provider for development

Create `local-dev.tfrc` with this content and change YOUR_USERNAME:

```
provider_installation {
# Use /Users/YOUR_USERNAME/github/terraform-provider-gridscale as an overridden package directory
# for the hashicorp/null provider. This disables the version and checksum
# verifications for this provider and forces Terraform to look for the
# null provider plugin in the given directory.
dev_overrides {
"gridscale/gridscale" = "/Users/YOUR_USERNAME/github/terraform-provider-gridscale/"
}
# For all other providers, install them directly from their origin provider
# registries as normal. If you omit this, Terraform will _only_ use
# the dev_overrides block, and so no other providers will be available.
direct {}
}
```

`export TF_CLI_CONFIG_FILE=./local-dev.tfrc`

Build the binary: `go build -o terraform-provider-gridscale`

Now you can run `terraform plan/apply` and terraform will tell you that you are using a local version of that provider:

```
> terraform apply
│ Warning: Provider development overrides are in effect
│ The following provider development overrides are set in the CLI configuration:
│ - gridscale/gridscale in /Users/YOUR_USERNAME/github/terraform-provider-gridscale
│ The behavior may therefore not match any released version of the provider and applying changes may cause the state to become incompatible with published
│ releases.
```

## Releasing the Provider

A [GoReleaser](https://goreleaser.com/) configuration is provided that produces build artifacts matching the [layout required](https://www.terraform.io/docs/registry/providers/publishing.html#manually-preparing-a-release) to publish the provider in the Terraform Registry.
Expand Down
1 change: 1 addition & 0 deletions gridscale/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ func Provider() *schema.Provider {
"gridscale_postgresql": resourceGridscalePostgreSQL(),
"gridscale_sqlserver": resourceGridscaleMSSQLServer(),
"gridscale_mysql": resourceGridscaleMySQL(),
"gridscale_mysql8_0": resourceGridscaleMySQL8_0(),
"gridscale_mariadb": resourceGridscaleMariaDB(),
"gridscale_memcached": resourceGridscaleMemcached(),
"gridscale_filesystem": resourceGridscaleFilesystem(),
Expand Down
Loading

0 comments on commit 7cdf4a3

Please sign in to comment.