Skip to content

Commit

Permalink
Update integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
outscale-toa committed Jan 30, 2024
1 parent 9974614 commit 756b2d7
Show file tree
Hide file tree
Showing 43 changed files with 1,014 additions and 325 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,15 @@ resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF177"
}

resource "outscale_security_group" "my_sgfg" {
description = "test security group"
}

resource "outscale_vm" "MaVM" {
image_id = var.image_id
vm_type = var.fgpu_vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgfg.security_group_id]
placement_subregion_name = "${var.region}a"
vm_initiated_shutdown_behavior = "restart"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,15 @@ resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF174"
}

resource "outscale_security_group" "my_sgfg_link" {
description = "test security group"
}

resource "outscale_vm" "MaVM" {
image_id = var.image_id
vm_type = var.fgpu_vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgfg_link.security_group_id]
placement_subregion_name = "${var.region}a"
vm_initiated_shutdown_behavior = "restart"
}
Expand All @@ -18,7 +23,6 @@ resource "outscale_flexible_gpu" "fGPU-1" {
delete_on_vm_deletion = true
}


resource "outscale_flexible_gpu_link" "link_fGPU" {
flexible_gpu_id = outscale_flexible_gpu.fGPU-1.flexible_gpu_id
vm_id = outscale_vm.MaVM.vm_id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,16 @@ resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF1775"
}

resource "outscale_security_group" "my_sgfgs" {
description = "test security group_fg"
}


resource "outscale_vm" "MaVM" {
image_id = var.image_id
vm_type = var.fgpu_vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgfgs.security_group_id]
placement_subregion_name = "${var.region}a"
vm_initiated_shutdown_behavior = "restart"
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
resource "outscale_security_group" "my_sgImg" {
description = "test security group"
}

resource "outscale_vm" "my-vm" {
image_id = var.image_id
image_id = var.image_id
security_group_ids = [outscale_security_group.my_sgImg.security_group_id]
}

resource "outscale_image" "outscale_image" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
resource "outscale_security_group" "my_sgImg1" {
description = "test sg group"
}

resource "outscale_vm" "my-vm" {
image_id = var.image_id
image_id = var.image_id
security_group_ids = [outscale_security_group.my_sgImg1.security_group_id]
}

resource "outscale_image" "outscale_image" {
Expand All @@ -9,11 +14,11 @@ resource "outscale_image" "outscale_image" {
tags {
key = "Key"
value = "value-tags"
}
tags {
}
tags {
key = "Key-2"
value = "value-tags-2"
}
}
}

### Test Copy Image
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
resource "outscale_security_group" "my_sgImgl" {
description = "test sg_group"
}

resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF68"
}
Expand All @@ -6,6 +10,7 @@ resource "outscale_vm" "outscale_vm" {
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgImgl.security_group_id]
}

resource "outscale_image" "outscale_image" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
resource "outscale_security_group" "my_sgImgs" {
description = "test sg-group"
}

resource "outscale_vm" "outscale_vm" {
image_id = var.image_id
image_id = var.image_id
security_group_ids = [outscale_security_group.my_sgImgs.security_group_id]
}

resource "outscale_image" "outscale_image1" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
resource "outscale_security_group" "my_sgImgs" {
description = "test sg-group"
}

resource "outscale_vm" "outscale_vm" {
image_id = var.image_id
image_id = var.image_id
security_group_ids = [outscale_security_group.my_sgImgs.security_group_id]
}

resource "outscale_image" "outscale_image1" {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,15 @@ resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF87"
}

resource "outscale_security_group" "my_sgLbl" {
description = "test sg-group-lbu"
}

resource "outscale_vm" "public_vm_1" {
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgLbl.security_group_id]
}

resource "outscale_load_balancer" "public_lbu2" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF88"
}

resource "outscale_security_group" "my_sgLbur" {
description = "test sg-group-lbur"
}

resource "outscale_vm" "public_vm_1" {
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgLbur.security_group_id]
}

resource "outscale_load_balancer" "public_lbu2" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF88"
}

resource "outscale_security_group" "my_sgLbur" {
description = "test sg-group-lbur"
}

resource "outscale_vm" "public_vm_1" {
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgLbur.security_group_id]
}

resource "outscale_load_balancer" "public_lbu2" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF89"
}

resource "outscale_security_group" "my_sgLburs" {
description = "test sg-group-lburs"
}

resource "outscale_vm" "public_vm_1" {
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.my_sgLburs.security_group_id]
}

resource "outscale_load_balancer" "public_lbu2" {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ resource "outscale_vm" "outscale_vm-1" {
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.public_sg.id]
security_group_ids = [outscale_security_group.public_sg.id]
placement_subregion_name = "${var.region}a"
user_data = base64encode(<<EOF
#!/bin/bash
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,17 @@ resource "outscale_load_balancer" "public_lbu1" {
}
}

resource "outscale_security_group" "public_sglb" {
description = "test lbu vm health"
security_group_name = "sgTF-93"
}

resource "outscale_vm" "outscale_vms_lbu" {
count = 2
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.public_sglb.id]
user_data = base64encode(<<EOF
#!/bin/bash
pushd /home
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ resource "outscale_keypair" "my_keypair" {
keypair_name = "KP-TF93"
}
resource "outscale_load_balancer" "public_lbu1" {
load_balancer_name = "lbu-TF-93"
load_balancer_name = "lbu-TF-93"
subregion_names = ["${var.region}a"]
listeners {
backend_port = 80
Expand All @@ -22,11 +22,17 @@ resource "outscale_load_balancer" "public_lbu1" {
}
}

resource "outscale_security_group" "public_sglb" {
description = "test lbu vm health"
security_group_name = "sgTF-93"
}

resource "outscale_vm" "outscale_vms_lbu" {
count = 2
image_id = var.image_id
vm_type = var.vm_type
keypair_name = outscale_keypair.my_keypair.keypair_name
security_group_ids = [outscale_security_group.public_sglb.id]
user_data = base64encode(<<EOF
#!/bin/bash
pushd /home
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"net_peering_id": "##id-3##",
"source_net": {
"account_id": "##id-1##",
"ip_range": "10.20.0.0/16",
"ip_range": "10.31.0.0/16",
"net_id": "##id-4##"
},
"state": {
Expand All @@ -44,7 +44,7 @@
"net_peering_id": "##id-5##",
"source_net": {
"account_id": "##id-1##",
"ip_range": "10.31.0.0/16",
"ip_range": "10.20.0.0/16",
"net_id": "##id-6##"
},
"state": {
Expand Down Expand Up @@ -93,9 +93,9 @@
"schema_version": 0,
"attributes": {
"dhcp_options_set_id": "##id-7##",
"id": "##id-6##",
"id": "##id-4##",
"ip_range": "10.31.0.0/16",
"net_id": "##id-6##",
"net_id": "##id-4##",
"request_id": "########",
"state": "available",
"tags": [],
Expand All @@ -116,9 +116,9 @@
"schema_version": 0,
"attributes": {
"dhcp_options_set_id": "##id-7##",
"id": "##id-4##",
"id": "##id-6##",
"ip_range": "10.20.0.0/16",
"net_id": "##id-4##",
"net_id": "##id-6##",
"request_id": "########",
"state": "available",
"tags": [],
Expand All @@ -144,16 +144,16 @@
"net_id": "##id-2##"
},
"accepter_net_id": "##id-2##",
"id": "##id-5##",
"net_peering_id": "##id-5##",
"id": "##id-3##",
"net_peering_id": "##id-3##",
"request_id": "########",
"source_net": {
"account_id": "##id-1##",
"ip_range": "10.31.0.0/16",
"net_id": "##id-6##"
"net_id": "##id-4##"
},
"source_net_account_id": null,
"source_net_id": "##id-6##",
"source_net_id": "##id-4##",
"state": {
"message": "########",
"name": "pending-acceptance"
Expand Down Expand Up @@ -193,16 +193,16 @@
"net_id": "##id-2##"
},
"accepter_net_id": "##id-2##",
"id": "##id-3##",
"net_peering_id": "##id-3##",
"id": "##id-5##",
"net_peering_id": "##id-5##",
"request_id": "########",
"source_net": {
"account_id": "##id-1##",
"ip_range": "10.20.0.0/16",
"net_id": "##id-4##"
"net_id": "##id-6##"
},
"source_net_account_id": null,
"source_net_id": "##id-4##",
"source_net_id": "##id-6##",
"state": {
"message": "########",
"name": "pending-acceptance"
Expand Down
Loading

0 comments on commit 756b2d7

Please sign in to comment.