When a user or visitor posts (but not when they edit) a comment, their IP address is logged for spam and abuse prevention. The IP address is stored in the database and visible to admins on the comment.
We would like a Scheduler task that will run daily and set the IP addresses on comments posted more than 30 days ago to nil. The number should be configurable; 30 is only an example.
It will be purging a lot of data the first time it runs – the initial clean-up may warrant a different approach than the daily task.
Testing
Log in as a user and post a comment
Log in as an admin and observe the IP address on the comment
Have a database admin run the task
Log in as an admin and make sure the work says "No address recorded"
Note that there is some caching on the comment sections that has caused difficulty with seeing IP addresses in the past, so it is probably best to check the comment itself by going to https://test.archiveofourown.org/comments/####