diff --git a/.github/workflows/deploy-ansible.yml b/.github/workflows/deploy-ansible.yml index a616ae0..be074bc 100644 --- a/.github/workflows/deploy-ansible.yml +++ b/.github/workflows/deploy-ansible.yml @@ -38,8 +38,8 @@ jobs: - name: Scan VM Host Key run: | - ssh-keyscan -H 135.116.196.120 >> ~/.ssh/known_hosts - + ssh-keyscan -H 4.223.70.80 >> ~/.ssh/known_hosts + - name: Run Playbook run: | ansible-playbook -i infra/inventory.ini ansible/site.yml \ diff --git a/.gitignore b/.gitignore index 3c4c474..a271750 100644 --- a/.gitignore +++ b/.gitignore @@ -43,3 +43,4 @@ Thumbs.db # Ansible local_secrets.yml +id_rsa diff --git a/README.md b/README.md index 9c7ba20..69434c7 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ Rancher deployment (Kubernetes): https://devsecops.stud.k8s.aet.cit.tum.de -~Azure deployment (Docker Compose): http://135.116.196.120/~ _Currently unavailable since we ran out of credits, will be setup again soon_ +Azure deployment (Docker Compose): http://4.223.70.80/ Coverage reports: https://aet-devops26.github.io/team-devsecops/ diff --git a/infra/.gitkeep b/infra/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/infra/.terraform.lock.hcl b/infra/.terraform.lock.hcl index 7a7d902..20a5e97 100644 --- a/infra/.terraform.lock.hcl +++ b/infra/.terraform.lock.hcl @@ -5,6 +5,7 @@ provider "registry.terraform.io/hashicorp/azurerm" { version = "3.117.1" constraints = "~> 3.0" hashes = [ + "h1:3c9iOEtBMnHrpJLlhbQ0sCZPWhE/2dvEPcL8KkXAh7w=", "h1:j6wnjpHfBcQC4xd3ZYquaIPIIR46xJQs7rxwPdSOZos=", "zh:0c513676836e3c50d004ece7d2624a8aff6faac14b833b96feeac2e4bc2c1c12", "zh:50ea01ada95bae2f187db9e926e463f45d860767a85ebc59160414e00e76c35d", diff --git a/infra/id_rsa.pub b/infra/id_rsa.pub new file mode 100644 index 0000000..b2c38ed --- /dev/null +++ b/infra/id_rsa.pub @@ -0,0 +1 @@ +ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCEoD/FM5r6/dGFx5/5wu29zPXq7MyYe85wgCz7yXukKMBGjqcRhyzuiBDNxUON3SL3xL1T6H9/DA0wmSBoAvvY6QeKdBz5LTLl29Ot84ZI3WivwJdOo/uqokOqU+HDGHQ46yUWe6NcBndwha3QkBU7++HaSzt9WuLozUjvWWkplYWlGtB3khqngJGCDo8Oh63ekXuJYdbfwi7g/rAO9/ipVyCGsTg8oJAItPyQYd8MgBYQMmOoO3k073XDFaBI9TO+WZ3m8eSmzyTyV8pQlFn/Yl7d63SWOLcfGwgIHlFNWhUyoB+FlBKBF3LUpi+negOWbHzL5sKzaJGj9UMvT1MVPcAmd6Fgv7bHbtdhN8x4tCrYLlVKDHTEp1m8aIaa6Y7lIsyvL8R1hH9jAQU4xgN6do7d/fiIMxQrdWIeMSbbvDRGdYI/e51zF7m7Iq5l6gvu8IWU7tX40zyXIaLdPIAYH+DyhQOCCk2CY7QUlU9+Br3SrRGbcpcXV3Gj7IiIf6IDSrr4ZXlB8VbOMpQu9yywHhsdLTiu50HNEqtKMDriAPUzZqRlHj+ZZfQY+Xmbs0lPhPMy5hY3kxcOsnG26jwbEf2iY2z5I8YNM0Jxb6KP0CSHcKHiVlopBaofre3md9Yn0Wq7FWga0h3NfM8wpbooTTq4o5NGD6Y6LrEl4n9glw== dave@wolfsburg diff --git a/infra/inventory.ini b/infra/inventory.ini index fec4aa2..a13054e 100644 --- a/infra/inventory.ini +++ b/infra/inventory.ini @@ -1,8 +1,8 @@ [web] -135.116.196.120 +4.223.70.80 [all:vars] ansible_user=azureuser ansible_ssh_private_key_file=~/.ssh/id_rsa ansible_ssh_common_args='-o StrictHostKeyChecking=no' -ansible_python_interpreter=/usr/bin/python3.10 \ No newline at end of file +ansible_python_interpreter=/usr/bin/python3.10 diff --git a/infra/main.tf b/infra/main.tf index 03cf384..f5a2ec1 100644 --- a/infra/main.tf +++ b/infra/main.tf @@ -67,7 +67,7 @@ resource "azurerm_linux_virtual_machine" "vm" { admin_ssh_key { username = "azureuser" - public_key = file("~/.ssh/id_rsa.pub") + public_key = file("./id_rsa.pub") } os_disk { @@ -103,4 +103,4 @@ resource "azurerm_network_interface_security_group_association" "nsg_assoc" { output "public_ip" { value = azurerm_public_ip.pip.ip_address -} \ No newline at end of file +}