sudo mkdir -p /srv/docker-data/syncthing #Similar to others, saving config files etc.
sudo mkdir -p /mnt/data/shared/Synced #One directory that will by synchronized

Set the correct permissions so the container can write in these folders

sudo chown -R 1000:1000 /srv/docker-data/syncthing
sudo chown -R 1000:1000 /mnt/data/syncthing

(We use 1000:1000 because it’s the default User ID and Group ID for most community-built Docker containers, ensuring proper permissions.)

Go to stack in Portainer and add this in the web-editor and simply deploy

version: "3.5"
services:
  syncthing:
    image: lscr.io/linuxserver/syncthing:latest
    container_name: syncthing
    hostname: syncthing
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Finland/Helsinki # You can change this to your timezone, e.g., "America/New_York"
    volumes:
      - /srv/docker-data/syncthing:/config
      - /mnt/data/shared/Synced:/data # This is the main sync folder
    ports:
      - 8384:8384    # Web UI
      - 22000:22000/tcp # File transfer
      - 22000:22000/udp # File transfer
      - 21027:21027/udp # Local discovery
    restart: unless-stopped

Important point to note: the syncthing can’t see the native file structure for it /mnt/data/share/Synced == /data so, if there is a subfolder it has to me written as /data/subfolder inside the syncthing UI, similar for all the docker installed things such as Jellyfin