Commit Graph
281 Commits
Author SHA1 Message Date
Fred Fu 892f93baaa fix: flags for read-only and recursive slave mount (#2086)
closes #2083
2026-05-04 11:10:30 +02:00
Alessio Biancalana 40c3cd724f chore: bump to v1.8.2.5 (#2072) 2026-04-27 14:25:31 +02:00
Eric Curtin 4e3dbe5b9a all: add Docker Desktop on macOS compatibility (#2019)
On macOS, Docker Desktop mounts all paths as private (rprivate) in its
Linux VM via VirtioFS, so rslave/rshared bind propagation is rejected.
Strip these propagation options from the generated docker create command
when running on Darwin.

Also fix a bug in distrobox-init where the socket path prefix stripping
used `sed 's|/run/host||g'` with the global flag, causing paths like
`/run/host/run/host-services/ssh-auth.sock` (a Docker Desktop socket)
to be mangled into `-services/ssh-auth.sock`. The leading `-` was then
parsed as a flag by `rm`, crashing the init script. Replace with shell
parameter expansion `${host_socket#/run/host}` which strips the prefix
exactly once.

distrobox-init detects "rootful" mode by checking if /run/host/etc/shadow
is accessible and owned by root. On macOS with Docker Desktop, all containers
run as root inside the Linux VM, so this check always succeeds even for
containers created without --root, causing a spurious first-shell password
prompt.

Fix this by having distrobox-create mount /dev/null:/run/.distrobox.rootless:ro
for every rootless container. distrobox-init now checks for this marker first
and skips the shadow heuristic when it is present.

This is backward-compatible: existing containers without the marker continue
to use the shadow-file heuristic as before.

Signed-off-by: Eric Curtin <eric.curtin@docker.com>
2026-03-19 11:53:26 +01:00
Alessio Biancalana 08e4963711 chore(version): bump to v1.8.2.4 (#1995) 2026-02-04 16:47:39 +01:00
Alessio Biancalana 35b3f2175c chore(version): bump to 1.8.2.3 (#1969) 2026-01-17 08:43:24 +01:00
Alessio Biancalana a7b2437dbe chore(version): bump to 1.8.2.2 (#1921) 2025-11-26 15:40:31 +01:00
Alessio BiancalanaandMichał Jastrzębski a04862f1bd create: direct stderr to /dev/null to prevent incorrect eval (#1920)
Co-authored-by: Michał Jastrzębski <inc007@gmail.com>
2025-11-26 15:21:42 +01:00
Brandon Sutherland d29adf44b8 create: fix failing to create containers from images that print to stdout with no input (#1912)
When podman runs a container that prints stdout with no input, this is
appended to the return of the generate_create_command  output, resulting
in an invalid command
2025-11-22 09:45:57 +01:00
Alessio Biancalana cdb90f26fa chore: bump version to 1.8.2.1 (#1872) 2025-11-06 09:17:11 +01:00
Luca Di Maio 216ea8b257 all: bump release 1.8.2.0
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2025-10-28 10:11:14 +01:00
Alessio Biancalana 40c4317cae create: fix formatting and quoting issues (#1862)
* create: fix formatting and quoting issues

* create: fix spacing
2025-10-23 12:53:08 +02:00
Jookia 3f15ed59ab create: support --userns=keep-id:size= (#1667)
Currently distrobox will reserve all subuids/subgids available.
This has the unfortunate effect of blocking other containers from running
that require their own set of subuids/subgids.

podman has added a feature that lets us restrict the amount of
subuids/subgids we request. If available, set the amount to 65536 which
is the standard amount needed for a typical Linux single container.

Disable this by setting DBX_USERNS_NOLIMIT=1.

Signed-off-by: Jookia <contact@jookia.org>
2025-10-23 12:28:11 +02:00
Apolloandapollo7321 d753b355a6 fix: indentation for --root usage in distrobox-create (#1846)
Co-authored-by: apollo7321 <apollo7321@users.noreply.github.com>
2025-09-28 11:25:15 +02:00
Apolloandapollo7321 d3a3a7b747 chore: clarify --root documentation for distrobox-create (#1845)
Co-authored-by: apollo7321 <apollo7321@noreply.codeberg.org>
2025-09-28 10:45:40 +02:00
Luca Di Maio 71cf8295fb create: explicitly prefer using crun if present
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2025-05-27 17:10:11 +02:00
Luca Di Maio 3b9f0e8d3d all: bump release 1.8.1.2
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2025-01-25 15:18:14 +01:00
Luca Di Maio 479d4f7166 all: bump release 1.8.1.1
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2025-01-23 09:04:13 +01:00
Luca Di Maio afb3b07098 fix linting
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2025-01-19 16:39:30 +01:00
Luca Di Maio 589ad7ebf3 create: properly handle platform specification for alien architectures. Fix #1644
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2025-01-19 16:06:13 +01:00
Luca Di Maio 3bac964bf0 create: better check clone support
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-12-14 17:34:34 +01:00
Luca Di Maio 5ad75a07d1 all: bump release 1.8.0
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-10-12 15:39:16 +02:00
Luca Di Maio 177a035b84 create: ignore trailing slashes on custom homes, Fix #1575
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-10-12 13:02:43 +02:00
jarred wilson 2fcdd6e816 fix:[#1525] handle container creation failure (#1526)
print error message and exit with subprocess return code
2024-10-12 12:08:15 +02:00
Luca Di Maio 175910fbc2 create: better explain init/pre-init hooks
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-06-29 13:42:43 +02:00
Luca Di Maio 20323d3fb1 all: use registry.fedoraproject.org/fedora-toolbox:latest image by default, Fix #1402
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-06-20 11:54:32 +02:00
Luca Di Maio 9b608a0688 all: ensure env variables are set and have values
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-09 16:11:51 +02:00
Luca Di Maio a4708b1117 all: set version 1.7.2.1 for release
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-06 08:38:39 +02:00
Luca Di Maio 7306a14728 all: bump version to 1.7.3.0 for future release
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-02 09:07:12 +02:00
Luca Di Maio 25ced537c1 all: update formatting style
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-02 09:07:01 +02:00
Luca Di Maio 772e86b161 all: bump version to 1.7.2.0
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-01 18:54:43 +02:00
Luca Di Maio 8753d5e903 all: improve function docs
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-01 18:09:55 +02:00
Luca Di Maio d626559baa init, create: use $CONTAINER_ID to distinguish container's prompts.
Use host's hostname by default.

This will fix issues with apps not matching StartupWMClass, and other
pesky bugs.

Fix #62
Fix #728
Fix #994
Fix #1306

Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-01 12:40:27 +02:00
Luca Di Maio f031b8e817 create: fix regression with rootless runc 1.20~rc1, Fix #1359
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-01 12:40:26 +02:00
XarvexandLuca Di Maio c8fcb12865 all: properly handle env vars and configs in all commands (#1328)
* all: process unhandled DBX_NON_INTERACTIVE and DBX_VERBOSE env vars
DBX_NON_INTERACTIVE was added in 7203563, but has not been added to new
files since then.
DBX_VERBOSE was added in 78b3319, but was not handled in all files that
use verbose as an option.

* all: modify optional env var header to reflect script implementation

* all: fix configs not being parsed/handled in all commands

* all: general code organization for consistency/readability

* fix: revert changes for in-container commands

Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>

---------

Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
Co-authored-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-05-01 11:58:31 +02:00
Luca Di Maio 867f4f85c7 all: bump version to 1.7.1
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-03-25 20:02:51 +01:00
Luca Di Maio c7f24abcb0 all: improve functions' documentation
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-03-25 19:51:37 +01:00
Luca Di Maio f26a01cff1 all: bump release to 1.7.0.1
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-03-11 19:35:36 +01:00
Luca Di Maio 7ef5cfeb1e all: bump release 1.7.0
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-28 19:25:44 +01:00
Luca Di Maio 78b3319d6f all: add DBX_VERBOSE env variable. Fix #1151
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-19 18:20:15 +01:00
Sandorex d26a926ff7 create: add --hostname argument and DBX_CONTAINER_HOSTNAME env var (#1214)
* Add --hostname argument and DBX_CONTAINER_HOSTNAME env var

* Update usage/distrobox-create.md and useful_tips.md

* Refining error message when hostname is too long
2024-02-18 18:08:36 +01:00
Luca Di Maio b58202f649 create: fix home-prefix not correctly detected, deduplicate code. Fix #1212
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-16 18:06:24 +01:00
Luca Di Maio d409ce4d5b create/enter: add unshare-groups flag, do proper su login only on usnhare-groups and initful containers. Fix #1208
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-16 00:02:33 +01:00
Luca Di Maio 0f4f3ea6ad enter: properly allocate pty container an do a proper login shell for the user, Fix #1150
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-15 17:57:58 +01:00
Sandorex 0f124f328f create: add host terminfo as a fallback (#1194)
* Add host terminfo separately and add it as fallback

This should allow the user to use a modern terminal without installing anything
additional inside the container itself

* Remove unecessary volume mount
2024-02-15 17:56:42 +01:00
Luca Di Maio e9bf2663dd fix linting
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-03 17:14:47 +01:00
Luca Di Maio 54cfcbe851 create: add pid-limits=-1 to create, Fix #1183
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-03 16:57:03 +01:00
Luca Di Maio 98cf591211 all: fix config loading when file doesn't exist
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-03 10:45:51 +01:00
Luca Di Maio dddefedf33 create: check RHEL subscription files before mounting, Fix #1146
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-01 23:33:34 +01:00
Luca Di Maio 6e9b2a8310 fix linting
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
2024-02-01 23:07:18 +01:00
Philipp Schmitt 9d6ad16cc7 all: Allow NixOS package maintainers to ship a static config file (#1080) 2024-02-01 22:55:03 +01:00