Redis stores celery’s scheduled tasks, so does redis need to be persistent?

  docker, question

Hello, everyone.
I am a green hand.

I want to run redis in docker, which is very convenient for development and deployment.
I recently made a website and used redis and celery

However, I am worried that docker restart or physical machine restart will cause redis to lose data.

Is it necessary to persist redis?

What is the best plan for concrete sustainability?

Redis can be placed outside the container, installed directly on the physical machine, and then RDB, AOF