github.hscsec.cn/hashicorp/consul@v1.4.5/bench/bench.json (about)

     1  {
     2    "variables": {
     3      "do_size": "16gb",
     4      "do_image": "ubuntu-14-04-x64",
     5      "do_region": "nyc3"
     6    },
     7    "builders": [
     8      {
     9        "type": "digitalocean",
    10        "region": "{{ user `do_region` }}",
    11        "size": "{{ user `do_size` }}",
    12        "image": "{{ user `do_image` }}",
    13        "snapshot_name": "bench-bootstrap-{{ isotime }}",
    14        "name": "bootstrap"
    15      },
    16      {
    17        "type": "digitalocean",
    18        "region": "{{ user `do_region` }}",
    19        "size": "{{ user `do_size` }}",
    20        "image": "{{ user `do_image` }}",
    21        "snapshot_name": "bench-server-{{ isotime }}",
    22        "name": "server"
    23      },
    24      {
    25        "type": "digitalocean",
    26        "region": "{{ user `do_region` }}",
    27        "size": "{{ user `do_size` }}",
    28        "image": "{{ user `do_image` }}",
    29        "snapshot_name": "bench-worker-{{ isotime }}",
    30        "name": "worker"
    31      }
    32    ],
    33    "provisioners":[
    34      {
    35        "type": "file",
    36        "source": "conf/upstart.conf",
    37        "destination": "/etc/init/consul.conf"
    38      },
    39      {
    40        "type": "shell",
    41        "inline": [
    42          "mkdir /etc/consul.d",
    43          "apt-get update",
    44          "apt-get install -y unzip make",
    45          "wget https://releases.hashicorp.com/consul/0.7.1/consul_0.7.1_linux_amd64.zip",
    46          "unzip consul_*_linux_amd64.zip",
    47          "mv consul /usr/local/bin/consul",
    48          "chmod +x /usr/local/bin/consul"
    49        ]
    50      },
    51      {
    52        "type": "file",
    53        "source": "conf/common.json",
    54        "destination": "/etc/consul.d/common.json"
    55      },
    56      {
    57        "type": "file",
    58        "source": "conf/bootstrap.json",
    59        "destination": "/etc/consul.d/bootstrap.json",
    60        "only": ["bootstrap"]
    61      },
    62      {
    63        "type": "file",
    64        "source": "conf/server.json",
    65        "destination": "/etc/consul.d/server.json",
    66        "only": ["server"]
    67      },
    68      {
    69        "type": "shell",
    70        "inline": [
    71          "curl https://s3.amazonaws.com/hc-ops/boom_linux_amd64 -o /usr/local/bin/boom",
    72          "chmod +x /usr/local/bin/boom"
    73        ]
    74      },
    75      {
    76        "type": "file",
    77        "source": "Makefile",
    78        "destination": "/Makefile"
    79      }
    80    ]
    81  }