FROM hypriot/rpi-alpine-scratch

RUN apk update \
    && apk upgrade \
    && apk add rsync

# run rsync
# we do not change ownerships as this is a samba mounted target drive
CMD rsync -a --no-o --no-g -v --delete /opt/from/ /opt/to/ | true && \
    echo "$(date '+%a %H:%M:%S %h %d %Y') sleeping 1h now.." && \
    sleep 3600s

