2019-04-02 20:53:19 +08:00
|
|
|
#!/bin/bash
|
|
|
|
|
2022-01-31 20:42:10 +08:00
|
|
|
vagrant box remove --force --provider libvirt --box-version 0 centos/stream8 || true
|
|
|
|
vagrant box add --provider libvirt --name centos/stream8 https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-Vagrant-8-20220125.1.x86_64.vagrant-libvirt.box || true
|
2021-05-25 16:02:23 +08:00
|
|
|
|
2019-04-02 20:53:19 +08:00
|
|
|
retries=0
|
|
|
|
until [ $retries -ge 5 ]
|
|
|
|
do
|
|
|
|
echo "Attempting to start VMs. Attempts: $retries"
|
2019-10-17 21:37:31 +08:00
|
|
|
timeout 10m time vagrant up "$@" && break
|
2021-05-25 16:08:55 +08:00
|
|
|
retries=$((retries+1))
|
2019-04-02 20:53:19 +08:00
|
|
|
sleep 5
|
|
|
|
done
|
|
|
|
|
|
|
|
sleep 10
|