imagery: add robots.txt
authorGrant Slater <git@firefishy.com>
Sat, 8 Sep 2018 23:14:17 +0000 (00:14 +0100)
committerGrant Slater <git@firefishy.com>
Sat, 8 Sep 2018 23:14:17 +0000 (00:14 +0100)
cookbooks/imagery/files/default/robots.txt [new file with mode: 0644]
cookbooks/imagery/resources/site.rb

diff --git a/cookbooks/imagery/files/default/robots.txt b/cookbooks/imagery/files/default/robots.txt
new file mode 100644 (file)
index 0000000..5312873
--- /dev/null
@@ -0,0 +1,2 @@
+User-agent: *
+Disallow: /layer/
index 8cb9513..e185084 100644 (file)
@@ -55,6 +55,13 @@ action :create do
     variables :title => new_resource.title
   end
 
+  cookbook_file "/srv/#{new_resource.site}/robots.txt" do
+    source "robots.txt"
+    user "root"
+    group "root"
+    mode 0o644
+  end
+
   cookbook_file "/srv/#{new_resource.site}/imagery.css" do
     source "imagery.css"
     user "root"