Browse Source

[ADD] [8.0] - web_no_crawler (#963)

pull/158/head
Nedas Zilinskas 7 years ago
committed by Pedro M. Baeza
parent
commit
a5d22dbdd9
  1. 1
      web_no_crawler/README.rst
  2. 5
      web_no_crawler/__init__.py
  3. 17
      web_no_crawler/__openerp__.py
  4. 5
      web_no_crawler/controllers/__init__.py
  5. 16
      web_no_crawler/controllers/main.py
  6. 1
      web_no_crawler/readme/CONTRIBUTORS.rst
  7. 3
      web_no_crawler/readme/CREDITS.rst
  8. 2
      web_no_crawler/readme/DESCRIPTION.rst
  9. 3
      web_no_crawler/readme/INSTALL.rst
  10. 1
      web_no_crawler/readme/ROADMAP.rst
  11. 3
      web_no_crawler/readme/USAGE.rst
  12. BIN
      web_no_crawler/static/description/icon.png

1
web_no_crawler/README.rst

@ -0,0 +1 @@
**This file is going to be generated by oca-gen-addon-readme.**

5
web_no_crawler/__init__.py

@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (C) 2018 Ventor, Xpansa Group (<https://ventor.tech/>)
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html).
from . import controllers

17
web_no_crawler/__openerp__.py

@ -0,0 +1,17 @@
# -*- coding: utf-8 -*-
# Copyright (C) 2018 Ventor, Xpansa Group (<https://ventor.tech/>)
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html).
{
'name': 'Disallow indexing completely via robots.txt',
'author': 'Ventor, Xpansa Group, Odoo Community Association (OCA)',
'website': 'https://github.com/OCA/website/tree/8.0',
'category': 'web',
'version': '8.0.1.0.0',
'depends': [
'base',
],
'installable': True,
'application': False,
'license': 'AGPL-3',
}

5
web_no_crawler/controllers/__init__.py

@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (C) 2018 Ventor, Xpansa Group (<https://ventor.tech/>)
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html).
from . import main

16
web_no_crawler/controllers/main.py

@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
# Copyright (C) 2018 Ventor, Xpansa Group (<https://ventor.tech/>)
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html).
import openerp
from openerp import http
class Main(openerp.addons.web.controllers.main.Home):
@http.route('/robots.txt', type='http', auth="none")
def robots(self):
return http.request.make_response(
"User-agent: *\nDisallow: /",
[('Content-Type', 'text/plain')],
)

1
web_no_crawler/readme/CONTRIBUTORS.rst

@ -0,0 +1 @@
* Nedas Zilinskas <nedas.zilinskas@xpansa.com> (http://xpansa.com)

3
web_no_crawler/readme/CREDITS.rst

@ -0,0 +1,3 @@
The development of this module has been financially supported by:
* Ventor, Xpansa Group (<https://ventor.tech/>)

2
web_no_crawler/readme/DESCRIPTION.rst

@ -0,0 +1,2 @@
This module was written to implement a robots.txt file to prevent web crawlers (like google) from indexing pages.
This module does not depend on Website module.

3
web_no_crawler/readme/INSTALL.rst

@ -0,0 +1,3 @@
Installation as usual. No specific installation steps / configuration required.
**WARNING:** this module is not to be used with `Website` module as it has a separate functionality for robots.txt.

1
web_no_crawler/readme/ROADMAP.rst

@ -0,0 +1 @@
* Investigate possibilies for compatibility with `Website` module as it has a separate functionality for robots.txt.

3
web_no_crawler/readme/USAGE.rst

@ -0,0 +1,3 @@
To use this module, you need to:
No configuration needed. Once installed adds robots.txt (ex.: http://example.org/robots.txt).

BIN
web_no_crawler/static/description/icon.png

After

Width: 128  |  Height: 128  |  Size: 9.2 KiB

Loading…
Cancel
Save