Skip to content

Add log helper script#366

Open
norman465 wants to merge 2 commits into
IBM:mainfrom
norman465:add_fleet_logs
Open

Add log helper script#366
norman465 wants to merge 2 commits into
IBM:mainfrom
norman465:add_fleet_logs

Conversation

@norman465
Copy link
Copy Markdown
Member

  • Add log helper script

@norman465 norman465 requested a review from jeremiaswerner May 5, 2026 13:12
Copy link
Copy Markdown
Collaborator

@jeremiaswerner jeremiaswerner left a comment

Choose a reason for hiding this comment

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

Awesome! I love it. Just a few small requests :-)

fi

if [[ -z "${ICL_ENDPOINT}" ]]; then
ICL_ENDPOINT="$(ibmcloud resource service-instance ${ICL_NAME} -o json | jq -r '.[].extensions.external_api')"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This is missing a protocol, e.g. https://

;;

*)
echo "Unknown flag $1"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

a one line usage would be nice, e.g. ./fleet_logs --tier <...> --fleet-id <...> ...

#### Using helper scripts

If you want to quickly iterate you may use the helper script `fleet-logs` in order to display fleet logs directly in your terminal. The scripts uses a `LOGS_URL` env variable targetting your ICL endpoint, or if unset will try to find that ICL endpoint of your ICL instance. Additionally, you may specify `--fleet-id <fleet-id>`, `--since <duration>`, `--tier <search-tier>` and `--output <output-format>` to parameterize your query. Available values are directly taken from `ibmcloud logs query --help`.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

useful additional query statements would be the subCompontentType and the individual --task <task-id>

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

Successfully merging this pull request may close these issues.

2 participants