# 5. Upgrading/Maintaining RoostGPT Control-plane

There are multiple options available to refresh or upgrade the RoostGPT stack. The infrastructure engineer can use either of these approaches.

##### a. Using Terraform Script to upgrade RoostGPT version

Update Terraform Variables in ["terraform.tfvars"](https://docs.roost.ai/topics/roostgpt/page/4-terraform-variables) to reflect the appropriate Roost Version

<table border="1" id="bkmrk-field-values-roost_v" style="border-collapse: collapse; width: 100%;"><colgroup><col style="width: 50.0596%;"></col><col style="width: 50.0596%;"></col></colgroup><tbody><tr><td class="align-center">**Field**

</td><td class="align-center">**Values**</td></tr><tr><td>roost\_version

</td><td>v1.1.17</td></tr></tbody></table>

Run below commands:

```bash
terraform apply
```

##### b. Using Terraform Script to refresh control-plane (without any config change)

Run below commands

```bash
terraform apply --replace="null_resource.provision-controlplane-system" --replace="null_resource.provision-roostgpt-server" --replace="null_resource.run-controlplane-services"
```

##### c. Using SSH to control-plane instance

RoostGPT control-plane runs a docker [compose script ](https://docs.roost.ai/topics/trying-roostgpt/page/docker-compose)and the entire offering can be updated using the below given steps.

- SSH Connect to your infrastructure bastion instance as ubuntu user
- Execute the below snippet with the appropriate Roost Version (after replacing v1.1.17)

```bash
ssh cp "ROOST_VER='v1.1.17' /var/tmp/Roost/bin/roost-enterprise.sh -c /var/tmp/Roost/config.json -i roostai"
```