Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sky/utils/command_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -1042,12 +1042,12 @@ def run(

if ssh_mode == SshMode.LOGIN:
assert isinstance(cmd, list), 'cmd must be a list for login mode.'
base_cmd = ['kubectl', 'exec', '-it', *kubectl_args, '--']
base_cmd = ['kubectl', 'exec', '--v=9', '-it', *kubectl_args, '--']
command = base_cmd + cmd
proc = subprocess_utils.run(command, shell=False, check=False)
return proc.returncode, '', ''

kubectl_base_command = ['kubectl', 'exec']
kubectl_base_command = ['kubectl', 'exec', '--v=9']

if ssh_mode == SshMode.INTERACTIVE:
kubectl_base_command.append('-i')
Expand Down
11 changes: 2 additions & 9 deletions tests/smoke_tests/test_cluster_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -1073,7 +1073,7 @@ def test_volume_env_mount_kubernetes():
def _check_container_logs(name, logs, total_lines, count):
"""Check if the container logs contain the expected number of logging lines.

Each line should be only one number in the given range and should show up
Each line should be only one number in the given range and should show up
count number of times. We skip the messages that we see in the job from
running setup with set -x.
"""
Expand Down Expand Up @@ -1965,17 +1965,10 @@ def test_long_setup_run_script(generic_cloud: str):
test = smoke_tests_utils.Test(
'long-setup-run-script',
[
f'sky launch -y -c {name} --infra {generic_cloud} {smoke_tests_utils.LOW_RESOURCE_ARG} {f.name}',
f'sky exec {name} "echo hello"',
f'sky exec {name} {f.name}',
f'sky logs {name} --status 1',
f'sky logs {name} --status 2',
f'sky logs {name} --status 3',
f'sky down {name} -y',
f'sky jobs launch -y -n {name} --cloud {generic_cloud} {smoke_tests_utils.LOW_RESOURCE_ARG} {f.name}',
f'sky jobs queue | grep {name} | grep SUCCEEDED',
],
f'sky down -y {name}; sky jobs cancel -n {name} -y',
f'sky status -u; sky api status -a; sleep 600; sky jobs cancel -n {name} -y',
)
smoke_tests_utils.run_one_test(test)

Expand Down