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

[Cloud] sh: 1: Bad substitution error when using docker as runtime environment #3554

Open
novahow opened this issue May 15, 2024 · 0 comments

Comments

@novahow
Copy link

novahow commented May 15, 2024

when I use my docker image as runtime, the setup fails with

I 05-15 21:00:14 provisioner.py:76] Launching on GCP us-central1 (us-central1-a)
I 05-15 21:00:30 provisioner.py:458] Successfully provisioned or found existing instance.
I 05-15 21:01:45 provisioner.py:560] Successfully provisioned cluster: gcp0
I 05-15 21:01:45 cloud_vm_ray_backend.py:3213] Running setup on 1 node.
> /mnt/d/ebook/FlyteDev/skyTest/skypilot/sky/backends/cloud_vm_ray_backend.py(3176)_setup_node()
-> returncode = runner.run(
(Pdb) c
Warning: Permanently added '34.70.197.193' (ED25519) to the list of known hosts.
Warning: Permanently added '[localhost]:10022' (ED25519) to the list of known hosts.
bash: no job control in this shell
bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
total 12
drwxr-xr-x 2 flytekit flytekit 4096 May 15 11:30 .
drwxr-xr-x 1 flytekit flytekit 4096 May 15 13:01 ..
sh: 1: Bad substitution
setuped
Clusters
NAME  LAUNCHED    RESOURCES                                                                  STATUS  AUTOSTOP  COMMAND                       
gcp0  3 mins ago  1x GCP(e2-small, image_id={'us-central1': 'docker:flytesky/plugins:sky...  UP      -         sky launch -c gcp0 hello_...  

sky.exceptions.CommandError: Command /bin/bash -i /tmp/sky_setup_sky-2024-05-15-21-00-04-823032 2>&1 failed with return code 2.
Failed to setup with return code 2. Check the details in log: ~/sky_logs/sky-2024-05-15-21-00-04-823032/setup-34.70.197.193-22.log

****** START Last lines of setup output ******
bash: no job control in this shell
bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
total 12
drwxr-xr-x 2 flytekit flytekit 4096 May 15 11:30 .
drwxr-xr-x 1 flytekit flytekit 4096 May 15 13:01 ..
setuped
******* END Last lines of setup output *******

I believe the cause was

source_bashrc=True,
, since when I deleted the source_bashrc=True statement, my setup worked fine. the task fails especially when my docker image uses /bin/sh by default, which can't get ${PIPESTATUS[0]}

Version & Commit info:

  • sky -v: PLEASE_FILL_IN
  • sky -c: PLEASE_FILL_IN
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant