disallow robots index for self hosted deployments
This commit is contained in:
9
server/utils/robots.js
Normal file
9
server/utils/robots.js
Normal file
@ -0,0 +1,9 @@
|
||||
// @flow
|
||||
import { type Context } from 'koa';
|
||||
|
||||
const DISALLOW_ROBOTS = `User-agent: *
|
||||
Disallow: /`;
|
||||
|
||||
export const robotsResponse = (ctx: Context): ?string => {
|
||||
if (ctx.headers.host.indexOf('getoutline.com') < 0) return DISALLOW_ROBOTS;
|
||||
};
|
Reference in New Issue
Block a user