diff options
| author | Daniil Baturin <daniil@baturin.org> | 2021-05-19 06:53:31 +0700 |
|---|---|---|
| committer | Daniil Baturin <daniil@baturin.org> | 2021-05-19 06:54:33 +0700 |
| commit | 8a97cba2aafc0a582b73f5d766eee97278cab09f (patch) | |
| tree | e9573263f7dfc90557733e07ff466b995d2ab774 | |
| parent | c41e8a8a487e331f8c18f2006043ec5c38de2261 (diff) | |
| download | community.vyos.net-8a97cba2aafc0a582b73f5d766eee97278cab09f.tar.gz community.vyos.net-8a97cba2aafc0a582b73f5d766eee97278cab09f.zip | |
Disallow search engine indexing on staging.
| -rw-r--r-- | plugins/create-file.lua | 5 | ||||
| -rw-r--r-- | soupault.conf | 9 |
2 files changed, 14 insertions, 0 deletions
diff --git a/plugins/create-file.lua b/plugins/create-file.lua new file mode 100644 index 0000000..e1d0369 --- /dev/null +++ b/plugins/create-file.lua @@ -0,0 +1,5 @@ +file_name = config["name"] +content = config["content"] + +file_path = Sys.join_path(build_dir, file_name) +Sys.write_file(file_path, content) diff --git a/soupault.conf b/soupault.conf index 5d89d98..22e2351 100644 --- a/soupault.conf +++ b/soupault.conf @@ -50,6 +50,15 @@ action = "prepend_child" profile = "staging" +[widgets.disallow-indexing-on-staging] + widget = "create-file" + name = "robots.txt" + content = """ +User-agent: * +Disallow: / +""" + profile = "staging" + # Generates a list of available snapshots from S3 [widgets.list-snapshots] widget = "exec" |
