Allow loading recipe values form env in SetupAiProvider action

Created on 17 February 2025, 5 days ago

Problem/Motivation

Currently you can provide an api key and setup an (simple) AI provider when applying a recipe. It works well both via UI and Terminal via Drush or Project Browser. This can been seen when using Drupal CMS.

We want to automate this process on drush site-install. The value will be know beforehand and could be stored in the systems environment variables.

The idea is that if a recipe with SetupAiProvider is run without any input or as part of the installation process, there will also exist a key called env_var, where the plugin will do a second check if its set, the env var is set and not the default ${some_var} is set from the recipe input process.

It will then set this value instead.

Proposed resolution

Add a key called env_var to the values that can be set in the SetupAiProvider
Change the value, if the value is not set or has the default ${some_var} input value and if the env_var is set and exists.

Feature request
Status

Active

Version

1.0

Component

AI Core module

Created by

🇩🇪Germany marcus_johansson

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024