From 37621796d21590337438a2f9e2a9b9dd10f7784a Mon Sep 17 00:00:00 2001 From: Guilouf Date: Mon, 30 Dec 2024 11:42:46 +0100 Subject: [PATCH] Rename delete_outdated_conversations.py to anonymize_outdated_conversations.py --- ...te_outdated.sh => conversations_anonymize_outdated.sh} | 8 ++++---- clevercloud/cron.json | 2 +- ...nversations.py => anonymize_outdated_conversations.py} | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) rename clevercloud/{conversations_delete_outdated.sh => conversations_anonymize_outdated.sh} (62%) mode change 100755 => 100644 rename lemarche/conversations/management/commands/{delete_outdated_conversations.py => anonymize_outdated_conversations.py} (62%) diff --git a/clevercloud/conversations_delete_outdated.sh b/clevercloud/conversations_anonymize_outdated.sh old mode 100755 new mode 100644 similarity index 62% rename from clevercloud/conversations_delete_outdated.sh rename to clevercloud/conversations_anonymize_outdated.sh index d139c247c..81ed6d183 --- a/clevercloud/conversations_delete_outdated.sh +++ b/clevercloud/conversations_anonymize_outdated.sh @@ -1,10 +1,10 @@ #!/bin/bash -l -# delete outdated conversations +# anonymize outdated conversations # Do not run if this env var is not set: -if [[ -z "$CRON_CONVERSATIONS_DELETE_OUTDATED" ]]; then - echo "CRON_CONVERSATIONS_DELETE_OUTDATED not set. Exiting..." +if [[ -z "$CRON_CONVERSATIONS_ANONYMIZE_OUTDATED" ]]; then + echo "CRON_CONVERSATIONS_ANONYMIZE_OUTDATED not set. Exiting..." exit 0 fi @@ -19,4 +19,4 @@ fi # $APP_HOME is set by default by clever cloud. cd $APP_HOME -django-admin delete_outdated_conversations +django-admin anonymize_outdated_conversations diff --git a/clevercloud/cron.json b/clevercloud/cron.json index 9a85f2c18..a9c943dc2 100644 --- a/clevercloud/cron.json +++ b/clevercloud/cron.json @@ -3,7 +3,7 @@ "15 0 * * * $ROOT/clevercloud/stats_export_user_download_list_to_file.sh", "30 0 * * * $ROOT/clevercloud/stats_export_user_search_list_to_file.sh", "0 1 * * * $ROOT/clevercloud/tenders_update_count_fields.sh", - "0 6 * * * $ROOT/clevercloud/conversations_delete_outdated.sh", + "0 6 * * * $ROOT/clevercloud/conversations_anonymize_outdated.sh", "0 7 * * 1 $ROOT/clevercloud/siaes_sync_with_emplois_inclusion.sh", "5 7 * * 1 $ROOT/clevercloud/siaes_sync_c2_c4.sh", "10 7 * * 1 $ROOT/clevercloud/siaes_update_api_entreprise_fields.sh", diff --git a/lemarche/conversations/management/commands/delete_outdated_conversations.py b/lemarche/conversations/management/commands/anonymize_outdated_conversations.py similarity index 62% rename from lemarche/conversations/management/commands/delete_outdated_conversations.py rename to lemarche/conversations/management/commands/anonymize_outdated_conversations.py index 3a1006dc8..1bbd6874e 100644 --- a/lemarche/conversations/management/commands/delete_outdated_conversations.py +++ b/lemarche/conversations/management/commands/anonymize_outdated_conversations.py @@ -3,10 +3,10 @@ class Command(BaseCommand): """ - Command to delete outdated conversations + Command to anonymize outdated conversations Note: run via a CRON every day - Usage: python manage.py delete_outdated_conversations + Usage: python manage.py anonymize_outdated_conversations """ def handle(self, *args, **options):