From bf992ed3c96a69b2e075e3ed8052c67e05121ff5 Mon Sep 17 00:00:00 2001 From: Bui Dai Date: Fri, 9 Jan 2026 18:25:18 +0700 Subject: [PATCH 1/3] fix: remove gum color flag --- logging_utils.sh | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/logging_utils.sh b/logging_utils.sh index d15885d..8635eb0 100644 --- a/logging_utils.sh +++ b/logging_utils.sh @@ -101,32 +101,32 @@ show_success_banner() { if command -v gum &>/dev/null; then local header - header=$(gum style --foreground 212 --border double --border-foreground 212 --padding "1 2" --align center --width 60 "✅ Setup Complete!") + header=$(gum style --border double --padding "1 2" --align center --width 60 "✅ Setup Complete!") local message - message=$(gum style --foreground 255 --align center --width 60 "Your Kaggle instance is ready for remote access!") + message=$(gum style --align center --width 60 "Your Kaggle instance is ready for remote access!") local token_label - token_label=$(gum style --foreground 99 "📡 Zrok Share Token:") + token_label=$(gum style "📡 Zrok Share Token:") local token_value - token_value=$(gum style --foreground 212 --bold "$share_token") + token_value=$(gum style --bold "$share_token") local token_section token_section=$(gum join --vertical --align center "$token_label" "$token_value") local token_box - token_box=$(gum style --border rounded --padding "1 2" --border-foreground 99 --width 60 --align center "$token_section") + token_box=$(gum style --border rounded --padding "1 2" --width 60 --align center "$token_section") local instr_label - instr_label=$(gum style --foreground 255 "🖥️ On your LOCAL machine, run:") + instr_label=$(gum style "🖥️ On your LOCAL machine, run:") local cmd1 - cmd1=$(gum style --foreground 212 "zrok access private $share_token") + cmd1=$(gum style "zrok access private $share_token") local cmd2_label - cmd2_label=$(gum style --foreground 255 "Then connect via SSH:") + cmd2_label=$(gum style "Then connect via SSH:") local cmd2 - cmd2=$(gum style --foreground 212 "ssh -p 9191 root@127.0.0.1") + cmd2=$(gum style "ssh -p 9191 root@127.0.0.1") local cmds_content cmds_content=$(gum join --vertical --align center "$instr_label" " " "$cmd1" " " "$cmd2_label" " " "$cmd2") local cmds_box - cmds_box=$(gum style --border rounded --padding "1 2" --border-foreground 255 --width 60 --align center "$cmds_content") + cmds_box=$(gum style --border rounded --padding "1 2" --width 60 --align center "$cmds_content") printf "\n" gum join --vertical --align center "$header" " " "$message" " " "$token_box" " " "$cmds_box" From 8852fa01682681073e0bc4e3b010b951e329d95d Mon Sep 17 00:00:00 2001 From: Bui Dai Date: Fri, 9 Jan 2026 18:41:56 +0700 Subject: [PATCH 2/3] fix: clean up false ssh command in banner --- logging_utils.sh | 10 +--------- tests/unit/test_logging.bats | 1 - 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/logging_utils.sh b/logging_utils.sh index 8635eb0..242fa42 100644 --- a/logging_utils.sh +++ b/logging_utils.sh @@ -118,13 +118,9 @@ show_success_banner() { instr_label=$(gum style "🖥️ On your LOCAL machine, run:") local cmd1 cmd1=$(gum style "zrok access private $share_token") - local cmd2_label - cmd2_label=$(gum style "Then connect via SSH:") - local cmd2 - cmd2=$(gum style "ssh -p 9191 root@127.0.0.1") local cmds_content - cmds_content=$(gum join --vertical --align center "$instr_label" " " "$cmd1" " " "$cmd2_label" " " "$cmd2") + cmds_content=$(gum join --vertical --align center "$instr_label" " " "$cmd1") local cmds_box cmds_box=$(gum style --border rounded --padding "1 2" --width 60 --align center "$cmds_content") @@ -144,10 +140,6 @@ show_success_banner() { echo "║ ║" echo "║ zrok access private $share_token" echo "║ ║" - echo "║ Then connect via SSH: ║" - echo "║ ║" - echo "║ ssh -p 9191 root@127.0.0.1 ║" - echo "║ ║" echo "╚════════════════════════════════════════════════════════════════╝" echo "" fi diff --git a/tests/unit/test_logging.bats b/tests/unit/test_logging.bats index d3a0802..adef752 100644 --- a/tests/unit/test_logging.bats +++ b/tests/unit/test_logging.bats @@ -119,7 +119,6 @@ teardown() { [[ "$output" == *"✅ Setup Complete!"* ]] [[ "$output" == *"$test_token"* ]] [[ "$output" == *"zrok access private $test_token"* ]] - [[ "$output" == *"ssh -p 9191 root@127.0.0.1"* ]] [[ "$output" == *"╔"* ]] # Box drawing characters [[ "$output" == *"╚"* ]] } From a27347f6aa39a453d63e6d10c32e1f9e55414b2c Mon Sep 17 00:00:00 2001 From: Bui Dai Date: Fri, 9 Jan 2026 18:54:12 +0700 Subject: [PATCH 3/3] feat: update doc and clean up --- README.md | 3 +++ logging_utils.sh | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index cb79602..3e1e12c 100644 --- a/README.md +++ b/README.md @@ -32,6 +32,9 @@ Wait for the setup to complete. You should see output similar to this upon succe ![](https://github.com/user-attachments/assets/22f564f3-8622-4c6c-bb82-9c9c63dd322a) +> [!TIP] +> **Avoiding Session Timeouts**: Kaggle's interactive notebook sessions have idle timeouts. For long-running remote development, use the **"Save & Run All"** feature by clicking the **Save Version** button (top right) and selecting "Save". This runs your notebook as a background job, avoiding timeout interruptions. You can still get the zrok share token from the log screen(click active event at bottom left -> Open Logs in Viewer) + #### How to set up your public SSH key? 1. **Generate an SSH key pair** on your local machine (if you haven't already). Use a descriptive filename, for example: diff --git a/logging_utils.sh b/logging_utils.sh index 242fa42..28fe9e0 100644 --- a/logging_utils.sh +++ b/logging_utils.sh @@ -108,7 +108,7 @@ show_success_banner() { local token_label token_label=$(gum style "📡 Zrok Share Token:") local token_value - token_value=$(gum style --bold "$share_token") + token_value=$(gum style "$share_token") local token_section token_section=$(gum join --vertical --align center "$token_label" "$token_value") local token_box