Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kola: Change --oscontainer to use new ostree native containers #3004

Merged
merged 1 commit into from
Jul 28, 2022

Conversation

cgwalters
Copy link
Member

Quite a while ago we added this special case code to kola
which learned how to do in-place updates to the weird bespoke
"ostree repo in container" OCP/RHCOS-specific container image.

A huge benefit of the change to use ostree-native containers
is that this approach can now be shared across FCOS/RHCOS.

(Also, rpm-ostree natively understands this, so it's much much
more efficient and less awkward than the wrappers we had in pivot around
rpm-ostree)

But the benefits get even larger: this issue:
#2685
proposes rethinking of our pipeline to more cleanly split up
"build OS update container" from "build disk images".

With this, it becomes extra convenient to do a flow of:

  • build OS update container, push to registry
  • kola run -p stable --oscontainer quay.io/fcos-devel/testos@sha256...

IOW we're not generating a disk image to test the OS update - we're
using the stable disk image and doing an in-place update before
we run tests.

Now...as of right now nothing in the pipeline passes this flag,
so the code won't be used (except for manual testing).

Suddenly with this, the number of tests we can run roughly doubles.
For example, we can run e.g.
kola run rpm-ostree both with and without --oscontainer.

In most cases, things should be the same. But, I think it will
be interesting to try to explictly use this for at least some tests;
it's almost a full generalization of the kola run-upgrades bits.

Quite a while ago we added this special case code to kola
which learned how to do in-place updates to the weird bespoke
"ostree repo in container" OCP/RHCOS-specific container image.

A huge benefit of the change to use ostree-native containers
is that this approach can now be shared across FCOS/RHCOS.

(Also, rpm-ostree natively understands this, so it's much much
 more efficient and less awkward than the wrappers we had in `pivot` around
 rpm-ostree)

But the benefits get even larger: this issue:
coreos#2685
proposes rethinking of our pipeline to more cleanly split up
"build OS update container" from "build disk images".

With this, it becomes extra convenient to do a flow of:

- build OS update container, push to registry
- `kola run -p stable --oscontainer quay.io/fcos-devel/testos@sha256...`

IOW we're not generating a disk image to test the OS update - we're
using the *stable* disk image and doing an in-place update before
we run tests.

Now...as of right now nothing in the pipeline passes this flag,
so the code won't be used (except for manual testing).

Suddenly with this, the number of tests we can run roughly *doubles*.
For example, we can run e.g.
`kola run rpm-ostree` both with and without `--oscontainer`.

In most cases, things should be the same.  But, I think it will
be interesting to try to explictly use this for at least some tests;
it's almost a full generalization of the `kola run-upgrades` bits.
@cgwalters
Copy link
Member Author

Here's a new flow possible:

$ git clone https://github.com/coreos/coreos-layering-examples
$ cd coreos-layering-examples/tailscale
$ podman build -t localhost/fcos-tailscale .
$ podman push localhost/fcos-tailscale quay.io/myuser/fcos-tailscale
$ kola run -p aws --oscontainer ostree-unverified-registry:quay.io/myuser/fcos-tailscale <some tests>

IOW - build as a container, natively using container tools (no coreos-assembler involved) and test the resulting container in AWS (or on any of our platforms) using any of our existing tests.

Copy link
Member

@gursewak1997 gursewak1997 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Contributor

@prestist prestist left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minus my question above. LGTM

@cgwalters cgwalters merged commit ab2f64f into coreos:main Jul 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants