trying to rework database migrations

This commit is contained in:
2026-02-05 11:42:04 -06:00
parent 3b14c65998
commit 343488b3eb
83 changed files with 5793 additions and 876 deletions

View File

@@ -0,0 +1,26 @@
# Core Pack Runtime Metadata
This directory contains runtime metadata YAML files for the core pack. Each file defines a runtime environment that can be used to execute actions and sensors.
## File Structure
Each runtime YAML file contains only the fields that are stored in the database:
- `ref` - Unique runtime reference (format: pack.name)
- `pack_ref` - Pack this runtime belongs to
- `name` - Human-readable runtime name
- `description` - Brief description of the runtime
- `distributions` - Runtime verification and capability metadata (JSONB)
- `installation` - Installation requirements and metadata (JSONB)
## Available Runtimes
- **python.yaml** - Python 3 runtime for actions and sensors
- **nodejs.yaml** - Node.js runtime for JavaScript-based actions and sensors
- **shell.yaml** - Shell (bash/sh) runtime - always available
- **native.yaml** - Native compiled runtime (Rust, Go, C, etc.) - always available
- **sensor_builtin.yaml** - Built-in sensor runtime for native Attune sensors
## Loading
Runtime metadata files are loaded by the pack loading system and inserted into the `runtime` table in the database.

View File

@@ -0,0 +1,18 @@
ref: core.native
pack_ref: core
name: Native
description: Native compiled runtime (Rust, Go, C, etc.) - always available
distributions:
verification:
always_available: true
check_required: false
languages:
- rust
- go
- c
- c++
installation:
build_required: false
system_native: true

View File

@@ -0,0 +1,23 @@
ref: core.nodejs
pack_ref: core
name: Node.js
description: Node.js runtime for JavaScript-based actions and sensors
distributions:
verification:
commands:
- binary: node
args:
- "--version"
exit_code: 0
pattern: "v\\d+\\.\\d+\\.\\d+"
priority: 1
min_version: "16.0.0"
recommended_version: "20.0.0"
installation:
package_managers:
- npm
- yarn
- pnpm
module_support: true

View File

@@ -0,0 +1,29 @@
ref: core.python
pack_ref: core
name: Python
description: Python 3 runtime for actions and sensors with automatic environment management
distributions:
verification:
commands:
- binary: python3
args:
- "--version"
exit_code: 0
pattern: "Python 3\\."
priority: 1
- binary: python
args:
- "--version"
exit_code: 0
pattern: "Python 3\\."
priority: 2
min_version: "3.8"
recommended_version: "3.11"
installation:
package_managers:
- pip
- pipenv
- poetry
virtual_env_support: true

View File

@@ -0,0 +1,14 @@
ref: core.sensor.builtin
pack_ref: core
name: Builtin
description: Built-in sensor runtime for native Attune sensors (timers, webhooks, etc.)
distributions:
verification:
always_available: true
check_required: false
type: builtin
installation:
method: builtin
included_with_service: true

View File

@@ -0,0 +1,28 @@
ref: core.shell
pack_ref: core
name: Shell
description: Shell (bash/sh) runtime for script execution - always available
distributions:
verification:
commands:
- binary: sh
args:
- "--version"
exit_code: 0
optional: true
priority: 1
- binary: bash
args:
- "--version"
exit_code: 0
optional: true
priority: 2
always_available: true
installation:
interpreters:
- sh
- bash
- dash
portable: true