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

rollup issue for experimental-image-proxy #1482

Closed
cgwalters opened this issue Oct 14, 2021 · 6 comments
Closed

rollup issue for experimental-image-proxy #1482

cgwalters opened this issue Oct 14, 2021 · 6 comments

Comments

@cgwalters
Copy link
Contributor

cgwalters commented Oct 14, 2021

#1476 merged, but there's more we can/should do as followup.

  • Add CI to skopeo that exercises it. I've been testing via the unit tests in https://github.com/ostreedev/ostree-rs-ext/ - we could wire that up as "reverse dependency testing". Or, maybe it wouldn't be hard to write a simple client in e.g. Python and just run it directly here?
  • Validate that e.g. signed images work correctly
  • Add support for privilege dropping (in particular I'd like to avoid running the proxy as real root/CAP_SYS_ADMIN when used for host OS updates with ostree); we'd need to do something like open e.g. ~/.docker/config.json or equivalent privileged, then re-exec? Or maybe just have the caller open the required creds, pass them via fd and use --authfile /proc/self/fd/X or so)
  • Add an API that fetches the config object too?
  • It turns out that in order to fetch from containers-storage: we may need the config so we can use the diffids
@lsm5
Copy link
Member

lsm5 commented Oct 18, 2021

@cevich @edsantiago PTAL RE: ci ^

@cevich
Copy link
Member

cevich commented Oct 18, 2021

Add CI to skopeo that exercises it.

I'm always in favor of more testing 😁

I've been testing via the unit tests in https://github.com/ostreedev/ostree-rs-ext/ - we could wire that up as "reverse dependency testing".

Though my general opinion is against reverse-dependency testing, since they can be a PITA to maintain. However, if it makes sense and you go this route, it should run as a separate Cirrus-CI task (i.e. not test_skopeo_task) - since (surprise!) this test is also used in reverse-dependency testing for containers/image - in other words, that would hurt my brain 😁

Or, maybe it wouldn't be hard to write a simple client in e.g. Python and just run it directly here? Validate that e.g. signed images work correctly

Python3 is available in these environments. If it can be a simple client, this would be easier to incorporate into test_skopeo_task - meaning you get testing under containers/image for "free" (minus the brain-hurt).

Add support for privilege dropping (in particular I'd like to avoid running the proxy as real root/CAP_SYS_ADMIN when used for host OS updates with ostree); we'd need to do something like open e.g. ~/.docker/config.json or equivalent privileged, then re-exec? Or maybe just have the caller open the required creds, pass them via fd and use --authfile /proc/self/fd/X or so)

There is an existing setup in podman's CI for creating a test-user, and re-exec'ing the tests via ssh It's a bit more convoluted than privilege dropping, runuser, or su, but lets the tests run from a real login-shell environment. This may be important, since it's closer to what real-users will experience.

Add an API that fetches the config object too? It turns out that in order to fetch from containers-storage: we may need the config so we can use the diffids

I'm not sure what this means. However it may be worth getting some sort of basic testing in place before worrying about additional features (which need more tests).

@github-actions
Copy link

A friendly reminder that this issue had no activity for 30 days.

@rhatdan
Copy link
Member

rhatdan commented Nov 18, 2021

@cgwalters @cevich @mtrmac What is going on with this issue?

@cevich
Copy link
Member

cevich commented Nov 18, 2021

I'm in favor of the "simple python client" idea, testing here, and getting "for free" testing in containers/image. I'm not in favor of doing the test-writing work myself 😁 (though I'm willing to help with the automation part, as always).

@cgwalters
Copy link
Contributor Author

#1495
already did some of this, but not all.

I think we definitely need testing for signed images, but...dunno. Closing this for now, I will track signed image bits over in ostreedev/ostree-rs-ext#163

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 18, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants