dev_scripts: Ditch sudo requirement for Docker

We don't tend to use Docker for development tasks in Linux, since we
have Podman for that. In MacOS and Windows, we do use Docker, but
typically without sudo.

Make our MacOS / Windows dev tasks non-interactive, by ditching the
`sudo` invocation.

Closes #519
This commit is contained in:
Alex Pyrgiotis 2023-08-17 15:15:30 +03:00
parent e512ba2b6a
commit 098e532bd2
No known key found for this signature in database
GPG key ID: B6C15EBA0357C9AA

View file

@ -261,11 +261,8 @@ class Env:
self.version = "bullseye-backports" self.version = "bullseye-backports"
# Try to autodetect the runtime, if the user has not provided it. # Try to autodetect the runtime, if the user has not provided it.
#
# FIXME: Typically Podman runs without sudo, whereas Docker with sudo, but this
# is not always the case. We may need to autodetect that as well.
podman_cmd = ["podman"] podman_cmd = ["podman"]
docker_cmd = ["sudo", "docker"] docker_cmd = ["docker"]
if not runtime: if not runtime:
if shutil.which("podman"): if shutil.which("podman"):
self.runtime = "podman" self.runtime = "podman"