-
Notifications
You must be signed in to change notification settings - Fork 150
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
Showing
5 changed files
with
257 additions
and
2 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,10 +1,10 @@ | ||
radish-bdd==0.13.1 | ||
mock==4.0.1 | ||
gitpython==3.0.8 | ||
gitpython==3.1.0 | ||
netaddr==0.7.19 | ||
colorful==0.5.4 | ||
filetype==1.0.5 | ||
junit-xml==1.8 | ||
junit-xml==1.9 | ||
emoji==0.5.4 | ||
lxml==4.5.0 | ||
ddt==1.2.2 |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module "elasticSearch" { | ||
source = "./module/" | ||
} |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
resource "azurerm_virtual_machine" "elasticSearchVM" { | ||
name = "elasticSearchVM" | ||
os_profile_linux_config { | ||
disable_password_authentication = true | ||
ssh_keys { | ||
key_data = "ssh-rsa mykey" | ||
path = "/home/es/.ssh/authorized_keys" | ||
} | ||
} | ||
location = "" | ||
network_interface_ids = [] | ||
resource_group_name = "test" | ||
vm_size = "" | ||
storage_os_disk { | ||
create_option = "" | ||
name = "" | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,212 @@ | ||
{ | ||
"format_version": "0.1" , | ||
"terraform_version": "0.12.20" , | ||
"planned_values": { | ||
"root_module": { | ||
"child_modules": [ | ||
{ | ||
"resources": [ | ||
{ | ||
"address": "module.elasticSearch.azurerm_virtual_machine.elasticSearchVM" , | ||
"mode": "managed" , | ||
"type": "azurerm_virtual_machine" , | ||
"name": "elasticSearchVM" , | ||
"provider_name": "azurerm" , | ||
"schema_version": 0 , | ||
"values": { | ||
"additional_capabilities": [ ] , | ||
"boot_diagnostics": [ ] , | ||
"delete_data_disks_on_termination": false , | ||
"delete_os_disk_on_termination": false , | ||
"location": "" , | ||
"name": "elasticSearchVM" , | ||
"network_interface_ids": [ ] , | ||
"os_profile": [ ] , | ||
"os_profile_linux_config": [ | ||
{ | ||
"disable_password_authentication": true , | ||
"ssh_keys": [ | ||
{ | ||
"key_data": "ssh-rsa mykey" , | ||
"path": "/home/es/.ssh/authorized_keys" | ||
} | ||
] | ||
} | ||
] , | ||
"os_profile_secrets": [ ] , | ||
"os_profile_windows_config": [ ] , | ||
"plan": [ ] , | ||
"primary_network_interface_id": null , | ||
"proximity_placement_group_id": null , | ||
"resource_group_name": "test" , | ||
"storage_os_disk": [ | ||
{ | ||
"create_option": "" , | ||
"image_uri": null , | ||
"name": "" , | ||
"vhd_uri": null , | ||
"write_accelerator_enabled": false | ||
} | ||
] , | ||
"vm_size": "" , | ||
"zones": null | ||
} | ||
} | ||
] , | ||
"address": "module.elasticSearch" | ||
} | ||
] | ||
} | ||
} , | ||
"resource_changes": [ | ||
{ | ||
"address": "module.elasticSearch.azurerm_virtual_machine.elasticSearchVM" , | ||
"module_address": "module.elasticSearch" , | ||
"mode": "managed" , | ||
"type": "azurerm_virtual_machine" , | ||
"name": "elasticSearchVM" , | ||
"provider_name": "azurerm" , | ||
"change": { | ||
"actions": [ | ||
"create" | ||
] , | ||
"before": null , | ||
"after": { | ||
"additional_capabilities": [ ] , | ||
"boot_diagnostics": [ ] , | ||
"delete_data_disks_on_termination": false , | ||
"delete_os_disk_on_termination": false , | ||
"location": "" , | ||
"name": "elasticSearchVM" , | ||
"network_interface_ids": [ ] , | ||
"os_profile": [ ] , | ||
"os_profile_linux_config": [ | ||
{ | ||
"disable_password_authentication": true , | ||
"ssh_keys": [ | ||
{ | ||
"key_data": "ssh-rsa mykey" , | ||
"path": "/home/es/.ssh/authorized_keys" | ||
} | ||
] | ||
} | ||
] , | ||
"os_profile_secrets": [ ] , | ||
"os_profile_windows_config": [ ] , | ||
"plan": [ ] , | ||
"primary_network_interface_id": null , | ||
"proximity_placement_group_id": null , | ||
"resource_group_name": "test" , | ||
"storage_os_disk": [ | ||
{ | ||
"create_option": "" , | ||
"image_uri": null , | ||
"name": "" , | ||
"vhd_uri": null , | ||
"write_accelerator_enabled": false | ||
} | ||
] , | ||
"vm_size": "" , | ||
"zones": null | ||
} , | ||
"after_unknown": { | ||
"additional_capabilities": [ ] , | ||
"availability_set_id": true , | ||
"boot_diagnostics": [ ] , | ||
"id": true , | ||
"identity": true , | ||
"license_type": true , | ||
"network_interface_ids": [ ] , | ||
"os_profile": [ ] , | ||
"os_profile_linux_config": [ | ||
{ | ||
"ssh_keys": [ | ||
{ } | ||
] | ||
} | ||
] , | ||
"os_profile_secrets": [ ] , | ||
"os_profile_windows_config": [ ] , | ||
"plan": [ ] , | ||
"storage_data_disk": true , | ||
"storage_image_reference": true , | ||
"storage_os_disk": [ | ||
{ | ||
"caching": true , | ||
"disk_size_gb": true , | ||
"managed_disk_id": true , | ||
"managed_disk_type": true , | ||
"os_type": true | ||
} | ||
] , | ||
"tags": true | ||
} | ||
} | ||
} | ||
] , | ||
"configuration": { | ||
"root_module": { | ||
"module_calls": { | ||
"elasticSearch": { | ||
"source": "./module/" , | ||
"module": { | ||
"resources": [ | ||
{ | ||
"address": "azurerm_virtual_machine.elasticSearchVM" , | ||
"mode": "managed" , | ||
"type": "azurerm_virtual_machine" , | ||
"name": "elasticSearchVM" , | ||
"provider_config_key": "elasticSearch:azurerm" , | ||
"expressions": { | ||
"location": { | ||
"constant_value": "" | ||
} , | ||
"name": { | ||
"constant_value": "elasticSearchVM" | ||
} , | ||
"network_interface_ids": { | ||
"constant_value": [ ] | ||
} , | ||
"os_profile_linux_config": [ | ||
{ | ||
"disable_password_authentication": { | ||
"constant_value": true | ||
} , | ||
"ssh_keys": [ | ||
{ | ||
"key_data": { | ||
"constant_value": "ssh-rsa mykey" | ||
} , | ||
"path": { | ||
"constant_value": "/home/es/.ssh/authorized_keys" | ||
} | ||
} | ||
] | ||
} | ||
] , | ||
"resource_group_name": { | ||
"constant_value": "test" | ||
} , | ||
"storage_os_disk": [ | ||
{ | ||
"create_option": { | ||
"constant_value": "" | ||
} , | ||
"name": { | ||
"constant_value": "" | ||
} | ||
} | ||
] , | ||
"vm_size": { | ||
"constant_value": "" | ||
} | ||
} , | ||
"schema_version": 0 | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Feature: Test | ||
|
||
Scenario: ElasticSearch VM linux config | ||
Given I have azurerm_virtual_machine defined | ||
When its address is module.elasticSearch.azurerm_virtual_machine.elasticSearchVM | ||
Then it must contain os_profile_linux_config | ||
And it must contain disable_password_authentication | ||
And its value must be true | ||
|
||
Scenario Outline: ElasticSearch VM linux config ssh | ||
Given I have azurerm_virtual_machine defined | ||
When its address is module.elasticSearch.azurerm_virtual_machine.elasticSearchVM | ||
Then it must contain os_profile_linux_config | ||
And it must contain ssh_keys | ||
And it must contain <key> | ||
And its value must be <value> | ||
|
||
Examples: | ||
| key | value | | ||
| key_data | ssh-rsa mykey | | ||
| path | /home/es/.ssh/authorized_keys | |