Fix bug #111: Added nmdc-redirector similar to the adc-redirector.

This commit is contained in:
Jan Vidar Krey 2010-02-07 23:37:21 +01:00
parent be8db21561
commit 74a2191350
1 changed files with 20 additions and 0 deletions

20
tools/nmdc-redirector Executable file
View File

@ -0,0 +1,20 @@
#!/usr/bin/perl -w
# Setup using inetd/xinetd or similar.
# In /etc/inetd.conf add:
# 1511 stream tcp nowait nobody /usr/bin/nmdc-redirector adc://target:port
#
# Change port to whatever you want.
# Make sure the path and the target:port is correct, then you should be good
# to go!
use strict;
use IO::Handle;
autoflush STDIN;
autoflush STDOUT;
my $target = $ARGV[0];
print "<Redirector> You are being redirected to " . $target . "|";
print "\$ForceMove " . $target . "|";