Skip to content

Commit ccda858

Browse files
committed
Release 4.0.27 - See CHANGELOG.md
1 parent d58b27d commit ccda858

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## 4.0.27 2023-12-04 <dave at tiredofit dot ca>
2+
3+
### Changed
4+
- Switch to using actual crontab for cron expressions
5+
6+
17
## 4.0.26 2023-11-30 <dave at tiredofit dot ca>
28

39
### Added

install/assets/dbbackup/template-dbbackup/run

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,8 @@ if [[ "${MODE,,}" =~ "standalone" ]] || [ "${MODE,,}" = "manual" ] || [ "${1,,}"
2222
backup_job_backup_begin=+0
2323
else
2424
silent sleep {{BACKUP_NUMBER}}
25-
set -x
2625
time_last_run=0
2726
time_current=$(date +'%s')
28-
set +x
2927
if [[ "${backup_job_backup_begin}" =~ ^\+(.*)$ ]]; then
3028
print_debug "BACKUP_BEGIN is a jump of minute starting with +"
3129
timer plusvalue
@@ -45,8 +43,8 @@ else
4543
backup_job_backup_begin=${backup_job_backup_begin//\'/}
4644
timer cron "${backup_job_backup_begin}" "${time_current}" "${time_last_run}"
4745
else
48-
echo "${backup_job_backup_begin} /var/run/s6/legacy-services/dbbackup-{{BACKUP_NUMBER}} now" > /tmp/.container/cron/{{BACKUP_NUMBER}}-backup
49-
crontab -l | { cat; echo "${backup_job_backup_begin} /var/run/s6/legacy-services/dbbackup-{{BACKUP_NUMBER}} now"; } | crontab -
46+
echo "${backup_job_backup_begin} /var/run/s6/legacy-services/dbbackup-{{BACKUP_NUMBER}}/run now" > /tmp/.container/cron/{{BACKUP_NUMBER}}-backup
47+
crontab -l | { cat; echo "${backup_job_backup_begin} /var/run/s6/legacy-services/dbbackup-{{BACKUP_NUMBER}}/run now"; } | crontab -
5048
s6-svc -d /var/run/s6/legacy-services/dbbackup-{{BACKUP_NUMBER}}
5149
exit 0
5250
fi

install/assets/functions/10-db-backup

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2000,12 +2000,13 @@ timer() {
20002000
fi
20012001
cron_parsed=0
20022002
done
2003-
2003+
set -x
20042004
local cron_future=$(date --date="${cron_next_year}-$(printf "%02d" ${cron_next_month})-$(printf "%02d" ${cron_next_day_of_month})T$(printf "%02d" ${cron_next_hour}):$(printf "%02d" ${cron_next_minute}):00" "+%s")
20052005
local cron_future_difference=$(( cron_future - cron_compare_seconds ))
20062006
time_cron=true
20072007
time_wait="${cron_future_difference}"
20082008
time_future="${cron_future}"
2009+
set +x
20092010
;;
20102011
datetime)
20112012
time_begin=$(date -d "${backup_job_backup_begin}" +%s)

0 commit comments

Comments
 (0)