product:build

Build deployment artifacts (.env.deploy.example and docker-compose.deploy.yml) by merging the product and its features.


Usage

splent product:build

Description

This command generates two deployment-oriented files inside the product docker/ directory:

  1. .env.deploy.example
    Merges environment variables from:
    • the product (.env.prod.example preferred, otherwise .env.example)
    • all feature docker directories (.env.prod.example preferred, otherwise .env.example)

    When merging, later values override earlier ones (features can override product keys).

  2. docker-compose.deploy.yml
    Merges Compose definitions from:
    • the product (docker-compose.prod.yml preferred, otherwise docker-compose.yml)
    • all feature docker directories (docker-compose.prod.yml preferred, otherwise docker-compose.yml)

    When merging:

    • services: product overrides same-named feature services
    • networks and volumes: dictionaries are merged

The result is a single deploy-ready compose file and a single deploy-ready env template.


Output files

Created under:

<product>/docker/

Files:

  • .env.deploy.example
  • docker-compose.deploy.yml

Requirements

  • A product must be selected (SPLENT_APP set).
  • The product must include a docker/ directory.
  • Features must be linked under <product>/features/ to be included.