[packages] rsync: Add initscript for rsync daemon
Add an initscript to the rsync package for use as a daemon, and a sample rsyncd.conf to show a simple setup. Signed-off-by: Ian Leonard <antonlacon@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/packages@26630 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
15
net/rsync/files/rsyncd.conf
Normal file
15
net/rsync/files/rsyncd.conf
Normal file
@ -0,0 +1,15 @@
|
||||
# /etc/rsyncd.conf
|
||||
# Minimal configuration for rsync daemon
|
||||
|
||||
# Next line required for init script
|
||||
pid file = /var/run/rsyncd.pid
|
||||
use chroot = yes
|
||||
uid = nobody
|
||||
gid = nogroup
|
||||
read only = yes
|
||||
|
||||
# Simple example to configure server
|
||||
#[openwrt-etc]
|
||||
#path = /etc
|
||||
#comment = OpenWrt Configuration Files
|
||||
#exclude = /init.d
|
15
net/rsync/files/rsyncd.init
Normal file
15
net/rsync/files/rsyncd.init
Normal file
@ -0,0 +1,15 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
# Copyright (C) 2011 OpenWrt.org
|
||||
|
||||
START=50
|
||||
BIN=/usr/bin/rsync
|
||||
PID=/var/run/rsyncd.pid
|
||||
SSD=start-stop-daemon
|
||||
|
||||
start() {
|
||||
$SSD -p $PID -S -x $BIN -- --daemon
|
||||
}
|
||||
|
||||
stop() {
|
||||
$SSD -p $PID -K
|
||||
}
|
Reference in New Issue
Block a user