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

Ubuntu ephemeral container creation fails at first run #117

Open
pid42 opened this issue Aug 25, 2024 · 3 comments
Open

Ubuntu ephemeral container creation fails at first run #117

pid42 opened this issue Aug 25, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@pid42
Copy link

pid42 commented Aug 25, 2024

Describe the bug

When I press Ctrl + U for the first time , it will create an ephemeral ubuntu-lts container.
But, the first time this command runs, it prints the following error:

/bin/sh: 2: /etc/profile.d/brew.sh: [[: not found

And drops to a /bin/sh prompt. When we close and press Ctrl+U again, it will open the terminal inside the ubuntu container as expected, now running bash, which means that the container was created, but the profile setup can be incomplete.

The problem here seems to be that /etc/profile.d/brew.sh is using "[[" , but ubuntu is trying to run that using its /bin/sh (which , if I do remember right, is dash and does not support [[ ).

What did you expect to happen?

The ubuntu container was sucessfuly created without errors and a terminal opened inside it.

Output of rpm-ostree status

State: idle
AutomaticUpdates: stage; rpm-ostreed-automatic.timer: last run 59min ago
Deployments:
● ostree-image-signed:docker://ghcr.io/ublue-os/bluefin-dx:stable
                   Digest: sha256:a0390ce9c85a06e83522d204c54dc4860b350b116934c511e929fd6ec7187feb
                  Version: 40.20240820.0 (2024-08-20T05:53:19Z)

  ostree-image-signed:docker://ghcr.io/ublue-os/bluefin-dx:gts
                   Digest: sha256:9e08ff20deea7d2f8b07e62cfc206043e7535065110dad02f4e11a613ae6bf5d
                  Version: 39.20240824.0 (2024-08-25T05:52:38Z)

Output of groups

fdr wheel docker

Extra information or context

No response

@pid42
Copy link
Author

pid42 commented Aug 25, 2024

Screenshot from 2024-08-25 16-37-17

@dosubot dosubot bot added the bug Something isn't working label Aug 25, 2024
@castrojo castrojo transferred this issue from ublue-os/bluefin Aug 26, 2024
@castrojo
Copy link
Member

Great catch! Pretty sure this goes in this repo, we'll see what the others think, thanks!

@djmason
Copy link

djmason commented Oct 24, 2024

I've encountered this as well, and I noticed that running /bin/sh on the first run happens not only in the ubuntu-toolbox but also in the fedora-toolbox. The shell syntax error only happens in the ubuntu-toolbox because /bin/sh is a symlink to dash, but in the fedora-toolbox /bin/sh is a link to bash, so it supports the extended syntax. In both cases you end up in a /bin/sh terminal the first time, but it changes to bash in subsequent windows.

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

3 participants