go-debos / debos

Debian OS builder
Apache License 2.0
542 stars 139 forks source link

Make the debootstrap script argument configurable #16

Open em- opened 7 years ago

em- commented 7 years ago

debos currently hardcodes /usr/share/debootstrap/scripts/unstable as the debootstrap script, which of course is not always appropriate.

It should be customizable, possibly with some magic to make local files available in the fakemachine even without installing the script in the host's /usr (it would be handy to ship the script in the same repository as the YAML for debos and directly use that).

sjoerdsimons commented 7 years ago

I'm wary about custom debootstrap scripts. There are some interdependencies between debootstrap options, debootstrap and the scripts. E.g. the merged user option is only actaully used if you use a "debian" script, not in the ubuntu ones.

Other then that, all the scripts are really similar, only changes are the default mirrors (debos has a workaround for that) and the keyring file which should be addressed in #21 hopefully.

It's reasonable for the host to try to match the debootstrap script to the suite rather then hardcoding it as is currently, but then you hit the merged-user issue if you're bootstrapping ubuntu bits.. And doesn't help you when doing derivatives.

For now i'm somewhat leaning of keeping the hardcoded behaviour in for now; It would be useful to do a further diagnosis though to see what significant items actaully change between the debian and ubuntu scripts debos cannot deal with.

Fwiw for the longer term, i'd like to drop debootstrap and have something similar implemented in go (it really isn't that hard what the crazy shell scripts do). That would also make it easier to implement caching and more efficent downloads and whatnot

smcv commented 2 years ago

This has become more problematic in the recent Debian 11.5 and 10.13 point releases, after which the unstable script assumes that we are genuinely installing Debian (not just some Debian derivative, but really Debian), and therefore all suites not in its list of older releases should install usr-is-merged, which of course doesn't exist in older Debian derivatives like the Steam Runtime.

Fwiw for the longer term, i'd like to drop debootstrap and have something similar implemented in go

Using mmdebstrap seems like it could be another good option.

smcv commented 2 years ago

the unstable script assumes that we are genuinely installing Debian (not just some Debian derivative, but really Debian), and therefore all suites not in its list of older releases should install usr-is-merged

See also #358

Using mmdebstrap seems like it could be another good option

See also #127

sjoerdsimons commented 2 years ago

This has become more problematic in the recent Debian 11.5 and 10.13 point releases, after which the unstable script assumes that we are genuinely installing Debian (not just some Debian derivative, but really Debian), and therefore all suites not in its list of older releases should install usr-is-merged, which of course doesn't exist in older Debian derivatives like the Steam Runtime.

Didn't expect that to get rolled back into a point release; fun fun

Fwiw for the longer term, i'd like to drop debootstrap and have something similar implemented in go

Using mmdebstrap seems like it could be another good option.

Fwiw i've gone back on that quite a while back; While debootstrap is not great for a bunch of reasons, it's still the one officially supported by the installer team so it is the safest default. I'm wary of switching to something else as i'd really woudln't like having multiple options available directly in debos (and in the end, one can always use an alternative bootstrapping tool through run actions)

obbardc commented 2 years ago

Suggestions welcome on how we can fix this in Debos. By default Debian builds all versions with the sid script, there's no reason why we shouldn't be able to do that in downstreams also.

The debootstrap developers didn't seem keen on my suggestion of only adding usr-is-merged if the suite is testing/unstable (but that's kind of expected anyway) https://salsa.debian.org/installer-team/debootstrap/-/merge_requests/73