summaryrefslogtreecommitdiff
path: root/lib/chef/resource/deploy.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/resource/deploy.rb')
-rw-r--r--lib/chef/resource/deploy.rb19
1 files changed, 16 insertions, 3 deletions
diff --git a/lib/chef/resource/deploy.rb b/lib/chef/resource/deploy.rb
index 8b614028bf..76478ed07c 100644
--- a/lib/chef/resource/deploy.rb
+++ b/lib/chef/resource/deploy.rb
@@ -50,9 +50,9 @@ class Chef
# release directory. Callback files can contain chef code (resources, etc.)
#
class Deploy < Chef::Resource
-
+
provider_base Chef::Provider::Deploy
-
+
identity_attr :repository
state_attrs :deploy_to, :revision
@@ -389,7 +389,7 @@ class Chef
arg ||= block
set_or_return(:after_restart, arg, :kind_of => [Proc, String])
end
-
+
def additional_remotes(arg=nil)
set_or_return(
:additional_remotes,
@@ -398,6 +398,19 @@ class Chef
)
end
+ # FIXME The Deploy resource may be passed to an SCM provider as its
+ # resource. The SCM provider knows that SCM resources can specify a
+ # timeout for SCM operations. The deploy resource must therefore support
+ # a timeout method, but the timeout it describes is for SCM operations,
+ # not the overall deployment. This is potentially confusing.
+ def timeout(arg=nil)
+ set_or_return(
+ :timeout,
+ arg,
+ :kind_of => Integer
+ )
+ end
+
end
end
end