openpalm 0.3.0 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +35 -0
  2. package/dist/openpalm.js +7599 -51
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -22,6 +22,9 @@ bunx openpalm install
22
22
  | `restart [service...]` | Restart services |
23
23
  | `logs [service...]` | View container logs |
24
24
  | `status` | Show container status |
25
+ | `service <up\|stop\|restart\|logs\|update\|status>` | Domain-based service operations |
26
+ | `channel <add\|configure>` | Domain-based channel operations |
27
+ | `automation <run\|trigger>` | Domain-based automation operations |
25
28
  | `extensions <install\|uninstall\|list>` | Manage extensions |
26
29
  | `dev preflight` | Validate development environment |
27
30
  | `dev create-channel` | Scaffold a new channel adapter |
@@ -61,3 +64,35 @@ cd packages/cli && bun test
61
64
  ## Dependencies
62
65
 
63
66
  Depends on `@openpalm/lib` (workspace package) for shared utilities like path resolution, runtime detection, and compose generation.
67
+
68
+ ## Execution modes (same commands for local and remote admin)
69
+
70
+ Domain commands automatically choose execution mode:
71
+
72
+ - **Local mode (default):** if admin API env vars are not explicitly set, service commands run locally via compose.
73
+ - **Remote admin API mode:** if admin API env vars are set, domain commands call admin over HTTP (`x-admin-token`), so callers do not need Docker socket access.
74
+ - **Assistant env fallback:** CLI also reads `${OPENPALM_STATE_HOME}/assistant/.env` for admin URL/token values.
75
+
76
+ Environment variables (all optional):
77
+
78
+ - `OPENPALM_ADMIN_API_URL` (preferred), `ADMIN_APP_URL`, or `GATEWAY_URL` for admin endpoint resolution.
79
+ - `OPENPALM_ADMIN_TOKEN` (preferred) or `ADMIN_TOKEN` for authentication.
80
+ - `OPENPALM_ADMIN_TIMEOUT_MS` request timeout (default `15000`).
81
+ - `OPENPALM_ALLOW_INSECURE_ADMIN_HTTP=1` to allow public/non-private HTTP URLs (not recommended).
82
+
83
+ Examples:
84
+
85
+ ```bash
86
+ # Local default service execution
87
+ openpalm service restart assistant
88
+
89
+ # Remote admin API execution (same command shape)
90
+ export OPENPALM_ADMIN_API_URL=http://admin:8100
91
+ export OPENPALM_ADMIN_TOKEN=...
92
+ openpalm service restart assistant
93
+
94
+ # Domain commands for channels/automations
95
+ openpalm channel add /path/to/channel.yaml
96
+ openpalm channel configure discord --exposure lan
97
+ openpalm automation run example-job
98
+ ```