From 73c742c84e40844e2a3719c43296788190898b15 Mon Sep 17 00:00:00 2001 From: Danny Date: Thu, 24 Apr 2025 00:23:14 +0100 Subject: [PATCH] Create default config table (WIP), add information on argument priority --- Configuration.md | 18 ++++++++++++++++++ Quick-Start-Guide.md | 5 +++-- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/Configuration.md b/Configuration.md index 5633495..819897d 100644 --- a/Configuration.md +++ b/Configuration.md @@ -12,9 +12,27 @@ This document explains the different ways to configure your project environments The default configuration for Spinner environments can be found at [config/spinner.yaml](https://forge.winningsoftware.co.uk/LoomLabs/spinner/src/branch/main/config/spinner.yaml) in the Spinner repository. +## All Configuration Options + +| Option | Config Key | Accepted Values | +|----------------------|---------------------------------------|---------------------------------------------------| +| `--php` | `environment.php.version` | Any PHP version with a valid PHP FPM Docker Image | +| `--disable-database` | `environment.database.enabled: false` | None in CLI / `true`/`false` in `spinner.yaml` | + + # Custom Configuration ## Argument Priority +Environment options and arguments are considered in the following priority order: + +- Those explicitly passed to the commands via the CLI +- Any set in the `spinner.yaml` file in your projects root directory +- Fallback to the default configuration found in this repository at `config/spinner.yaml` + +This means that if you were to set `environment.database.enabled: true` in your config file, but pass the +`--disable-database` flag when running the `spin:up` command, your projects settings would be overridden by +the flag you passed in. + ## Command Line Arguments ## Using Custom Configuration diff --git a/Quick-Start-Guide.md b/Quick-Start-Guide.md index cccc795..752645f 100644 --- a/Quick-Start-Guide.md +++ b/Quick-Start-Guide.md @@ -1,2 +1,3 @@ -After [installation](Installation), you'll need to ensure that your **Docker Engine** is installed and -running before running any `spinner` commands. \ No newline at end of file +After [installation](Installation), you'll need to ensure that your **Docker Engine** is installed and running before running any +`spinner` commands. If you attempt to run any `spinner` commands while your Docker Engine is turned off, you'll see an +error message. \ No newline at end of file