You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Terraform](https://www.terraform.io/) is an infrastructure automation tool to provision and manage resources in clouds or data centers. To deploy Charmed MySQL using Terraform and Juju, you can use the [Juju Terraform Provider](https://registry.terraform.io/providers/juju/juju/latest).
5
-
6
-
The easiest way is to start from [these examples of terraform modules](https://github.com/canonical/terraform-modules) prepared by Canonical. This page will guide you through a deployment using an example module for MySQL on machines.
4
+
[Terraform](https://www.terraform.io/) is an infrastructure automation tool to provision and manage resources in clouds or data centers.
5
+
To deploy Charmed MySQL using Terraform and Juju, you can use the [Juju Terraform Provider](https://registry.terraform.io/providers/juju/juju/latest).
7
6
8
7
For an in-depth introduction to the Juju Terraform Provider, read [this Discourse post](https://discourse.charmhub.io/t/6939).
9
8
10
-
```{note}
11
-
Storage support was added in [Juju Terraform Provider version 0.13+](https://github.com/juju/terraform-provider-juju/releases/tag/v0.13.0).
12
-
```
13
-
14
9
## Install Terraform tooling
15
10
16
-
This guide assumes Juju is installed and you have an LXD controller already bootstrapped. For more information, check the [Charmed MySQL tutorial](/tutorial/index).
11
+
This guide assumes Juju is installed, and you have an LXD controller already bootstrapped. For more information, check the [Charmed MySQL tutorial](/tutorial/index).
17
12
18
13
Let's install Terraform Provider and example modules:
19
14
```shell
20
15
sudo snap install terraform --classic
21
16
```
17
+
22
18
Switch to the LXD provider and create a new model:
23
19
```shell
24
20
juju switch lxd
25
21
juju add-model my-model
26
22
```
27
-
Clone examples and navigate to the MySQL machine module:
23
+
24
+
Clone the MySQL operator repository and navigate to the terraform module:
juju_application.mysql_server: Destruction complete after 0s
153
133
154
134
Destroy complete! Resources: 1 destroyed.
155
135
```
156
-
---
157
-
```{note}
158
-
For more examples of Terraform modules for VM, see the other directories in the [`terraform-modules` repository](https://github.com/canonical/terraform-modules/tree/main/modules/machine).
159
-
```
160
136
161
-
Feel free to [contact us](/reference/contacts) if you have any question and [collaborate with us on GitHub](https://github.com/canonical/terraform-modules)!
137
+
---
162
138
139
+
Feel free to [contact us](/reference/contacts) if you have any question and collaborate with us on GitHub!
0 commit comments