-
-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] Changing PRUNE_RESULTS_OLDER_THAN value doesn't have any effect #2006
Comments
Did it work when you used 180? |
Good point! I checked my results and my oldest one goes back to June 8 which is more than 7 months old. Does this mean the feature is not working at all regardless of the settings? It's a long time I've been maintaining the exact same instance with the same database, etc and only been auto-updated with WatchTower. Could it be because of an older version corrupted the settings? |
When I run the command manual it all works as intended. Can you share your docker compose. |
I have automated my docker apps [un]installations using Ansible, so there is no docker compose file and I'm running the database in a separate docker container. Here is what I have for docker container installation for SpeedTest-Tracker only: (the variables are replaced by Ansible by their corresponding values)
... and the
If you need to know the actual value of a particular variable or a setting/record in the database, please let me know and I will post them here. By the way, what's the cron schedule for pruning the results history? Is it calculated from the container up time? I don't see any cron schedule variable in the env variables. |
It's using the laravel task scheduler for it. It should run every day at midnight. Might have an idea why it does not run but I need to double check with Alex, before I say anything stupid. |
Just to confirm since it's behind a config you're using the LSIO image right? |
Yes, right. |
@armond-avanes if you run |
So I logged into my SpeedTest-Tracker container using Portainer and executed the above line. Here is the error I got back: |
You need to be in the |
Thanks for the clarification. I switched to that folder and executed the command. Here is the new error stack trace:
|
Alrighty... Now we're getting somewhere. I'll put a patch together to always cast the value as an integer. |
Describe the bug
When I decrease the value of PRUNE_RESULTS_OLDER_THAN environment variable from 180 to 90 (days), it doesn't prune my result history. I've been waiting for two days for this process to happen, because I thought it might have been scheduled for a specific time of the day to be executed.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
To prune my result history according to the current value of PRUNE_RESULTS_OLDER_THAN.
Environment (please complete the following information):
Additional context
I've searched the
settings
table in the database and I couldn't find anyprune_results_older_than
record there. So looks like there is only one source of truth for this setting and that's the environment variable.The text was updated successfully, but these errors were encountered: