-
Notifications
You must be signed in to change notification settings - Fork 433
Conversation
IIRC the local-tarball names are actually specified by the names in |
Maybe I phrased it badly. (it is a small enhancement to give greater flexibility.) |
Oh, I'd never seen that feature actually used ;-) Does it make sense to be able to specify absolute local filepaths? It kinda breaks the idea of each OS being self-contained in its own
Just out of curiosity, what flexibility does this give you that editing the |
If you look at LibreElec, the tarballs are as follows: When I re-implemented Arch, I used labels of |
I don't want to specify absolute local paths - the point of this PR is so that I don't have to. :) And NOOBS already takes care of conflicting partition names for different OSes in case there is a clash (by appending an index number) |
As far as I can tell, this change isn't backwards compatible, so distros taking advantage of this wouldn't work with older versions of NOOBS, which isn't ideal. Given that we only deal with distros which support NOOBS, I'm not sure that this is a good idea. Or did I get this wrong? |
You got it wrong 😉 Remember there are 2 ways to install an OS: from the internet, or from a local source (SD card, USB etc).
Because, generally, the tarball name matches the partition name, LibreELEC partitions.json specifies the label name as "LibreELEC_RPi_System", which we realise from #460 is an invalid label name. For a remote install, we could change the label name to be valid in partitions.json and it will still install remotely because the tarball specifies the URL exactly.
So this PR recognises a relative path in the local tarball field of os.json, and adds the absolute path to it so the file can be found. Existing tarballs that have absolute paths or URLs are unaffected. It can make it easier to download OSes for local installation. This modification is included in PINN and works fine with all existing RPF OSes, whether installed remotely or locally. You may not need to use it at the moment since #460 has been merged, but it would allow you to manually shorten overly long partition labels like in LibreELEC and keep the existing overly long tarball filenames. It just provides more options. |
And what happens if you use current NOOBS with a PINN OS which takes advantage of this feature? Won't it fail to find the tarball? |
Correct - (only if you did a straight download of the /os from the repo and tried to install it locally). I think the only OS I modified in this way was Arch. |
Right, that was what I meant when I said it wasn't backwards compatible. If we merged this, we wouldn't be able to use it. |
Because a user with an old version of NOOBS wouldn't be able to install a newer OS that used this feature, without upgrading NOOBS? |
That is my understanding, yes. Given than NOOBS doesn't have an 'upgrade' feature, the limitation is that we can only break things if we really have to. |
Yup, when I was working on NOOBS I tried my best to keep it both forwards and backwards compatible, i.e. older versions of NOOBS could still download & install the latest OSes (where applicable) from the internet (which is why there's separate Unless I'm still misunderstanding it, this PR doesn't "fix" anything that couldn't be "fixed" by simply renaming the local tarballs you've downloaded? (which would seem to me to be the simpler option) |
Which is why I've closed it. BTW - I looked at |
Yeah - it was all quite a while ago now, but IIRC some older versions of NOOBS aren't compatible with some of the newer OSes (I recall RiscOS being a bit problematic due to its non-standard partition handling) so the older versions of NOOBS are only compatible with certain versions of RiscOS, and they use
Then NOOBS v3.4 would download And the whole process was repeated again with |
Yeah, os_list_v3.json was added for windows. There may be all kind of unintentional inconsistencies with various versions of os_list. The script that automatically updates them is broken and I've never set time aside to fix it. |
The
tarball
field is used to specify an external URL to download an image from. Often these external images do not have the default filename ofpartition.tar.xz
. Iftarball
is absent, the image is assumed to be local and have the same name as the partition (e.g.root.tar.xz
). But it could equally specify a different local image filename rather than the default, but in this case the complete path must be used (and therefore known).This PR adds the image folder to the tarball if one does not already exist, so that alternative image filenames can be specified and found in their correct location (Useful if you want to have a local copy of one of these images in your SDcard /os folder without having to change the name to the default)