Skip to content

bug(quick-start): fix kubectl logs verification commands#300

Open
shubhtrek wants to merge 1 commit into
kmesh-net:mainfrom
shubhtrek:fix-kubectl-logs-jsonpath
Open

bug(quick-start): fix kubectl logs verification commands#300
shubhtrek wants to merge 1 commit into
kmesh-net:mainfrom
shubhtrek:fix-kubectl-logs-jsonpath

Conversation

@shubhtrek
Copy link
Copy Markdown

Summary

Fix broken jsonpath expression in the Kmesh verification logs command.

Changes

  • Add recommended label selector based logs command
  • Fix jsonpath syntax for fetching logs from the first pod

Before

kubectl logs -n kmesh-system $(kubectl get pods -n kmesh-system -o jsonpath='{.items.metadata.name}')

After

# Option 1: Get logs from all Kmesh pods (recommended)
kubectl logs -n kmesh-system -l app=kmesh

# Option 2: Get logs from the first pod
kubectl logs -n kmesh-system $(kubectl get pods -n kmesh-system -o jsonpath='{.items[0].metadata.name}')

#297

Signed-off-by: Shubh Pingale <135618936+shubhtrek@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 12, 2026 14:50
@kmesh-bot
Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign nlgwcy for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@netlify
Copy link
Copy Markdown

netlify Bot commented May 12, 2026

Deploy Preview for kmesh-net ready!

Name Link
🔨 Latest commit 643c4a1
🔍 Latest deploy log https://app.netlify.com/projects/kmesh-net/deploys/6a033e33f9627900081cea24
😎 Deploy Preview https://deploy-preview-300--kmesh-net.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the quick-start documentation by improving the kubectl logs verification commands, adding a recommended label-based approach and fixing a JSONPath expression for single pod logs. Feedback was provided to ensure these documentation changes are synchronized with the Chinese translation file to maintain consistency.

Comment thread docs/setup/quick-start.md
Comment on lines +191 to 196
# Option 1: Get logs from all Kmesh pods (recommended)
kubectl logs -n kmesh-system -l app=kmesh

# Option 2: Get logs from the first pod
kubectl logs -n kmesh-system $(kubectl get pods -n kmesh-system -o jsonpath='{.items[0].metadata.name}')
```
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The improvements to the kubectl logs verification commands should also be synchronized with the Chinese translation to maintain consistency across the documentation. The file i18n/zh/docusaurus-plugin-content-docs/current/setup/quick-start.md (around line 151) still contains the broken jsonpath expression and lacks the new recommended label-based command.

Suggested translations for the new comments:

  • # Option 1: Get logs from all Kmesh pods (recommended) -> # 选项 1:获取所有 Kmesh pod 的日志(推荐)
  • # Option 2: Get logs from the first pod -> # 选项 2:获取第一个 pod 的日志

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes the Quick Start verification logs commands by correcting the jsonpath expression and adding a recommended label-selector-based kubectl logs option, aligning the docs with the intended Kmesh verification flow (Issue #297).

Changes:

  • Add a recommended command to fetch logs from all Kmesh pods via -l app=kmesh.
  • Fix the broken jsonpath expression to correctly select the first pod name (.items[0].metadata.name).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/setup/quick-start.md
Comment on lines +194 to +195
# Option 2: Get logs from the first pod
kubectl logs -n kmesh-system $(kubectl get pods -n kmesh-system -o jsonpath='{.items[0].metadata.name}')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants