summaryrefslogtreecommitdiff
path: root/lib/chef/provider/remote_file/fetcher.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/remote_file/fetcher.rb')
-rw-r--r--lib/chef/provider/remote_file/fetcher.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/chef/provider/remote_file/fetcher.rb b/lib/chef/provider/remote_file/fetcher.rb
index 563d135d6a..6a4711d097 100644
--- a/lib/chef/provider/remote_file/fetcher.rb
+++ b/lib/chef/provider/remote_file/fetcher.rb
@@ -24,6 +24,9 @@ class Chef
def self.for_resource(uri, new_resource, current_resource)
if network_share?(uri)
+ if !Chef::Platform.windows?
+ raise Exceptions::UnsupportedPlatform, "Fetching the file on a network share is supported only on the Windows platform. Please change your source: #{uri}"
+ end
Chef::Provider::RemoteFile::NetworkFile.new(uri, new_resource, current_resource)
else
case uri.scheme