Introduction
The internal services that make up Terraform Enterprise use certain network addresses for communication. Terraform Enterprise expects these network addresses to be reserved exclusively for its own usage. These network addresses should not overlap with each other or any other network Terraform Enterprise is expected to communicate with.
By default, Terraform Enterprise uses the following IPv4 network addresses:
- Docker:
172.17.0.0/16,172.19.0.0/16,172.20.0.0/16 - Replicated:
172.18.0.0/16
Use Case
The default network addresses used by Terraform Enterprise may already be in use elsewhere on your network, causing connectivity issues. In such cases, you must change the network addresses that Terraform Enterprise uses.
Procedure
For installations of Terraform Enterprise, you can change the Docker and Replicated network addresses independently. This example details how to change the Docker network addresses to 10.10.0.0/16 and 10.11.0.0/16, and the Replicated network address to 10.12.0.0/16. If you are using different network addresses, please adjust the values accordingly.
Stop the Terraform Enterprise application.
# replicatedctl app stop
Ensure the Terraform Enterprise application is stopped. The output should show the
Stateasstopped.# replicatedctl app status
Stop the Replicated services.
# systemctl stop replicated replicated-ui replicated-operator
Stop all running Docker containers on the host.
# docker stop $(docker ps -q)
Delete the
replicated_retracedDocker network.# docker network rm replicated_retraced
For installations running version
v202104-1or greater, delete thetfe_servicesandtfe_terraform_isolationDocker networks.# docker network rm tfe_services # docker network rm tfe_terraform_isolation
Create a new
replicated_retracedDocker network using the desired network address.# docker network create replicated_retraced --subnet=10.12.0.0/16
Create the file
/etc/docker/daemon.jsonwith the following content.Note: The value of
bipis a network address, not just a subnet. Docker will use this IPv4 address as its bridge IP address, and the rest of the subnet will be for containers that Docker creates.{ "bip": "10.10.0.1/16", "default-address-pools": [ { "base": "10.11.0.0/16", "size": 24 } ] }Restart the Docker service.
# systemctl restart docker
Start the Replicated services.
# systemctl start replicated replicated-ui replicated-operator
Start the Terraform Enterprise application.
# replicatedctl app start
Verification
Ensure the Terraform Enterprise application has started successfully. The output should show the State as started.
# replicatedctl app status