42 lines
2.0 KiB
Plaintext
42 lines
2.0 KiB
Plaintext
---
|
|
layout: docs
|
|
page_title: Run Consul-Terraform-Sync
|
|
description: >-
|
|
Consul-Terraform-Sync requires a Terraform Provider, a Terraform Module and a running Consul Cluster outside of the `consul-terraform-sync` daemon.
|
|
---
|
|
|
|
# Run Consul-Terraform-Sync
|
|
|
|
This topic describes the basic procedure for running Consul-Terraform-Sync (CTS). Verify that you have met the [basic requirements](/consul/docs/nia/usage/requirements) before attempting to run CTS.
|
|
|
|
1. Move the `consul-terraform-sync` binary to a location available on your `PATH`.
|
|
|
|
```shell-session
|
|
$ mv ~/Downloads/consul-terraform-sync /usr/local/bin/consul-terraform-sync
|
|
```
|
|
|
|
2. Create the config.hcl file and configure the options for your use case. Refer to the [configuration reference](/consul/docs/nia/configuration) for details about all CTS configurations.
|
|
|
|
3. Run Consul-Terraform-Sync (CTS).
|
|
|
|
```shell-session
|
|
$ consul-terraform-sync start -config-file <config.hcl>
|
|
```
|
|
|
|
4. Check status of tasks. Replace port number if configured in Step 2. Refer to [Consul-Terraform-Sync API](/consul/docs/nia/api) for additional information.
|
|
|
|
```shell-session
|
|
$ curl localhost:8558/status/tasks
|
|
```
|
|
|
|
## Other Run modes
|
|
|
|
You can [configure CTS for high availability](/consul/docs/nia/usage/run-ha), which is an enterprise capability that ensures that all changes to Consul that occur during a failover transition are processed and that CTS continues to operate as expected.
|
|
|
|
You can start CTS in [inspect mode](/consul/docs/nia/cli/start#modes) to review and test your configuration before applying any changes. Inspect mode allows you to verify that the changes work as expected before running them in an unsupervised daemon mode.
|
|
|
|
For hands-on instructions on using inspect mode, refer to the [Consul-Terraform-Sync Run Modes and Status Inspection](/consul/tutorials/network-infrastructure-automation/consul-terraform-sync-run-and-inspect?utm_source=WEBSITE&utm_medium=WEB_IO&utm_offer=ARTICLE_PAGE&utm_content=DOCS) tutorial.
|
|
|
|
|
|
|