Bundle Management (zeysdk bundle)
The bundle command provides functionality for creating and installing bundles of ZeyOS applications.
Commands
Create Bundle
Creates a bundle file containing selected ZeyOS applications from the current directory.
Usage:
zeysdk bundle create [output] [options]
Parameters
| Parameter | Description | Required | Default |
|---|---|---|---|
output | Bundle filename | ❌ | Interactive prompt |
Options
| Option | Description | Default |
|---|---|---|
-v, --verbose | Show detailed output | false |
Directory Scanning
- Scans current directory for potential ZeyOS apps
- Skips hidden directories (starting with '.')
- Ignores
node_modulesandvendordirectories - Validates each directory for
zeyos.app.json - Checks for required fields:
identifierandname
Interactive Selection
-
Output File
- If not provided as argument, prompts for filename
- Default suggestion: 'bundle'
- Validates for non-empty input
-
App Selection
- Shows checkbox list of valid ZeyOS apps
- Must select at least one app
- Maximum 20 items per page
- Apps sorted alphabetically in output
Install Bundle
Installs multiple applications from a bundle file to a specified instance.
Usage:
zeysdk bundle install <bundle> <instance> [options]
Parameters
| Parameter | Description | Required | Example |
|---|---|---|---|
bundle | Path to bundle file | ✅ | my-bundle |
instance | Target instance identifier | ✅ | dev-instance |
Options
| Option | Description | Default |
|---|---|---|
-v, --verbose | Show detailed output | false |
-f, --force | Continue installation if errors occur | false |
Instance Configuration
If instance not found:
- Prompts to configure new instance
- Collects instance details:
- URL (default:
https://cloud.zeyos.com/<instance>) - Authentication token
- URL (default:
- Stores credentials securely
Installation Process
-
Validation
- Verifies bundle file exists and is readable
- Checks instance configuration
- Validates app directories
-
For Each App
- Links to specified instance
- Switches to instance context
- Pushes app content
- Shows progress spinner
- Reports success/failure
-
Results
- Shows installation summary
- Reports successful/failed installations
- Continues on errors if --force used
Error Handling
Create Bundle Errors
| Error | Description | Resolution |
|---|---|---|
| No directories | Empty current folder | Navigate to folder with apps |
| No valid apps | No ZeyOS apps found | Verify app directory structure |
| Invalid selection | No apps selected | Select at least one app |
| Write error | Cannot create bundle file | Check write permissions |
Install Bundle Errors
| Error | Description | Resolution |
|---|---|---|
| Bundle not found | Bundle file missing | Check file path |
| Invalid instance | Instance not configured | Follow setup prompts |
| Invalid token | Authentication failed | Check instance credentials |
| Directory error | App directory not found | Verify bundle contents |
| Push failed | App deployment failed | Check app configuration |
Examples
Create a bundle:
zeysdk bundle create my-bundle
zeysdk bundle create --verbose
Install a bundle:
zeysdk bundle install my-bundle dev-instance
zeysdk bundle install my-bundle prod-instance --force --verbose