sleep timer configuration
This commit is contained in:
parent
ee9f24e1ba
commit
9e447a570e
@ -19,6 +19,7 @@ ENV NEXTCLOUD_DOWNLIMIT=
|
||||
ENV NEXTCLOUD_EXCLUDEFILE=
|
||||
ENV NEXTCLOUD_UNSYNCFILE=
|
||||
ENV NEXTCLOUD_SILENT=
|
||||
ENV NEXTCLOUD_SLEEP=30
|
||||
|
||||
COPY start.sh /start.sh
|
||||
|
||||
|
@ -62,6 +62,7 @@ docker-compose up -d
|
||||
| NEXTCLOUD_EXCLUDEFILE | | Path to a file, inside the container, which contains a list of excluded directories/files |
|
||||
| NEXTCLOUD_UNSYNCFILE | | Path to a file, inside the container, which contains a list of remote unsynced folders (selective sync) |
|
||||
| NEXTCLOUD_SILENT | | If set to "1", the client will run in silent mode, with a lot less log messages |
|
||||
| NEXTCLOUD_SLEEP | 30 | Seconds of sleep time between every client runs |
|
||||
| USER_NAME | nextcloudclient | Internal username used by nextcloud client |
|
||||
| USER_UID | 1000 | Internal UID used by nextcloud client |
|
||||
| USER_GID | 1000 | Internal GID used by nextcloud client |
|
||||
|
3
start.sh
3
start.sh
@ -9,6 +9,7 @@ NEXTCLOUD_PASSWORD=${NEXTCLOUD_PASSWORD:-password}
|
||||
NEXTCLOUD_URL=${NEXTCLOUD_URL:-https://nextcloud.example.com}
|
||||
NEXTCLOUD_DIR=${NEXTCLOUD_DIR:-/data}
|
||||
NEXTCLOUD_DIR_CHOWN=${NEXTCLOUD_DIR_CHOWN:-1}
|
||||
NEXTCLOUD_SLEEP=${NEXTCLOUD_SLEEP:-30}
|
||||
|
||||
# check if group already exists
|
||||
GRP_NAME=$(getent group ${USER_GID} )
|
||||
@ -70,5 +71,5 @@ PARAMS="${PARAMS} --non-interactive -u ${NEXTCLOUD_USERNAME} -p ${NEXTCLOUD_PASS
|
||||
# main loop
|
||||
while true; do
|
||||
/bin/su -s /bin/sh ${USER_NAME} -c "/usr/bin/nextcloudcmd ${PARAMS}"
|
||||
sleep 10
|
||||
sleep ${NEXTCLOUD_SLEEP}
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user