Help getting out of Plugin purgatory- jail upgrading

This is more of a Plugin jail question than a NextCloud question, but for background… Many years ago I made the mistake of installing NextCloud via plugin. Early on I found it challenging to upgrade NextCloud, and doing a jail upgrade via the GUI would break it, so I kind of gave up. I’ve been trying to migrate to a clean jail/install on and off for a few years now.

I think my biggest hurdle is that I can’t migrate straight from NextCloud 17 to 30; when I drop and reload the database it breaks the new install. So that’s where my focus is now.

Truenas CORE is up to date 13.3. The jail is running 11.2-RELEASE-p15. When I try a CLI jail upgrade to 13.3, Truenas checks the plugins train and finds that it doesn’t exist anymore.

root@truenas:~ # iocage upgrade nextcloud

Branch 13.3-RELEASE does not exist at https://github.com/freenas/iocage-plugin-nextcloud.git!
Using "master" branch for plugin, this may not work with your RELEASE
New plugin RELEASE missing, fetching now...
13.2-RELEASE was not found!

I know editing files on Truenas isn’t recommended, but I can change it back when I’m done: is there ANY way to force Truenas to use a different repository for upgrading a jail created via plugin? If so, what file do I edit, and what’s the address?

Alternatively within the jail, I can try pkg update and at least try to get dependencies for newer versions of NextCloud. The problem there is that it looks in “pkg: http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest/meta.txz” and FreeBSD:11:amd64 doesn’t exit anymore. When I look here (http://pkg.freebsd.org/) there’s nothing before FreeBSD:13. Is there an alternate pkg repository for FreeBSD:11 I can tell it to use instead?

I did find this command:

iocage fetch --root-dir /pub/FreeBSD-Archive/old-releases/amd64/ --server ftp-archive.freebsd.org

That lets me grab 13.2 which allows the upgrade to proceed, but only as far as the plugin pkg installs which then fails because plugins are EOL. I just feel like there should be some way to break free of the plugin train and just use regular pkg’s…

I ultimately decided scrapping my old Nextcloud install was the only way. I’ve been working on this on and off for 4 years, and I feel like with this last 12 hour or so push of trying new things, there simply is no way to upgrade a plugin jail successfully. Every failed attempt breaks the jail and requires a snapshot rollback. There is also no way to merge a very old Nextcloud database into a modern install (which is why they recommend upgrading to the same version before attempting). I can confirm in a clean install their backup/restore database procedure does work without an issue on the same version.

In the end, it was a journey, but using a clean install wasn’t so bad. My biggest concern was my CardDAV scheme which many people depend on for work contacts. However, keeping the domain, user names, address book names, and everything else the same resulted in a seamless transition. iOS subscriptions had no clue it was a different Nextcloud, and just carried on like nothing had happened.