mirror of
https://github.com/trailofbits/algo.git
synced 2025-04-21 16:47:06 +02:00
Instance size (#404)
* Escaping Special Characters #388 * Make instance sizes more flexible to edit #355
This commit is contained in:
parent
bf75a1bb03
commit
16329fe088
6 changed files with 16 additions and 12 deletions
16
config.cfg
16
config.cfg
|
@ -58,9 +58,13 @@ SSH_keys:
|
|||
private: configs/algo.pem
|
||||
public: configs/algo.pem.pub
|
||||
|
||||
dynamic_inventory_groups:
|
||||
- azure
|
||||
- digitalocean
|
||||
- ec2
|
||||
- gce
|
||||
- local
|
||||
cloud_providers:
|
||||
azure:
|
||||
size: Basic_A0
|
||||
digitalocean:
|
||||
size: 512mb
|
||||
ec2:
|
||||
size: t2.micro
|
||||
gce:
|
||||
size: f1-micro
|
||||
local:
|
||||
|
|
|
@ -19,6 +19,6 @@
|
|||
create: yes
|
||||
block: |
|
||||
[algo:children]
|
||||
{% for group in dynamic_inventory_groups %}
|
||||
{% for group in cloud_providers.keys() %}
|
||||
{{ group }}
|
||||
{% endfor %}
|
||||
|
|
|
@ -80,7 +80,7 @@
|
|||
virtual_network: algo_net
|
||||
name: "{{ azure_server_name }}"
|
||||
ssh_password_enabled: false
|
||||
vm_size: Basic_A0
|
||||
vm_size: "{{ cloud_providers.azure.size }}"
|
||||
tags:
|
||||
Environment: Algo
|
||||
ssh_public_keys:
|
||||
|
@ -91,7 +91,7 @@
|
|||
sku: '16.04-LTS'
|
||||
version: latest
|
||||
register: azure_rm_virtualmachine
|
||||
|
||||
|
||||
# To-do: Add error handling - if vm_size requested is not available, can we fall back to another, ideally with a prompt?
|
||||
|
||||
- set_fact:
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
command: droplet
|
||||
name: "{{ do_server_name }}"
|
||||
region_id: "{{ do_region }}"
|
||||
size_id: "512mb"
|
||||
size_id: "{{ cloud_providers.digitalocean.size }}"
|
||||
image_id: "ubuntu-16-04-x64"
|
||||
ssh_key_ids: "{{ do_ssh_key.ssh_key.id }}"
|
||||
unique_name: yes
|
||||
|
|
|
@ -90,7 +90,7 @@
|
|||
keypair: "VPNKEY"
|
||||
vpc_subnet_id: "{{ vpc.subnets[0].id }}"
|
||||
group: vpn-secgroup
|
||||
instance_type: t2.micro
|
||||
instance_type: "{{ cloud_providers.ec2.size }}"
|
||||
image: "{{ ami_image }}"
|
||||
wait: true
|
||||
region: "{{ region }}"
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
gce:
|
||||
instance_names: "{{ server_name }}"
|
||||
zone: "{{ zone }}"
|
||||
machine_type: f1-micro
|
||||
machine_type: "{{ cloud_providers.gce.size }}"
|
||||
image: ubuntu-1604
|
||||
service_account_email: "{{ service_account_email }}"
|
||||
credentials_file: "{{ credentials_file_path }}"
|
||||
|
|
Loading…
Add table
Reference in a new issue