tilt-dev / tilt-extensions

Extensions for Tilt
https://tilt.dev/
Apache License 2.0
200 stars 156 forks source link

Podman: add restart function #556

Closed ianb-mp closed 6 months ago

ianb-mp commented 6 months ago

Add podman_build_with_restart() function to Podman extension.

@nicks fyi

arlyon commented 5 months ago

This seems to invoke docker still, no?

https://github.com/tilt-dev/tilt-extensions/blob/master/restart_process/Tiltfile

Should I open an issue?

ianb-mp commented 5 months ago

@arlyon I'm not sure what you mean by 'invoke docker'. Can you provide more detail? This PR passes a command parameter here which explicitly uses podman.

arlyon commented 5 months ago

Sure. podman_build_with_restart will unconditionally call into docker to build the image that hosts the tilt-restart-wrapper. The call graph is as follows:

ianb-mp commented 5 months ago

Ah I see what you mean. TBH I don't understand the internals of tilt and the multiple stages. I do know that podman_build_with_restart is working for me in an environment where everything outside the k8s cluster is Podman only. Is the later docker_build happening inside a container? And if so, would it matter if it's docker and not Podman?

nicks commented 5 months ago

@arlyon Tilt communicates with docker over the unix socket / REST API. Podman claims to offer REST API compatibility, so should work fine if you have the environment set up correctly. if it's not working for you, please open an issue with repro steps.

arlyon commented 4 months ago

Apologies for the late reply. I don't have podman running in daemon mode (it is daemonless by default) but it is possible and can be an ok workaround for now. I will open an issue with a repro when I get back to this project. Thanks for all the amazing work you guys are doing! 💞