Vagrantfile
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "bento/ubuntu-16.04"
config.vm.hostname = "ub1604etcd"
config.vm.provider :virtualbox do |vbox|
vbox.name = "ub1604etcd"
vbox.cpus = 2
vbox.memory = 2048
vbox.customize ["modifyvm", :id, "--nicpromisc2","allow-all"]
end
config.vm.network "private_network", ip: "192.168.55.103", :netmask => "255.255.255.0"
config.vm.network "public_network", ip:"192.168.1.103", :netmask => "255.255.255.0"
config.vm.provision "shell", inline: <<-SHELL
# update packages
apt-get update
#DEBIAN_FRONTEND=noninteractive apt-get -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" upgrade
# install etcd
apt-get -y install etcd
systemctl enable etcd
systemctl start etcd
sleep 10
# テスト実行
etcdctl mkdir test
etcdctl set test/key1 value1
etcdctl get test/key1
SHELL
end
○関連情報
・etcdに関する他の記事はこちらを参照してください。
0 件のコメント:
コメントを投稿