This repository has been archived by the owner on Jul 27, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Vagrantfile.default.rb
54 lines (45 loc) · 1.85 KB
/
Vagrantfile.default.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
print "\n"
# Environment Configs
$dev_machine_name = 'example.lan'
$dev_additional_hostnames = %w(store1.example.lan store2.example.lan)
# System Configs
$vagrant_base_box = 'bento/centos-8'
$dev_vm_cpus = 2
$dev_vm_ram = 4096
$ssh_private_key = '~/.ssh/id_rsa'
$ssh_public_key_paths = ['~/.ssh/id_rsa.pub']
$persistent_disks = [
# {
# "description" => "data",
# "persistDiskPath" => "data_disk.vmdk",
# "persistDiskSizeGb" => 50
# },
# {
# "description" => "datadb",
# "persistDiskPath" => "datadb_disk.vmdk",
# "persistDiskSizeGb" => 50
# }
]
$use_provider = "virtualbox" # possible values ["virtualbox", "digitalocean"]
$digital_ocean_api_token = 'CHANGEME'
# To crate a volume
# ----------------------------------
# export DO_TOKEN=xxxxxxxxxxxxxxxxxxxxxxxx
# export DO_VOL_GB=50
# export DO_VOL_NAME="xxxxxxxxxx_data"
# export DO_VOL_REGION=xxxxxxx
# curl -s -X POST -H "Content-Type: application/json" -H "Authorization: Bearer ${DO_TOKEN}" -d "{\"size_gigabytes\":${DO_VOL_GB}, \"name\": \"${DO_VOL_NAME}\", \"region\": \"${DO_VOL_REGION}\"}" "https://api.digitalocean.com/v2/volumes" | jq .
# To List existing volumes
# ----------------------------------
# export DO_TOKEN=xxxxxxxxxxxxxxxxxxxxxxxx
# curl -s -X GET -H "Content-Type: application/json" -H "Authorization: Bearer ${DO_TOKEN}" "https://api.digitalocean.com/v2/volumes" | jq .
# Volume must exist before creating the droplet
$digital_ocean_block_volume_id = [] # ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"]
$digital_ocean_ssh_key_name = ''
$digital_ocean_tags = []
# To List droplet size slugs
# ----------------------------------
# export DO_TOKEN=xxxxxxxxxxxxxxxxxxxxxxxx
# curl -s -X GET -H "Content-Type: application/json" -H "Authorization: Bearer ${DO_TOKEN}" "https://api.digitalocean.com/v2/sizes" | jq .
$digital_ocean_droplet_size = 's-2vcpu-4gb'
$digital_ocean_region = 'nyc1'