summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorDavid Dymko <dymkod@gmail.com>2021-04-13 14:15:34 -0400
committerGitHub <noreply@github.com>2021-04-13 14:15:34 -0400
commit0ae0b1d4336acdcab12bd49e9bddb46922fb19c7 (patch)
tree11eca25e1c86dfeab2a80bcf027af9aebf2aec78 /tools
parent83f6bbfbe5b924be61a3c098f4202377d69c8947 (diff)
downloadvyos-cloud-init-0ae0b1d4336acdcab12bd49e9bddb46922fb19c7.tar.gz
vyos-cloud-init-0ae0b1d4336acdcab12bd49e9bddb46922fb19c7.zip
Add Vultr support (#827)
This PR adds in support so that cloud-init can run on instances deployed on Vultr cloud. This was originally brought up in #628. Co-authored-by: Eric Benner <ebenner@vultr.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/.github-cla-signers1
-rwxr-xr-xtools/ds-identify16
2 files changed, 16 insertions, 1 deletions
diff --git a/tools/.github-cla-signers b/tools/.github-cla-signers
index b39f4198..d6212d1d 100644
--- a/tools/.github-cla-signers
+++ b/tools/.github-cla-signers
@@ -11,6 +11,7 @@ BirknerAlex
candlerb
cawamata
dankenigsberg
+ddymko
dermotbradley
dhensby
eandersson
diff --git a/tools/ds-identify b/tools/ds-identify
index 2f2486f7..73e27c71 100755
--- a/tools/ds-identify
+++ b/tools/ds-identify
@@ -124,7 +124,7 @@ DI_DSNAME=""
# this has to match the builtin list in cloud-init, it is what will
# be searched if there is no setting found in config.
DI_DSLIST_DEFAULT="MAAS ConfigDrive NoCloud AltCloud Azure Bigstep \
-CloudSigma CloudStack DigitalOcean AliYun Ec2 GCE OpenNebula OpenStack \
+CloudSigma CloudStack DigitalOcean Vultr AliYun Ec2 GCE OpenNebula OpenStack \
OVF SmartOS Scaleway Hetzner IBMCloud Oracle Exoscale RbxCloud UpCloud"
DI_DSLIST=""
DI_MODE=""
@@ -1350,6 +1350,20 @@ dscheck_IBMCloud() {
return ${DS_NOT_FOUND}
}
+dscheck_Vultr() {
+ dmi_sys_vendor_is Vultr && return $DS_FOUND
+
+ case " $DI_KERNEL_CMDLINE " in
+ *\ vultr\ *) return $DS_FOUND ;;
+ esac
+
+ if [ -f "${PATH_ROOT}/etc/vultr" ]; then
+ return $DS_FOUND
+ fi
+
+ return $DS_NOT_FOUND
+}
+
collect_info() {
read_uname_info
read_virt