-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Ryuko
committed
Jun 1, 2024
1 parent
ba2fc3e
commit c575c57
Showing
1 changed file
with
7 additions
and
5 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -1,17 +1,19 @@ | ||
# Testing Infrastructure | ||
|
||
This `OpenTofu` script sets up Infrastructure to test the ansible upgrade script. | ||
We use `cri-o`, `kubeadm` and `cilium` to setup the cluster. | ||
|
||
## Setup | ||
1. Get your API token (Read + Write) for Hetzner Cloud in the Hetzner Console: | ||
`https://console.hetzner.cloud/projects/<id>/security/tokens` | ||
2. Paste it into the variables.tfvars | ||
|
||
## Run | ||
`tofu init` | ||
`tofu apply -var-file=variables.tfvars` | ||
1. `tofu init` | ||
2. `tofu apply -var-file=variables.tfvars` | ||
|
||
## Output | ||
You will receive an `inventory` and `kubeconfig` file in the `local/` directory which you can use to test the cluster. | ||
If you encounter any issue with the cilium install, just run the script again and it should work. | ||
|
||
⚠ The script will create a file in your `~/.ssh` directory called `~/.ssh/tofu-ssh` make sure that is not overwritten when running the script ⚠ | ||
## Output | ||
You will receive an `inventory`,`kubeconfig` and `ssh-key` files in the `local/` directory which you can use to test the cluster. | ||
You may have to copy the files to your `~/.ssh` directory in order to connect via ssh. |