summaryrefslogtreecommitdiff
path: root/chef-utils/lib/chef-utils/dsl/cloud.rb
diff options
context:
space:
mode:
Diffstat (limited to 'chef-utils/lib/chef-utils/dsl/cloud.rb')
-rw-r--r--chef-utils/lib/chef-utils/dsl/cloud.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/chef-utils/lib/chef-utils/dsl/cloud.rb b/chef-utils/lib/chef-utils/dsl/cloud.rb
index a232563709..6e8fc520a5 100644
--- a/chef-utils/lib/chef-utils/dsl/cloud.rb
+++ b/chef-utils/lib/chef-utils/dsl/cloud.rb
@@ -35,6 +35,17 @@ module ChefUtils
!node["cloud"].nil?
end
+ # Determine if the current node is running in Alibaba Cloud
+ #
+ # @param [Chef::Node] node the node to check
+ # @since 17.0
+ #
+ # @return [Boolean]
+ #
+ def alibaba?(node = __getnode)
+ node.key?("alibaba")
+ end
+
# Determine if the current node is running in AWS EC2.
#
# @param [Chef::Node] node the node to check