Jenkins migration local to container

I currently have a Jenkins installation, version Jenkins 2.385, on a Linux Ubuntu machine. However, I wish to migrate this installation into a Docker container using an appropriate Jenkins image, aiming to facilitate future upgrades, as working with containers becomes easier and more secure.

Nevertheless, I have several Jenkins plugins already installed and many configurations in place, and I don’t want to lose anything.

What alternatives do I have, and how can I go about migrating everything I currently have in Jenkins to this new setup? Alternatively, how can I migrate it to a Docker container?