This commit is contained in:
2024-01-31 18:06:16 +08:00
parent d54a0b84bb
commit fc79d5d350
9 changed files with 102 additions and 8 deletions

View File

@@ -34,12 +34,12 @@ function Quit {
function StartProc {
Print Starting rsync ...
rm -f /var/run/rsyncd.pid
rm -f $LOG_DIR/rsyncd.pid
rsync --daemon \
--no-detach \
--port=873 \
--log-file=$LOG_DIR/rsyncd.log \
--dparam=pidfile=/var/run/rsyncd.pid \
--dparam=pidfile=$LOG_DIR/rsyncd.pid \
&>> $LOG_DIR/rsyncd.out &
PIDS="$PIDS $!"
Print Rsync started.

View File

@@ -1,9 +1,9 @@
ARG ARCH
FROM harbor.colben.cn/general/alpine$ARCH
FROM harbor.colben.cn/general/alpine$ARCH:3.12
MAINTAINER Colben colbenlee@gmail.com
ADD --chown=root:root /ADD/ /opt/
RUN apk update \
&& apk add --no-cache rsync \
&& apk add --no-cache rsync inotify-tools \
&& mkdir -p /var/log/rsync \
&& rm -rf /var/cache/apk/*
CMD ["/opt/ccmd"]

View File

@@ -9,7 +9,7 @@ export LANG=en_US.UTF-8
[ 'x86_64' == "$(uname -m)" ] && ARCH='' || ARCH="-$(uname -m)"
ROOT_DIR="$(cd $(dirname $0) && pwd)"
IMAGE="harbor.colben.cn/general/$(basename ${0%.sh})$ARCH:latest"
IMAGE="harbor.colben.cn/general/$(basename ${0%.sh})$ARCH:3.1.3"
if [ -t 0 ]; then
function Print { echo -e "\033[36;1m$(date +'[%F %T]')\033[32;1m $*\033[0m"; }