This commit is contained in:
parent
d0d187f203
commit
1f8d77b98d
@ -1,5 +1,5 @@
|
|||||||
FROM python:alpine3.18
|
FROM python:alpine3.18
|
||||||
RUN apk add --no-cache mariadb-client rclone supercronic docker restic
|
RUN apk add --no-cache mariadb-client rclone supercronic docker restic zip
|
||||||
COPY . opt
|
COPY . opt
|
||||||
RUN chmod +x /opt/entrypoint.sh
|
RUN chmod +x /opt/entrypoint.sh
|
||||||
RUN chmod +x /opt/restic.sh
|
RUN chmod +x /opt/restic.sh
|
||||||
|
@ -79,7 +79,7 @@ apprise_body = os.getenv("apprise_body")
|
|||||||
|
|
||||||
# Stop seafile and seafile hub
|
# Stop seafile and seafile hub
|
||||||
if docker_command:
|
if docker_command:
|
||||||
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seahub.sh stop')
|
os.system(f'docker exec {container_name} /opt/seafile/seafile-serverlatest/seahub.sh stop')
|
||||||
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seafile.sh stop')
|
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seafile.sh stop')
|
||||||
|
|
||||||
# Dump the databases
|
# Dump the databases
|
||||||
@ -106,12 +106,12 @@ if rclone_push:
|
|||||||
|
|
||||||
# Remote restic backup
|
# Remote restic backup
|
||||||
if restic_push:
|
if restic_push:
|
||||||
os.system("./restic.sh")
|
os.system("/opt/restic.sh")
|
||||||
|
|
||||||
# Start seafile and seafile hub
|
# Start seafile and seafile hub
|
||||||
if docker_command:
|
if docker_command:
|
||||||
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seahub.sh start')
|
|
||||||
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seafile.sh start')
|
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seafile.sh start')
|
||||||
|
os.system(f'docker exec {container_name} /opt/seafile/seafile-server-latest/seahub.sh start')
|
||||||
|
|
||||||
# compress db files
|
# compress db files
|
||||||
if zip_db_files:
|
if zip_db_files:
|
||||||
@ -125,8 +125,7 @@ if offload_db_files:
|
|||||||
# cleanup
|
# cleanup
|
||||||
if cleanup:
|
if cleanup:
|
||||||
os.system(f'rm {db_dump_tmp_path}*sfdb_*')
|
os.system(f'rm {db_dump_tmp_path}*sfdb_*')
|
||||||
os.system(f'Rclone delete -P \
|
os.system(f'rclone delete -P {rclone_db_retention} {rclone_remote}:{rclone_remote_db_path}')
|
||||||
{rclone_db_retention} {rclone_remote}:{rclone_remote_db_path}')
|
|
||||||
|
|
||||||
# healthcheck
|
# healthcheck
|
||||||
if healthcheck:
|
if healthcheck:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user