diff options
author | Achilleas Pipinellis <axil@gitlab.com> | 2018-03-23 15:45:35 +0300 |
---|---|---|
committer | Achilleas Pipinellis <axil@gitlab.com> | 2018-03-23 15:45:35 +0300 |
commit | 0d8f96cac73873b9e8cc3bf622cac5ee13120c48 (patch) | |
tree | dd33d29c53180dc906e4bd3e770dcd3af403b05c /content | |
parent | 7eeb5bbfb15b21238ecf1e6e2c9e36cfde465185 (diff) |
Allow robots indexing only on master
Diffstat (limited to 'content')
-rw-r--r-- | content/robots.txt.erb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/content/robots.txt.erb b/content/robots.txt.erb index db1d0b75..b4a4b64f 100644 --- a/content/robots.txt.erb +++ b/content/robots.txt.erb @@ -2,4 +2,10 @@ is_hidden: true --- +<% if ENV['CI_COMMIT_REF_NAME'] == 'master' %> Sitemap: <%= @items['/sitemap.*'].path %> +<% else %> +# Ban all spiders from the entire site when not on master branch +User-Agent: * +Disallow: / +<% end %> |