Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env perl
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
@john-
john- / notify
Created November 27, 2018 17:56
Websocket and Subprocess
#!/usr/bin/env perl
use Mojolicious::Lite;
use Mojo::IOLoop::Subprocess;
get '/' => sub {
my $c = shift;
$c->render(template => 'index');
};