Commit b3e0872d authored by Francesc Guasch's avatar Francesc Guasch Committed by Francesc Guasch
Browse files

Hide this web from robots

parent 3834bf1f
......@@ -121,7 +121,7 @@ hook before_routes => sub {
return login($c)
if
$url !~ m{^/(anonymous|login|logout|requirements)}
$url !~ m{^/(anonymous|login|logout|requirements|robots.txt)}
&& $url !~ m{^/(css|font|img|js)}
&& !_logged_in($c);
......@@ -131,6 +131,12 @@ hook before_routes => sub {
############################################################################3
any '/robots.txt' => sub {
my $c = shift;
warn "robots";
return $c->render(text => "User-agent: *\nDisallow: /\n", format => 'text');
};
any '/' => sub {
my $c = shift;
return quick_start($c);
......@@ -932,6 +938,7 @@ sub req_new_domain {
my $c = shift;
my $name = $c->param('name');
my $swap = ($c->param('swap') or 0);
my $vm = ( $c->param('backend') or 'KVM');
$swap *= 1024*1024*1024;
my %args = (
name => $name
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment