-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Summary
Introduce a “builder” concept so each app directory can define pre-deployment steps. Builders can be built-in or plugin-based. Some apps may use ready images, while others will be built from source (e.g., GitHub) using a builder.
Why
Certain apps require preparation before running—compiling assets, generating keys, running migrations, packaging binaries, etc. Builders standardize this workflow in FlatRun.
Requirements
-
Builder Logic
Encapsulate steps for specific app types. Examples:npm run build/npm run dist→ JS frontendsphp artisan key:generate→ Laravelgo build→ Go projectscomposer install→ PHP apps
-
Detection
- Explicit config in
app.yml(e.g.,builder: "npm") - Auto-detect from files (
package.json,composer.json, etc.)
- Explicit config in
-
Plugin Support
- Allow custom builders via modules or external hooks
- Interface:
Detect(appDir string) boolBuild(appDir string) error- Optional:
Prepare(appDir string),PostBuild(appDir string)
-
Execution & Deployment Types
- Run in sandboxed environment
- Clear logs via Agent UI/API
- Failures block deployment unless overridden
- Support dry-run mode to preview commands
- Deployment types:
- Ready compose files → use existing Docker images
- Build from source and generate compose files → use a builder to generate deployment artifacts
Metadata
Metadata
Assignees
Labels
No labels