1
Fork 0
mirror of https://github.com/Steffo99/backup-duplicity.git synced 2024-12-22 11:34:22 +00:00

Use absolute paths

This commit is contained in:
Steffo 2023-05-17 17:04:16 +02:00
parent a2dac69741
commit 20cc310e4b
Signed by: steffo
GPG key ID: 2A24051445686895
3 changed files with 16 additions and 8 deletions

View file

@ -80,7 +80,7 @@
<workItem from="1684324347198" duration="751000" /> <workItem from="1684324347198" duration="751000" />
<workItem from="1684325989651" duration="719000" /> <workItem from="1684325989651" duration="719000" />
<workItem from="1684326731845" duration="241000" /> <workItem from="1684326731845" duration="241000" />
<workItem from="1684331412572" duration="54000" /> <workItem from="1684331412572" duration="720000" />
</task> </task>
<task id="LOCAL-00001" summary="Add proper python cryptography requirements"> <task id="LOCAL-00001" summary="Add proper python cryptography requirements">
<created>1684080793392</created> <created>1684080793392</created>
@ -124,7 +124,14 @@
<option name="project" value="LOCAL" /> <option name="project" value="LOCAL" />
<updated>1684326830505</updated> <updated>1684326830505</updated>
</task> </task>
<option name="localTasksCounter" value="7" /> <task id="LOCAL-00007" summary="Add missing sh files to image">
<created>1684331474276</created>
<option name="number" value="00007" />
<option name="presentableId" value="LOCAL-00007" />
<option name="project" value="LOCAL" />
<updated>1684331474276</updated>
</task>
<option name="localTasksCounter" value="8" />
<servers /> <servers />
</component> </component>
<component name="TypeScriptGeneratedFilesManager"> <component name="TypeScriptGeneratedFilesManager">
@ -148,6 +155,7 @@
<MESSAGE value="Backup at startup" /> <MESSAGE value="Backup at startup" />
<MESSAGE value="Quote variables" /> <MESSAGE value="Quote variables" />
<MESSAGE value="Fix idea modules" /> <MESSAGE value="Fix idea modules" />
<option name="LAST_COMMIT_MESSAGE" value="Fix idea modules" /> <MESSAGE value="Add missing sh files to image" />
<option name="LAST_COMMIT_MESSAGE" value="Add missing sh files to image" />
</component> </component>
</project> </project>

View file

@ -14,12 +14,12 @@ WORKDIR /var/lib/duplicity
ENV HOME="/var/lib/duplicity" ENV HOME="/var/lib/duplicity"
# Add entrypoint # Add entrypoint
COPY ./entrypoint.sh ./entrypoint.sh COPY ./entrypoint.sh /usr/lib/backup-duplicity/entrypoint.sh
COPY ./restore.sh ./restore.sh COPY ./restore.sh /usr/lib/backup-duplicity/restore.sh
COPY ./backup.sh /etc/periodic/daily/backup.sh COPY ./backup.sh /etc/periodic/daily/backup.sh
# Configure entrypoint and command # Configure entrypoint and command
ENTRYPOINT ["./entrypoint.sh"] ENTRYPOINT ["/usr/lib/backup-duplicity/entrypoint.sh"]
CMD [] CMD []
# Add image labels # Add image labels

View file

@ -3,13 +3,13 @@
case "$MODE" in case "$MODE" in
backup) backup)
echo "Running first backup..." echo "Running first backup..."
./backup.sh /usr/lib/backup-duplicity/backup.sh
echo "Running cron for daily backups..." echo "Running cron for daily backups..."
crond -f -d 5 -l info crond -f -d 5 -l info
;; ;;
restore) restore)
echo "Restoring from latest backup..." echo "Restoring from latest backup..."
./restore.sh /usr/lib/backup-duplicity/restore.sh
;; ;;
*) *)
echo "No such mode." >> /dev/stderr echo "No such mode." >> /dev/stderr