saturnin._scripts.bundlerun

Command-line script to run a bundle of Saturnin services.

This script provides a convenient way to execute a collection of Saturnin services as a coordinated bundle. It parses command-line arguments for configuration files and logging levels, then uses saturnin.component.bundle.BundleExecutor to manage the lifecycle of all services within the bundle.

Functions

saturnin._scripts.bundlerun.main(description: str | None = None, bundle_config: str | None = None)[source]

Saturnin script to run a bundle of services.

This function sets up command-line argument parsing, initializes logging and tracing, and then uses BundleExecutor to run the specified service bundle based on the provided configuration.

Parameters:
  • description (str | None) – Custom description for the script, shown when --help is used. Defaults to a standard description.

  • bundle_config (str | None) – Default path for the BUNDLE-CONFIG argument. If None, BUNDLE-CONFIG becomes a required positional argument.

Command-line usage (auto-generated by argparse):

saturnin-bundle [-h] [-c CONFIG] [-s SECTION] [-q] [-o]
                [-l {critical,fatal,error,warn,warning,info,debug,notset}]
                BUNDLE-CONFIG

Positional arguments:
  BUNDLE-CONFIG         Path to service bundle configuration file.

Optional arguments:
  -h, --help            show this help message and exit
  -c CONFIG, --config CONFIG
                        Path to additional configuration file. Could be specified
                        multiple times. (default: None)
  -s SECTION, --section SECTION
                        Configuration section name (default: bundle)
  -q, --quiet           Suppress console output. (default: False)
  -o, --outcome         Always print service execution outcome (default: False)
  -l {critical,fatal,error,warn,warning,info,debug,notset},
  --log-level {critical,fatal,error,warn,warning,info,debug,notset}
                        Logging level (default: None)