Skip to main content
OverflowAI is here! AI power for your Stack Overflow for Teams knowledge community. Learn more

Questions tagged [configuration]

Use this tag for questions about Drupal's configuration system.

Filter by
Sorted by
Tagged with
1 vote
0 answers
39 views

How to create third party settings for themes?

How to I properly implement third party settings for a theme, without clearing 3rd party settings from other modules? E.g. my site has a gin.settings.yml with third_party_settings: shortcut: ...
Hudri's user avatar
  • 5,530
1 vote
0 answers
76 views

Does anyone have suggestions or recommendations on how to integrate CKEditor 5 Full page HTML plugin successfully into a Drupal website?

I am exploring ways to implement the Full Page HTML feature of CKEditor 5 in Drupal. Does anyone have suggestions or recommendations on how to integrate this feature successfully into a Drupal website?...
aiqntsrgulla's user avatar
1 vote
0 answers
35 views

How can I lint / audit / validate YML to avoid making stupid mistakes?

Is there a way to lint YML to ensure that the values are something that Drupal understands? For example, I recently wrote this YML for a custom module: config/install/mymodule.settings.yml langcode: ...
Patrick Kenny's user avatar
0 votes
1 answer
43 views

Add fields to content-type when Theme is enabled

Is there any way we can change configuration items when we switch to a specific theme? Our (simplified) situation: Using Drupal 10.2 Our customers can choose between different themes Every theme uses ...
mullzk's user avatar
  • 65
0 votes
1 answer
51 views

How can I import staged configuration?

I'm trying to import configuration with drush cim. I'm getting Rename operation for simple configuration. Existing configuration system.site and staged configuration domain.config.xxx.system.site. I ...
Kartagis's user avatar
  • 612
1 vote
0 answers
33 views

Prevent certain config dependencies from being exported to a config file

I have a scenario where I want to import a baseline of configuration for hundreds of sites. New(er) versions of modules recently set permission callbacks to their entities. The problem is that these ...
Kevin's user avatar
  • 27.9k
0 votes
0 answers
33 views

What would cause config export (drush cex) to output to multiple folders instead of just config/sync?

settings.php has a single config sync setting: $settings['config_sync_directory'] = '../config/sync'; Yet every time we run "drush cex" it writes the same config .yml files to three places: ...
quantumized's user avatar
  • 1,227
0 votes
1 answer
82 views

Block config not saved apparently due to an enforced 303 status

After upgrading from 10.0 to 10.1.7, changes to block configuration were no longer saved. I cannot reproduce this in an out-of-the-box instance. I've turned off all custom modules and as many of the ...
JAyenGreen's user avatar
2 votes
2 answers
88 views

How can I have multiple module configs depending on environment?

I have a Drupal site that I build locally and pull to the staging and production servers using git. Normally, my workflow is to run drush cex to export the configs from local, and drush deploy to ...
GeorgeCiesinski's user avatar
0 votes
1 answer
247 views

'stale_file_threshold' is not a supported key [closed]

I have installed "Advanced CSS/JS Aggregation" on my Drupal 10. but after installation, I faced a problem. In performance page, when I want to save configuration (for example I checked/...
Mehrdad201's user avatar
  • 1,312
1 vote
0 answers
32 views

Unable to get $settings['config_exclude_modules'] to work - am I misunderstanding how it works? [duplicate]

Drupal 10 on Pantheon. We have our settings.php file updated with this line: $settings['config_exclude_modules'] = ['devel', 'stage_file_proxy', 'status_messages']; This line exists locally and also ...
quantumized's user avatar
  • 1,227
1 vote
1 answer
72 views

How to execute a drush command with an answer to a prompt

When I run drush it to sync up my taxonomy content, I am prompted to specify the style: What import style would you like?: [0] Full [1] Safe [2] Force Is there a way I can include my answer to this ...
arnoldbird's user avatar
  • 1,213
0 votes
0 answers
147 views

There were errors validating the config synchronization after changes to modules and config

After many hurdles, struggles, and "learning moments", I pushed my site to staging successfully. Unfortunately, I am running into numerous issues when I try to push updates to a deployed ...
GeorgeCiesinski's user avatar
1 vote
1 answer
445 views

How do I override settings.php for Symfony Mailer to use Mailhog for local development?

Now that I am supporting Drupal 10, I needed to set up Mailhog to allow local capturing of emails when I'm testing in my local Docker environment. I used to use the SMTP and Mail System modules and ...
ChumKui's user avatar
  • 179
0 votes
3 answers
91 views

Is it possible to override config in settings.local.php by prepending/appending to the current value?

I have tried both of the following: $config['my_module.default']['content'] = 'prepend ' . $config['my_module.default']['content']; $config['my_module.default']['content'] .= ' append'; but the ...
jofitz's user avatar
  • 125
0 votes
0 answers
54 views

Trusted host patterns problem, again

I need to set up trusted host patterns for 3 EC2 instances. They all share same base code, so they all use the "same" settings.php. On my two (production) instances everything works fine: ...
lazarcelic's user avatar
0 votes
0 answers
33 views

Why does a custom matcher cause a linkit profile to be deleted on module uninstall?

In a custom module, I've set up a custom EntityMatcher in order to get suggestions for instances of my custom entity type in the linkit dialogue. This all works very fine. However, when uninstalling ...
MSNOP's user avatar
  • 11
0 votes
1 answer
110 views

How to update migration field mapping using custom module/form?

I was learning about Drupal migration recently and found out that we can use Migrate Plus module to import migrations as configurations. Hence I started wondering if a migration is imported as a ...
SGupta's user avatar
  • 1
0 votes
0 answers
37 views

Configuration synchronization

I am trying to import views from one of my Drupal 9 sites, we will call it Drupal A to another Drupal 9 site, we will call it Drupal B. I keep getting this error: Error message The configuration ...
Madison's user avatar
0 votes
1 answer
48 views

How to pass block instance configuration settings to TWIG template?

I've got a custom block plugin which has some configuration settings that can set from the block configuration form. How can I then access that configuration info later when the block is being ...
micbay's user avatar
  • 13
0 votes
1 answer
67 views

How to Save Configuration Data for Custom Block

I'm have a custom module that creates a custom block plugin, but am having trouble figuring out how to add some custom configuration settings to the block. Just for understanding how to do this, I've ...
micbay's user avatar
  • 13
0 votes
0 answers
144 views

How to run drush cim command for importing all the configurations

I cloned the drupal project on my local. I have a Docker desktop app. so I run docker-compose up -d on command prompt. docker-compose.yml: services: mariadb: image: wodby/mariadb:$MARIADB_TAG ...
Bohdan V.'s user avatar
0 votes
1 answer
126 views

Custom field type that has an array property won't save unless serialized, otherwise get "This value should be of the correct primitive type" error

I have a custom field type with two properties I am storing on it. One stores a string. The other I want to store an array. The array should be serialized in the field value table of the database, but ...
Kevin's user avatar
  • 27.9k
0 votes
0 answers
37 views

Install module with required config that may exist

I have a module that have some config in config/install folder, that require config that may already exist in the current config. So I placed those config under config/optional. But if those config ...
Mistraë's user avatar
  • 392
0 votes
1 answer
40 views

is it posible to get the value of other fields right inside the buildForm() method without having to save configuration?

I have a config form with two select fields. The first one(vocabulary) gets populated automatically without problems with options taken from the available vocabularies for users to pick up one. The ...
Jorge Luis Arzola's user avatar
0 votes
0 answers
208 views

How can you update a single configuration entity using drush?

Every now and then, if I try to import partial configs using drush, like drush config:import --partial --source=stuff/is/here drush seems to understand that some of these config entities exist in the ...
commonpike's user avatar
0 votes
2 answers
257 views

Config Export changes to different folder

Is it possible to export only the changed configuration files to a specified folder? When you run drush cex to see the change list of files like this +------------+----------------------+-----------+ |...
Andrew Morris's user avatar
0 votes
0 answers
30 views

Why does Drush:migrate not generate config entities for separate content types?

When using Drupal 9 with modules migrate, migrate_drupal, migrate_upgrade and migrate_plus, and calling drush:migrate --configure-only with a Drupal 7 source database I see migrations at drush ...
commonpike's user avatar
1 vote
2 answers
274 views

Enum class not found when trying to use it in settings.php

I defined an enum in a custom module: namespace Drupal\my_module\Enum; enum BuildType: string { case Apple = 'apple_build'; case Orange = 'orange_build'; } And I want to use it in settings.php ...
Patrick Kenny's user avatar
3 votes
0 answers
51 views

Can I use pseudofields in anything other than source?

If I use pseudofields in the source property for my custom plugin, they are correctly substituted with the computed values. If I use them in another configuration (as per the example), they are ...
Geat's user avatar
  • 463
0 votes
1 answer
29 views

Custom form, add admin editable instructions from settings area to form

I have a custom form that is working great. I'd like to add a field "instructions" right under the title, above the first form field. This "instructions" field is editable in the ...
jasonflaherty's user avatar
0 votes
0 answers
44 views

Config split is imported only every second time of jenkins job run

I have some weird behavior with drush cim when running from a jenkins job. It seems like a config split is only imported every second time or so when the job is run. The update skript containing the ...
macbert's user avatar
  • 363
3 votes
0 answers
101 views

Enable a module with sample config that depends on a theme

I have a submodule that provides some prepared configuration via config/install. The goal is to have devs enable that module to get a preconfigured set of content types complete with preconfigured ...
Joseph's user avatar
  • 1,598
0 votes
0 answers
34 views

Why isn't this configuration saving?

How do I do change configuration when there is a dash in the yml file? The configuration is the following one. source: plugin: url data_fetcher_plugin: http data_parser_plugin: xml urls: - ...
esod's user avatar
  • 319
0 votes
1 answer
72 views

Deleted context link still exists in admin toolbar menu

I have deleted context but in admin toolbar it still showing . On main context admin page context doesn't exists. I have installed/uninstalled module - not helping How do i remove that link from ...
Vitaliy K's user avatar
  • 129
0 votes
0 answers
31 views

Can I change the autocomplete to a dropdown for the entity_browser module?

I'd like to be able to change the autocomplete for the Site Sections portion of the entity_browser module. I'm not seeing any way to modify this within the admin. Am I missing something? Can I do this ...
bigmike7801's user avatar
0 votes
0 answers
38 views

How to import localized version of a configuration file

With drupal, you can import a single config file. Let say it is a view config file and let say that this view has been translated in french and has produced a locallized config file under the "fr&...
Baud's user avatar
  • 542
0 votes
1 answer
70 views

Block Configuration Form Returning Unexpected Value

I'm trying to build a block configuration form. Here's my blockForm code: public function blockForm($form, FormStateInterface $form_state) { $form['resolve_ip_addresses'] = [ '#type' => ...
Scott Hollenbeck's user avatar
0 votes
0 answers
203 views

Why my custom module configuration are not getting created on module install?

I have created one custom module with config/install folder. This install folder contain content type yml. Basically on install of custom module new content type should be created. When I use drush en ...
Sudha's user avatar
  • 71
5 votes
1 answer
109 views

How do I import a sync config file into my Kernel unit test?

How do I import a sync config file into my Kernel unit test ? Specifically, I have some REST resources in files config/sync/rest.resource.foo.yml,config/sync/rest.resource.bar.yml At present, when I ...
Monkeybrain's user avatar
3 votes
0 answers
100 views

Where do you put install config translations?

I have a Drupal 9 site. When I export site config (drush cex) I get config/sync dir with settings and inside it I have i.e. language/de where translation config is stored. So translations are in ...
MilanG's user avatar
  • 539
2 votes
1 answer
340 views

How to create configurable plugins under a plugin manager?

I have a custom plugin type and annotation. The purpose of it is so people can develop their own clients for an API integration, and tell the system which plugin to use to perform these actions. I am ...
Kevin's user avatar
  • 27.9k
0 votes
2 answers
411 views

Error about non-existing configuration

After trying to import configuration with drush cim it returns an error saying The import failed due to the following reasons: Configuration core.entity_view_display.contact_message.kontaktujte_nas....
Tomáš Bažant's user avatar
1 vote
2 answers
319 views

Programmatically add new fields to content type

I have a custom module that has a form that allows the user to select various content types. I would like to create fields for those content types programmatically so that after the form is saved, it ...
user1470118's user avatar
0 votes
0 answers
64 views

How to import config to a site installed with a profile?

Good day. I’ve installed a profile, made my settings, entered my content, exported config and pushed everything to the repo. Now, when I clone it somewhere else and attempt to install using the config,...
Kartagis's user avatar
  • 612
0 votes
0 answers
139 views

Why does layout builder duplicate the body of a node after a full configuration import?

I used Layout builder for a site (Site A) using Drupal 9 and configured the Article content type to Use Layout Builder and Allow each content item to have its layout customized This allowed me to ...
Dakotaw's user avatar
  • 11
1 vote
1 answer
311 views

Correct schema for an Entity Reference in config settings

Background I am creating a schema for a custom module's config settings, which are saved from a simple settings form. It has some basic fields, such as a checkbox for a Boolean value for hiding some ...
mbomb007's user avatar
  • 516
-4 votes
1 answer
478 views

Error importing configuration [duplicate]

[error] Drupal\Core\Config\ConfigImporterException: There were errors validating the config synchronization. The <em class="placeholder">language.content_settings.media.instagram</...
LeJuanChis's user avatar
0 votes
0 answers
2k views

PluginNotFoundException entity type does not exist when trying to uninstall any module

I've got this drupal website from a client that the another developer created, and they've made a mess with many things in this site. I'm having a problem where every time I try to uninstall a module, ...
Jean da Silva's user avatar
1 vote
0 answers
81 views

How to invalidate config or service cache

I have a service wich is loading a config at construct time: class MyService { public function __construct(ConfigFactoryInterface $config_factory) { $config = $config_factory->get('my.config')...
Baud's user avatar
  • 542

1
2 3 4 5
17