Working with products

In SPLENT, a product is a Flask application that composes one or more features. A product declares its features in pyproject.toml, manages its own Docker configuration, database, and deployment pipeline, and can be derived from a UVL variability model.


Product structure

my_product/
├── pyproject.toml          ← declares features, version, metadata
├── src/my_product/         ← application source
├── docker/                 ← docker-compose files per environment
├── entrypoints/            ← entrypoint scripts (dev/prod)
├── features/               ← symlinks to .splent_cache/features/
└── uvl/                    ← optional UVL variability model

Features are not copied into the product — they are symlinked from .splent_cache/features/ and installed as editable pip packages.


Declaring features

Features are declared in [tool.splent].features:

[tool.splent]
features = [
    "splent_feature_auth@v1.2.7",
    "splent_feature_redis@v1.2.7",
    "splent_feature_mail@v1.2.7",
]

Run product:resolve to clone any missing features and create their symlinks.


Typical development workflow

product:select   →  set the active product
product:deselect →  enter detached mode
product:resolve     →  clone & link all declared features
product:env      →  generate and merge .env files
product:up       →  start Docker Compose services
product:run      →  execute the entrypoint inside the container
product:logs     →  follow container output
product:shell    →  open a shell in the main container
product:down     →  stop all services

Environments

Most product commands accept --dev or --prod. If neither is provided, SPLENT_ENV is used (defaults to dev). Each environment maps to a separate Docker Compose file:

docker/docker-compose.dev.yml
docker/docker-compose.prod.yml

Command sections

Section Description
Product Setup Create, select, configure, and derive products
Product Runtime Start, stop, monitor, and interact with a live product
Product Inspection Understand config, routes, signals, validation, and health
Product Release & Deploy Build, deploy, and release products

Back to top

splent. Distributed by an LGPL license v3. Contact us: drorganvidez@us.es