-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1160 from weaveworks/docs-edits-dec5
Changes URLs for better SEO and fixes small typos
- Loading branch information
Showing
48 changed files
with
289 additions
and
228 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...tect_drifts_only_without_plan_or_apply.md → ...tect-drifts-only-without-plan-or-apply.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
docs/how_to/flux_receiver_and_alert.md → ...-tf-controller/flux-receiver-and-alert.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...oller/to_force_unlock_Terraform_states.md → ...ntroller/force-unlock-terraform-states.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Use TF-controller | ||
|
||
- [Use TF-controller to provision resources and **auto approve**](provision-resources-and-auto-approve.md) | ||
- [Use TF-controller to **plan and manually apply** Terraform resources](plan-and-manually-apply-terraform-resources.md) | ||
- [Use TF-controller to provision resources and **obtain outputs**](provision-resources-obtain-outputs.md) | ||
- [Use TF-controller to **detect drifts only** without plan or apply](detect-drifts-only-without-plan-or-apply.md) | ||
- [Use TF-controller with **drift detection disabled**](with-drift-detection-disabled.md) | ||
- [Use TF-controller with **AWS EKS IRSA**](with-aws-eks-irsa.md) | ||
- [Use TF-controller to **set variables** for Terraform resources](set-variables-for-terraform-resources.md) | ||
- [Use TF-controller with a **custom backend**](with-a-custom-backend.md) | ||
- [Use TF-controller with an **OCI Artifact as Source**](with-an-oci-artifact-as-source.md) | ||
- [Use TF-controller to provision Terraform resources that are required **health checks**](provision-Terraform-resources-that-are-required-health-checks.md) | ||
- [Use TF-controller to provision resources and **destroy them when the Terraform object gets deleted**](provision-resources-and-destroy-them-when-terraform-object-gets-deleted.md) | ||
- [Use TF-controller to **force unlock** Terraform states](force-unlock-terraform-states.md) | ||
- [Use TF-controller with Terraform Runners enabled via Env Variables](with-tf-runner-logging.md) | ||
- [Use TF-controller to provision resources with **customized Runner Pods**](provision-resources-with-customized-runner-pods.md) | ||
- [Use TF-controller with **Terraform Enterprise**](integration-with-terraform-enterprise-or-cloud.md) | ||
- [Use TF-controller with **primitive modules**](with-primitive-modules.md) | ||
- [Use TF-controller with **GitOps dependency management**](with-gitops-dependency-management.md) | ||
- [Use TF-controller with **the ready-to-use AWS package**](with-the-ready-to-use-aws-package.md) | ||
- [User TF-controller with **plan-only mode**](with-plan-only-mode.md) | ||
- [Use TF-controller with **external webhooks**](with-external-webhooks.md) | ||
- [Use TF-controller with Terraform Runners **exposed via hostname/subdomain**](with-tf-runner-exposed-using-hostname-subdomain.md) | ||
- [How to **backup and restore** a Terraform state](backup-and-restore-a-Terraform-state.md) | ||
- [How to **build and use** a custom runner image](build-and-use-a-custom-runner-image.md) | ||
- [How to integrate with Flux Receivers and Alerts?](flux-receiver-and-alert.md) | ||
- [How does the interval and retryInterval work?](interval-and-retryInterval.md) | ||
- [How does the resource deletion work?](resource-deletion.md) | ||
- [How to troubleshoot with **Break the Glass** mode](troubleshooting-with-break-the-glass-mode.md) | ||
- [How to enable cross-namespace references](use-cross-namespace-refs.md) | ||
- [How to run TF-controller in Azure Kubernetes Service](with-azure.md) | ||
- [How to upgrade TF-controller to a newer version](upgrade-tf-controller.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
docs/how_to/interval_and_retryInterval.md → ...-controller/interval-and-retryInterval.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
60 changes: 60 additions & 0 deletions
60
docs/use-tf-controller/plan-and-manually-apply-terraform-resources.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
# Use TF-controller to plan and manually apply Terraform resources | ||
|
||
Assume that you have a `GitRepository` object named `helloworld` pointing to a Git repository, and you want to plan and apply the Terraform resources under `./` of that Git repo. Let's walk through the steps of using TF-Controller to plan and | ||
manually apply Terraform resources. | ||
|
||
- Create a `Terraform` object and set the necessary fields in the spec: | ||
- `approvePlan`, which sets the mode. For plan and manual approval mode, either keep this field blank or omit it entirely. | ||
- `interval`, which determines how often TF-Controller will run the Terraform configuration | ||
- `path`, which specifies the location of the configuration files, in this case `./` | ||
- `sourceRef`, which points to the `helloworld` GitRepository object | ||
- Once this object is created, use kubectl to obtain the `approvePlan` value and set it in the `Terraform` object. | ||
- After making our changes and pushing them to the Git repository, TF-Controller will apply the plan and create the real resources. | ||
|
||
Here is an example: | ||
|
||
```yaml hl_lines="7" | ||
apiVersion: infra.contrib.fluxcd.io/v1alpha2 | ||
kind: Terraform | ||
metadata: | ||
name: helloworld | ||
namespace: flux-system | ||
spec: | ||
approvePlan: "" # or you can omit this field | ||
interval: 1m | ||
path: ./ | ||
sourceRef: | ||
kind: GitRepository | ||
name: helloworld | ||
namespace: flux-system | ||
``` | ||
## View the approval message | ||
After a reconciliation loop, TF-Controller will generate a plan. Run this command to receive the `.spec.approvePlan` value from TF-Controller, which you'll need to approve the plan: | ||
|
||
```bash | ||
kubectl -n flux-system get tf/helloworld | ||
``` | ||
|
||
This value enables you to edit the Terraform object file and set the `spec.approvePlan` field | ||
to the value obtained from the message. | ||
|
||
After making your changes and pushing them to the Git repository, | ||
TF-Controller will apply the plan and create the real resources. | ||
|
||
```yaml hl_lines="7" | ||
apiVersion: infra.contrib.fluxcd.io/v1alpha2 | ||
kind: Terraform | ||
metadata: | ||
name: hello-world | ||
namespace: flux-system | ||
spec: | ||
approvePlan: plan-main-b8e362c206 # first 8 digits of a commit hash is enough | ||
interval: 1m | ||
path: ./ | ||
sourceRef: | ||
kind: GitRepository | ||
name: helloworld | ||
namespace: flux-system | ||
``` |
2 changes: 1 addition & 1 deletion
2
...ources_that_are_required_health_checks.md → ...ources-that-are-required-health-checks.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.