> Note: For mdm testing, where a SCEP CHALLENGE secret is required, you will need to fetch the details from the database [using this script](https://github.com/fleetdm/fleet/blob/main/tools/mdm/assets/main.go) and passing it in as an `extra_flag` when triggering an osquery\_perf deployment.
>
> Requires:
> - VPN connection
> - Database access
Example:
```
["--mdm_scep_challenge", "<value>"]
```
Additional parameters can be passed in (and not limited to):
4. After all details have been filled out, you will hit the green `Run Workflow` button, directly under the inputs. For `terraform_action` select `Plan`, `Apply`, or `Destroy`.
3. Create a new the terraform workspace or select an existing workspace for your environment. The terraform workspace will be used in different area's of Terraform to drive uniqueness and access to the environment.
> Note: The workspace from the infrastructure deployment will not be carried over to this deployment. A new or existing workspace, specifically for osquery perf must be used.
>
> Your workspace name must match the workspace name that was used for the infrastructure deployment. Failure to use a matching workspace name can lead to deployments in another environment.
```sh
terraform workspace new <workspace_name>
```
or, if your workspace already exists
```sh
terraform workspace list
terraform workspace select <workspace_name>
```
4. Ensure that your new or existing workspace is in use.
```sh
terraform workspace show
```
5. Deploy the environment (will also trigger migrations automatically)
> Note: Terraform will prompt you for confirmation to trigger the deployment. If everything looks ok, submitting `yes` will trigger the deployment.
or, you can add the additional supported terraform variables, to overwrite the default values. You can choose which ones are included/overwritten. If a variable is not defined, the default value configured in [./variables.tf](variables.tf) is used.
> Note: For mdm testing, where a SCEP CHALLENGE secret is required, you will need to fetch the details from the database [using this script](https://github.com/fleetdm/fleet/blob/main/tools/mdm/assets/main.go) and passing it in as an `extra_flag` when triggering an osquery\_perf deployment.
>
> Requires:
> - VPN connection
> - Database access
Example with the SCEP CHALLENGE secret as an extra\_flag:
6. If you'd like to deploy osquery\_perf tasks in batches, you can now run the original `enroll.sh` script, from the osquery\_perf directory. The script will deploy in batches of 8, every 60 seconds, so it's recommended to set your starting index and max number of osquery perf containers as a multiple of 8.
| <aname="input_extra_flags"></a> [extra\_flags](#input\_extra\_flags) | Comma delimited list (string) for passing extra flags to osquery-perf containers | `list(string)` | <pre>[<br/> "--orbit_prob",<br/> "0.0"<br/>]</pre> | no |
| <aname="input_git_tag_branch"></a> [git\_tag\_branch](#input\_git\_tag\_branch) | The tag or git branch to use to build loadtest containers. | `string` | n/a | yes |
| <aname="input_loadtest_containers"></a> [loadtest\_containers](#input\_loadtest\_containers) | Number of loadtest containers to deploy | `number` | `1` | no |