You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to suggest to implement a way to specify time slot for automated conversions. I would desire it to be triggered only during night hours when I am not using the server for other activities..
Haven't seen this in documentation so I expect it is not possible at the moment.. Please let me know if it is something you can implement in your image.
Should be possible via CRON. I would like to see multiple CRON slots so it can be combined in a more precise way:
Monday-Friday from midnight until 4pm: 0 0-16 * * MON-FRI
Saturday-Sunday from 2am until 10am: 0 2-10 * * SAT-SUN
Although such feature seems to be not implemented, as a workaround, you can take advantage of a pre-conversion hook (docs), that will pause the execution of the conversion as long as a certain condition is met.
An example pre-conversion hook could look like this:
#!/bin/sh# ...
current_time="$(date +'%s')"
min_time="$(date -d '14:00' +'%s')"while [ "$current_time"-lt"$min_time" ];doecho"pre-conversion: Conversion is paused until 14:00"
sleep 60
current_time="$(date +'%s')"done
(Make sure your timezone is set correctly within the container.)
Of course, you will have to implement your own pause condition logic depending on your needs.
Idea
Hello,
I would like to suggest to implement a way to specify time slot for automated conversions. I would desire it to be triggered only during night hours when I am not using the server for other activities..
Haven't seen this in documentation so I expect it is not possible at the moment.. Please let me know if it is something you can implement in your image.
Should be possible via CRON. I would like to see multiple CRON slots so it can be combined in a more precise way:
0 0-16 * * MON-FRI
0 2-10 * * SAT-SUN
Having such environment variable:
AUTOMATED_CONVERSION_TIMEFRAME: ['0 0-16 * * MON-FRI', '0 2-10 * * SAT-SUN']
Then implement just
if
check if the current time is within given CRON range.Appreciate, Michal
The text was updated successfully, but these errors were encountered: