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

[BUG] GUI mode cannot bind X11 socket using Orbstack #144

Closed
nheuillet opened this issue Mar 1, 2023 · 1 comment
Closed

[BUG] GUI mode cannot bind X11 socket using Orbstack #144

nheuillet opened this issue Mar 1, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@nheuillet
Copy link
Member

Describe the bug

Trying to create a container with all default values (GUI on being the one I'm interested in), I get this error:

invalid mount config for type "bind": bind source path does not exist: /tmp/.X11-unix

I'm using Orbstack as my docker runtime. This should not however change anything to behavior. In fact, I'm able to use GUI app using xQuartz by creating a simple container by hand using this command:

docker run -it --env="DISPLAY=host.docker.internal:0" -v /tmp/.X11-unix:/tmp/.X11-unix:rw ubuntu

Steps To Reproduce

  • Use Orbstack as the docker runtime
  • Start a new container using GUI on

Exegol Wrapper Version

[*] Exegol is currently in version v4.1.1
[*] Exegol Discord serv.: https://discord.gg/cXThyp7D6P
[*] Exegol documentation: https://exegol.rtfd.io/
[+] We thank Capgemini for supporting the project (helping with dev) 🙏
[+] We thank HackTheBox for sponsoring the multi-arch support 💚
[D] Pip installation: On ✔
[D] Git source installation: Off 🪓
[D] Host OS: Linux
[D] Arch: amd64
[D] Raw arch: x86_64
[D] Docker desktop: Off 🪓
[D] Shell type: Mac
[D] Last update check: 01/03/2023

Host OS

MacOS

Configuration of the concerned container

No response

Execution logs in debug mode

[*] Exegol is currently in version v4.1.1
[*] Exegol Discord serv.: https://discord.gg/cXThyp7D6P
[*] Exegol documentation: https://exegol.rtfd.io/
[+] We thank Capgemini for supporting the project (helping with dev) 🙏
[+] We thank HackTheBox for sponsoring the multi-arch support 💚
[D] Pip installation: On ✔
[D] Git source installation: Off 🪓
[D] Host OS: Linux
[D] Arch: amd64
[D] Raw arch: x86_64
[D] Docker desktop: Off 🪓
[D] Shell type: Mac
[D] Last update check: 01/03/2023

[*] Starting exegol
[D] Attribute not found in parameters: multicontainertag
[!] No containers have been created yet
[V] Configuring new exegol container
[D] Attribute not found in parameters: multiimagetag
[D] Fetching remote image tags, digests and sizes
[D] Fetching information from: https://hub.docker.com/v2/repositories/nwodtuhs/exegol/tags?page_size=20
[D] Fetching information from: https://hub.docker.com/v2/repositories/nwodtuhs/exegol/tags?page=2&page_size=20
[D] Max page limit reached. In non-verbose mode, downloads will stop there.
[D] Fetching information from: https://hub.docker.com/v2/repositories/nwodtuhs/exegol/tags?page=3&page_size=20
[D] Fetching local image tags, digests (and other attributes)
[D] └── light   → (remote) sha256:7f4cf4a55f34cc2419b57c8b4286be4e5a053316ecce2e23cce5f17a38590571
[D] └── nightly → (remote) sha256:230a9ae3759cc3899dba22a6ec13367d48758752403aeb7906f3b38a31e4e6f6
[D] └── osint   → (remote) sha256:6792268d4ffd890010482584becd8b04666025b71766b0fea76ed355d6b14c4c
[D] └── web     → (remote) sha256:901640f976728b005c1291fc791db173583be4ce77e06c656fcc9ca1d90b9f78
[D] └── full    → (remote) sha256:b595b71adbf4f0edc32a388f87771de377d82e059e0f9459fb62b49eb938b5cd
[D] └── full    → (remote) sha256:b595b71adbf4f0edc32a388f87771de377d82e059e0f9459fb62b49eb938b5cd
[D] └── ad      → (remote) sha256:4fc6a3d2d28929f13fb74ff4e9258f51daa8986a0603aaa37ad109bacc7f9381
[D] └── light-3.0.0     → (remote) sha256:2fe0e78dcf1924785bffeb20b52ecde82609f9c91c0fad883bb293dd65d7443d
[D] └── osint-3.0.0     → (remote) sha256:13b3d0f9d9946b0105c997260f84a5b3ea0e35d1b1da974a033def9375c109ea
[D] └── web-3.0.0       → (remote) sha256:fe361319498cdbf0c62688fc675902a54dc12ceff164ef193789d67d1140d970
[D] └── web-3.0.0       → (remote) sha256:fe361319498cdbf0c62688fc675902a54dc12ceff164ef193789d67d1140d970
[D] └── ad-3.0.0        → (remote) sha256:a174289246c5ce40227a52caf4d82faf81420c915791caad6bbf85c7d02cd5c9
[D] └── full-3.0.0      → (remote) sha256:6751cd3bf83461623a9bfab29c36edfef8b5d4e9b80c11015cf53a0061099dce
[D] └── full-3.0.0      → (remote) sha256:6751cd3bf83461623a9bfab29c36edfef8b5d4e9b80c11015cf53a0061099dce
[D] └── full-2.1.1      → (remote) sha256:c19d64e74f346999991a82a740acb392bf0da6c2fbb680c2403250f2bba31cfc
[D] └── ad-2.1.1        → (remote) sha256:b2b9a7642cd765daae0e0e517544cb4f5b0b77f8149f19165479fceb92f14f84
[D] └── web-2.1.1       → (remote) sha256:6ce49800b576f2f97d665e63ab0cb4fb946cf3d575b5918887e93887afe3c2d8
[D] └── light-2.1.1     → (remote) sha256:c048d0ebe19613e01e65d27013c5174fb41cccbe2fd9f8cde9cbb2a56b919371
[D] └── osint-2.1.1     → (remote) sha256:ffe3c2d9693b0b52d11d9104dd2a33f2cf2037b412249db340d59d7ee01497fa
[D] └── full-2.1.0      → (remote) sha256:2462e5169f04b72123ab28d34ae7b326d40240097bcebe65bc968ade06c36a9c
[D] └── full-2.1.0      → (remote) sha256:2462e5169f04b72123ab28d34ae7b326d40240097bcebe65bc968ade06c36a9c
[D] └── ad-2.1.0        → (remote) sha256:eda497aebe8e35d685be9057793606c297548519dd16526b302d50a8f959179d
[D] └── web-2.1.0       → (remote) sha256:4520239532ce14afdfb87e4fcd9633096b90a3e8a28d8b02044e628c53cfb17f
[D] └── light-2.1.0     → (remote) sha256:ffa088736d8a3e2bab9cf3e3ae2b816d779e2a6a984ed41012ef989e3524e8b3
[D] └── osint-2.1.0     → (remote) sha256:f706f54024324899836f7568aeda8608dacd93a98d7114cd5f5b3fd093beba08
[D] └── full-2.0.2      → (remote) N/A
[D] └── light-2.0.2     → (remote) N/A
[D] └── ad-2.0.2        → (remote) N/A
[D] └── web-2.0.2       → (remote) N/A
[D] └── osint-2.0.2     → (remote) N/A
[D] └── full-2.0.1      → (remote) N/A
[D] └── ad-2.0.1        → (remote) N/A
[D] └── web-2.0.1       → (remote) N/A
[D] └── light-2.0.1     → (remote) N/A
[D] └── osint-2.0.1     → (remote) N/A
[D] └── web-2.0.0       → (remote) N/A
[D] └── light-2.0.0     → (remote) N/A
[D] └── osint-2.0.0     → (remote) N/A
[D] └── full-2.0.0b5    → (remote) N/A
[D] └── ad-2.0.0b5      → (remote) N/A
[D] └── web-2.0.0b5     → (remote) N/A
[D] └── light-2.0.0b5   → (remote) N/A
[D] └── osint-2.0.0b5   → (remote) N/A

🛸 Available images
┌───────────────┬─────────────────┬───────────────┬──────────────┬──────────────────┬──────────────────────┐
│ Id            │ Image tag       │ Download size │ Size on disk │ Build date (UTC) │ Status               │
├───────────────┼─────────────────┼───────────────┼──────────────┼──────────────────┼──────────────────────┤
│ 10ff1a5f247f  │ light (amd64)   │ 4.7GB         │ 11.2GB       │ 24/02/2023 21:07 │ Up to date (v.3.0.1) │
│ Not installed │ nightly (amd64) │ 12.7GB        │ N/A          │ N/A              │ Not installed        │
│ Not installed │ osint (amd64)   │ 3.4GB         │ N/A          │ N/A              │ Not installed        │
│ Not installed │ web (amd64)     │ 6.7GB         │ N/A          │ N/A              │ Not installed        │
│ Not installed │ full (amd64)    │ 12.7GB        │ N/A          │ N/A              │ Not installed        │
│ Not installed │ ad (amd64)      │ 9.1GB         │ N/A          │ N/A              │ Not installed        │
└───────────────┴─────────────────┴───────────────┴──────────────┴──────────────────┴──────────────────────┘
[*] You can use a name that does not already exist to build a new image from local sources
[?] Select an image by its name (light):
[V] Config: Enabling display sharing
[V] Config: Enabling host timezones
[V] File /etc/timezone is missing on host, cannot create volume for this.
[V] Volume was successfully added for /etc/localtime
[V] Config: Enabling my-resources volume
[V] Updating the permissions of /Users/noe/.exegol/my-resources (and sub-folders) to allow file sharing between the container and the host user
[D] Adding setgid permission recursively on directories from /Users/noe/.exegol/my-resources
[D] Loading git at /Users/noe/.exegol/exegol-resources
[D] Repo path: /Users/noe/.exegol/exegol-resources/.git
[D] Git repository successfully loaded
[V] Config: Enabling exegol resources volume
[?] Enter the name of your new exegol container (default):
⭐ Container summary
┌──────────────────┬─────────────────────────────────────────────────────────────────┐
│             Name │ default                                                         │
│            Image │ light - v.3.0.1 (Up to date) (amd64)                            │
├──────────────────┼─────────────────────────────────────────────────────────────────┤
│              GUI │ On ✔                                                            │
│          Network │ host                                                            │
│         Timezone │ On ✔                                                            │
│ Exegol resources │ On ✔ (/opt/resources)                                           │
│     My resources │ On ✔ (/opt/my-resources)                                        │
│    Shell logging │ Off 🪓                                                          │
│       Privileged │ Off ✔                                                           │
│        Workspace │ Dedicated (/workspace)                                          │
│             Envs │ DISPLAY=/private/tmp/com.apple.launchd.pcWxMO8udo/org.xquartz:0 │
│                  │ _JAVA_AWT_WM_NONREPARENTING=1                                   │
│                  │ QT_X11_NO_MITSHM=1                                              │
│          Volumes │ /tmp/.X11-unix ➡ /tmp/.X11-unix                                 │
│                  │ /etc/localtime ➡ /etc/localtime (RO)                            │
│                  │ /Users/noe/.exegol/my-resources ➡ /opt/my-resources             │
│                  │ /Users/noe/.exegol/exegol-resources ➡ /opt/resources            │
└──────────────────┴─────────────────────────────────────────────────────────────────┘

[?] Is the container configuration correct? [Y/n]:
[*] Command line of the configuration: exegol start default light
[*] To use exegol without interaction, read CLI options with exegol start -h
[*] Creating new exegol container
[V] Updating the permissions of /Users/noe/.exegol/workspaces/default (and sub-folders) to allow file sharing between the container and the host user
[D] Adding setgid permission recursively on directories from /Users/noe/.exegol/workspaces/default
[D] default - light
Privileged: False
Capabilities: []
Sysctls: {}
X: True
TTY: True
Network host: host
Ports: {}
Share timezone: True
Common resources: True
Envs (3): {'DISPLAY': '/private/tmp/com.apple.launchd.pcWxMO8udo/org.xquartz:0', '_JAVA_AWT_WM_NONREPARENTING': '1', 'QT_X11_NO_MITSHM': '1'}
Labels (0): {}
Shares (5): [{'Target': '/tmp/.X11-unix', 'Source': '/tmp/.X11-unix', 'Type': 'bind', 'ReadOnly': False}, {'Target': '/etc/localtime', 'Source': '/etc/localtime', 'Type': 'bind',
'ReadOnly': True}, {'Target': '/opt/my-resources', 'Source': '/Users/noe/.exegol/my-resources', 'Type': 'bind', 'ReadOnly': False}, {'Target': '/opt/resources', 'Source':
'/Users/noe/.exegol/exegol-resources', 'Type': 'bind', 'ReadOnly': False}, {'Target': '/workspace', 'Source': '/Users/noe/.exegol/workspaces/default', 'Type': 'bind', 'ReadOnly':
False}]
Devices (0): []
VPN: N/A
[D] Entrypoint: ['/.exegol/entrypoint.sh']
[D] Cmd: ['default']
[-] invalid mount config for type "bind": bind source path does not exist: /tmp/.X11-unix
[D] 400 Client Error for http+docker://localhost/v1.42/containers/create?name=exegol-default: Bad Request ("invalid mount config for type "bind": bind source path does not exist:
/tmp/.X11-unix")
[!] Error while creating exegol container. Exiting.

Exception

No response

Anything else?

No response

@nheuillet nheuillet added the bug Something isn't working label Mar 1, 2023
@Dramelac
Copy link
Member

Dramelac commented Mar 8, 2023

After investigation it seems that orbstack does not support the mount format (recommended).

PoC (working on Linux):
docker run --rm --name tmp -it --mount 'type=bind,src=/tmp/.X11-unix,dst=/tmp/.X11-unix' debian bash

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants