#1308 use_bootstrap and use_bootstrap_image options revamp
Closed: Fixed 3 years ago by praiskup. Opened 4 years ago by praiskup.

After recent discussions in mock upstream [1], we'll soon have to have
a way to enable use_bootstrap_image config option for building
opensuse chroots.

While we are on it, we won't be OK with turning the use_bootstrap_image
on by default for everyone and for every project. We will probably turn
it ON on mock-core-configs level (mock upstream) for opensuse
chroots only. This means that we need to change the checkbox from
two-state to three-state one in web-UI [2] and fix our commandline to
--use-bootstrap {on,off,default} (not just on/off).

Another thing is that we should be able to configure this on chroot
level, not on copr level. We don't have cli variant for configuring
chroot options, so we should add that while we are on it.

Todo items:
- [ ] three state configuration per project
- [ ] config per chroot, three state
- [ ] three-state config for bootstrap image

[1] https://github.com/rpm-software-management/mock/pull/509
[2] http://extremefe.github.io/bootstrap-checkbox/ three state checkbox


We should also drop the "experimental" description.

Metadata Update from @dturecek:
- Issue assigned to dturecek

3 years ago

I'm thinking about this once more, and I think that bootstrap image and
bootstrap chroot config options are somewhat exclusive (they overlap in
some situations).

Shouldn't we rather flip from binary "checkbox" (current state) into a text
field like Mock bootstrap configuration with possible values:

  1. default (equivalent to an empty field), this would mean that the
    default copr configuration (or rather mock-core-configs configuration) is
    used
  2. disabled (bootstrap chroot disabled)
  3. chroot (bootstrap chroot is used, installed by dnf)
  4. image (bootstrap chroot is initialized from image)
  5. image=custom_image_id (bootstrap chroot is initialized from the
    given image).

WDYT? It would be trivial to beat the per-project config by per-chroot, and
then per-build config (when needed).

I also think that we should transfer all the existing projects by alembic
migration to

1. some form of "disabled", if they have bootstrap OFF now
2. something like "chroot", if they have bootstrap ON now

And flip the default value to "default" (empty) for new projects.

Commandline cptions proposal for copr-cli edit-chroot:

--bootstrap on|off|(default)|image
--bootstrap-image <IMAGE_ID> (implies --bootstrap=ON)

Metadata Update from @praiskup:
- Issue assigned to praiskup (was: dturecek)

3 years ago

Login to comment on this ticket.

Metadata
Related Pull Requests
  • #1525 Merged 3 years ago
  • #1445 Closed 3 years ago