product:run

Execute the product entrypoint inside the main container.


Development environment

Run (dev)

splent product:run --dev

If no flag is provided, the default environment is dev.


Production environment

Run (prod)

splent product:run --prod

Description

This command executes the product entrypoint script inside the main Docker container of the active product.

The following entrypoint is executed.

<product>/entrypoints/entrypoint.<env>.sh

Where <env> is one of the following.

  • dev
  • prod

The command does the following.

  1. Detects the Docker Compose project for the selected product.
  2. Locates the container belonging to that project.
  3. Identifies the container that mounts /workspace (preferred).
  4. Executes the entrypoint inside that container using the following command.
docker exec

If no container is running, the entrypoint is executed locally.


Compose file resolution

Compose files are resolved in this order.

  1. docker-compose.<env>.yml
  2. docker-compose.yml

Requirements

  • A product must be selected.
splent product:select <product>
  • The product must provide the following.
entrypoints/entrypoint.dev.sh
entrypoints/entrypoint.prod.sh

inside the product directory.


Back to top

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