10. Optionally, follow the instructions below to migrate your existing data to PostgreSQL.
+Migrating from LinuxServer.io Docker Image
+========================
+
+As with any upgrades and large changes, it is highly recommended to create a backup before
+starting. This assumes the image was running using Docker Compose, but the instructions
+are translatable to Docker commands as well.
+
+1. Stop and remove the paperless container
+2. If using an external database, stop the container
+3. Update Redis configuration
+
+ a) If ``REDIS_URL`` is already set, change it to ``PAPERLESS_REDIS`` and continue
+ to step 3.
+ b) Otherwise, in the ``docker-compose.yml`` add a new service for Redis,
+ following `the example compose files <https://github.com/paperless-ngx/paperless-ngx/tree/main/docker/compose>`
+ b) Set the environment variable ``PAPERLESS_REDIS`` so it points to the new Redis container
+
+4. Update user mapping
+
+ a) If set, change the environment variable ``PUID`` to ``USERMAP_UID``
+ b) If set, change the environment variable ``PGID`` to ``USERMAP_GID``
+
+5. Update configuration paths
+
+ a) Set the environment variable ``PAPERLESS_DATA_DIR``
+ to ``/config``
+
+6. Update media paths
+
+ a) Set the environment variable ``PAPERLESS_MEDIA_ROOT``
+ to ``/data``
+
+7. Update timezone
+
+ a) Set the environment variable ``PAPERLESS_TIME_ZONE``
+ to the same value as ``TZ``
+
+8. Modify the ``image:`` to point to ``ghcr.io/paperless-ngx/paperless-ngx:latest`` or
+ a specific version if preferred.
+
+9. Start the containers as before, using ``docker-compose``.
+
.. _setup-sqlite_to_psql:
Moving data from SQLite to PostgreSQL