move nbtstat and nbtwalk to worker plugins
This commit is contained in:
19
lib/App/Netdisco/Worker/Plugin/Test.pm
Normal file
19
lib/App/Netdisco/Worker/Plugin/Test.pm
Normal file
@@ -0,0 +1,19 @@
|
||||
package App::Netdisco::Worker::Plugin::Test;
|
||||
|
||||
use Dancer ':syntax';
|
||||
use App::Netdisco::Worker::Plugin;
|
||||
use aliased 'App::Netdisco::Worker::Status';
|
||||
|
||||
register_worker({ primary => true }, sub {
|
||||
my ($job, $workerconf) = @_;
|
||||
debug 'Test (primary) ran successfully.';
|
||||
return Status->done('Test (primary) ran successfully.');
|
||||
});
|
||||
|
||||
register_worker({ primary => false }, sub {
|
||||
my ($job, $workerconf) = @_;
|
||||
debug 'Test ran successfully.';
|
||||
return Status->done('Test ran successfully.');
|
||||
});
|
||||
|
||||
true;
|
||||
Reference in New Issue
Block a user