beclab/olares

olares-shared

Foundation for the olares-cli skill suite: choose the right domain skill, understand the Olares platform model each task depends on, and decide whether the active profile can proceed or needs login recovery.

查看源码

使用方法

  1. 复制安装命令,在自己的智能体环境安装前先检查源码包。
  2. 从原始文档核对所需工具、凭据和支持的宿主。
  3. 说明输入材料与期望交付物,并对照来源检查输出。
npx skills add https://github.com/beclab/olares --skill olares-shared

开始前需了解

  • 安装不包含模型订阅、API 额度或访问文件的权限。
  • 仓库星数和安装量反映活跃情况,不等于独立质量或安全测试。
仓库原始内容

按源仓库内容呈现,保留标题、案例、代码、表格、链接以及原文引用的演示图片。

olares-cli shared rules

Read this thin front door before a runtime skill. It supplies the active-profile model, platform entry points and the auth proceed/stop rule — what a task needs once it knows which skill it belongs to. Load detailed references only when the current task triggers them.

  • Suite map: which skill owns which task, and how to install olares-cli when it is not on PATH. Read it when the task has not been routed to a skill yet; a task that has been does not need it again.

Reading the answer

Every profile-backed tree spells machine-readable output the same way: -o json (--json is the same request, kept for older scripts). A verb that fails under it answers on stderr with {"error":{"code","message","retryable","action"}}, and stderr carries nothing else, so it parses whole.

.error.code is worth branching on where it is set, and today that is the failures whose recovery differs from every other failure's: auth_no_profile, auth_not_logged_in, auth_token_expired, auth_token_invalidated and timeout, plus whatever Router reports from upstream. Everything else arrives as unclassified with the whole story in .message. So read the code first, and fall back to the message rather than assuming a code you did not get means something. retryable and action are present only when the failure knows them — their absence means unknown, not "no".

Some trees also carry their own result document (Market's lifecycle verbs report .status and .finalState); where they do, that is the one to read.

Platform entry points

  • Olares platform model: userspace storage, uid/gid 1000, protected Home directories, app/namespace networking, system middleware and Olares version semantics. Read it for files, chart, cluster or settings tasks that touch those concepts.
  • Application state machine: lifecycle transitions, allowed operations, backend timeouts, serialized downloads, running semantics and unreliable progress. Read it for market operations or runtime diagnosis.
  • Profile and authentication: login/import flows, profile statuses, token storage and refresh behavior. Read it only for profile work or auth recovery.

Active profile

One profile selects one Olares instance and one Olares identity. Every profile-backed command targets that selection; there is no per-command --profile override.

CommandPurpose
olares-cli profile listShow profiles, current selection, auth status and cached Olares version
olares-cli profile whoamiIdentity and role of the selected profile; the admin/normal answer other skills gate on
`olares-cli profile use <name\->`Switch selection; - returns to the previous profile
olares-cli profile loginAuthenticate with password and optional TOTP
olares-cli profile importBootstrap from a refresh token
olares-cli profile remove <name>Remove a profile and its credential

Use olares-cli profile --help for flags and the auth reference for login or recovery.

Auth-readiness gate

Proceed by default:

  • logged-in, expired and pending proceed; an expired access token normally refreshes on the next request, and pending is a platform-issued profile whose grant has not been exchanged yet.
  • never and invalidated stop for profile login or profile import — unless SOURCE reads platform(<app>), which the platform issued to an application: login, import and remove are all refused there, nothing local can mint or revoke that grant, and the recovery is reinstalling or repairing that application. The same answer covers no profile at all inside an application container — say the application needs repair rather than asking for a login.
  • For unknown or an unparseable token, run the business command and react to its typed error instead of guessing.

Do not preflight every command. The CLI refreshes and retries an authentication rejection once. Stop for login when the CLI explicitly says the credential is absent/invalidated or prints a login action after a persistent 401/459. A 403 permission denial, network error or 5xx is not a login signal. Never build a retry loop around auth errors.

Safety and escalation

  • Never place a password in command arguments. Use the interactive prompt or --password-stdin.
  • Never print access or refresh tokens. Source imports from a secret environment variable or secret manager.
  • Ask before login, credential replacement, an ambiguous target or an action outside the user's authorised task scope.
  • Within an authorised chart deploy/debug task, install, upgrade, restart, uninstall and clean reinstall are normal loop steps; do not ask again for each command.

按任务相关推荐

来自同一仓库

更多 Skills

全部 Skills
beclab
社区

olares-chart

Olares app packaging and chart authoring via olares-cli chart — port a repo, docker-compose, or generic Helm chart; build/push the image; author, lint, package, and deploy an OlaresManifest; wire storage, middleware, entrances, env, and GPU; edit the chart after diagnosis. Runtime failure diagnosis is olares-doctor; public Market submission is olares-publish.

安装量
2
GitHub Stars
5311
最近更新
10月20日
beclab
社区

olares-cluster

Olares ControlHub K8s runtime view via olares-cli cluster — inspect pods, containers, workloads, logs, jobs, cronjobs, namespaces, nodes, and middleware; exec, scale, restart, or delete K8s objects. Use for raw runtime objects and logs, not app lifecycle (market), resource metrics (dashboard), or host install.

安装量
2
GitHub Stars
5311
最近更新
10月20日
beclab
社区

olares-dashboard

Olares Dashboard via olares-cli dashboard — CPU, memory, disk, network, pod counts, fan, GPU, application/resource rankings, JSON envelopes, and --watch. Use for Dashboard metrics, overview, resource usage, and Olares One fan; not for pod logs or K8s object inspection (olares-cluster).

安装量
2
GitHub Stars
5311
最近更新
10月20日
beclab
社区

olares-files

Olares Files via olares-cli files — browse known paths; upload or download file bytes; edit, share, mount SMB/NFS, compress/extract archives, and manage Seafile sync across Drive/cache/external/cloud. Use for Olares Files and LarePass Files operations, not URL/yt-dlp/torrent download tasks (olares-knowledge).

安装量
2
GitHub Stars
5311
最近更新
10月20日