mirror of
https://github.com/vimagick/dockerfiles.git
synced 2024-12-23 01:39:27 +02:00
20 lines
351 B
Bash
20 lines
351 B
Bash
|
#!/bin/bash
|
||
|
#
|
||
|
# backup userdata to aliyun oss cloud storage
|
||
|
# (please run it as cron job)
|
||
|
#
|
||
|
# https://help.aliyun.com/document_detail/50452.html
|
||
|
#
|
||
|
|
||
|
FILES=/root/fig/nextcloud/data/data
|
||
|
USERS=(admin kev)
|
||
|
|
||
|
export PATH=/usr/local/bin:$PATH
|
||
|
|
||
|
cd $FILES || exit
|
||
|
|
||
|
for user in ${USERS[@]}
|
||
|
do
|
||
|
ossutil cp -r -u $user oss://easypi/nextcloud/$user
|
||
|
done
|