Skip to content

Commit

Permalink
tf update
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph Kanzaveli committed Jul 20, 2023
1 parent b479597 commit c14c51f
Show file tree
Hide file tree
Showing 19 changed files with 22 additions and 24 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
## Terraform-Modules
<h3> Terraform modules </h3>

1. [Azure AKS+LogAnalytics module](https://github.com/Joska99/joska/blob/main/terraform/modules/tf-aks-la)
1. [Azure AKS with LogAnalytics and ACR module](https://github.com/Joska99/joska/blob/main/terraform/modules/tf-aks-la)
2. [Azure Linux VM module](https://github.com/Joska99/joska/blob/main/terraform/modules/tf-linux-vm)
3. [Azure WAN Hub module](https://github.com/Joska99/joska/blob/main/terraform/modules/tf-wan-hub)

Expand Down
10 changes: 5 additions & 5 deletions terraform/modules/tf-aks-la/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p align="center">
<h1>Terraform AKS, ACR and Log Analytics</h1>
<p align="center">
<img src="https://github.com/Joska99/joska/blob/main/terraform/modules/tf-aks-la/diagram.drawio.svg">
</p>

Expand All @@ -9,11 +9,11 @@
```bash
az login
```
2. Move to "ias" folder and init Terraform:
2. Move to "iac" folder and init Terraform:
```bash
terraform init
```
3. Chek terraform module and output plan:
3. Check terraform module and output plan:
```bash
terraform plan --out tfplan
```
Expand All @@ -30,7 +30,7 @@ az aks get-credentials --resource-group aks-rg --name joska-cluster
mv kubeconfig ~/.kube/config
```

<h1> Create Storage Acount in azure by CLI to store .tfstate</h1>
<h1> Create Storage Account in azure by CLI to store .tfstate</h1>

1. Create variables
```bash
Expand All @@ -39,7 +39,7 @@ SA_NAME=sa4tstfstate
CONTAINER_NAME=tf-state
```

2. Create Storage Acount
2. Create Storage Account
```bash
az storage acount create --resource-group $RG_NAME --name $SA_NAME --sku Standard_LRS --encryption-services blob
```
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
8 changes: 8 additions & 0 deletions terraform/modules/tf-aks-la/iac/terraform.tfvars
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# resource_group_name = "aks-rg"
# location = "eastus"
# cluster_name = "joska-cluster"
# # az aks get-versions --location eastus ---> to cche enable versions in region
# kubernetes_version = "1.26.0"
# system_node_count = 2
# log_analytics_name = "eeboitflga"
# log_analytics_sku = "PerGB2018"
File renamed without changes.
8 changes: 0 additions & 8 deletions terraform/modules/tf-aks-la/terraform.tfvars

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
11 changes: 6 additions & 5 deletions terraform/modules/tf-linux-vm/readme.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<p align="center">
<h1>Terraform Linux VM</h1>
<p align="center">
<img src="https://github.com/Joska99/joska/blob/main/terraform/modules/tf-linux-vm/diagram.drawio.svg">
</p>

<h1> Steps </h1>

- Terraform init, plan apply with local backend
- Terraform init, plan apply with local backend from 'iac' directory
```bash
terraform init
terraform plan --out tfplan
Expand All @@ -18,6 +18,7 @@ terraform destroy --auto-approve
```

- outputs:
1. vnet_id = virtual network id to connect
2. linuxkey.pem = shh connection key to local dir
3. vm_pip = linux vm public ip

1. vnet_id - virtual network id to connect
2. linuxkey.pem - shh connection key to local dir
3. vm_pip - linux vm public ip
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
7 changes: 2 additions & 5 deletions terraform/modules/tf-wan-hub/readme.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<p align="center">
<h1>Terraform Virtual Wan Hub</h1>
<p align="center">
<img src="https://github.com/Joska99/joska/blob/main/terraform/modules/tf-wan-hub/diagram.drawio.svg">
</p>

<h1> Steps </h1>

- Terraform init, plan apply with local backend
- Terraform init, plan apply with local backend from 'iac' directory
```bash
terraform init
terraform plan --out tfplan
Expand All @@ -16,6 +16,3 @@ terraform apply tfplan
```bash
terraform destroy --auto-approve
```

- outputs:
1. vhub_id = virtual hub id to connect

0 comments on commit c14c51f

Please sign in to comment.