Questions tagged [configuration]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
-4 votes
1 answer
32 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</...
  • 1
0 votes
0 answers
79 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, ...
1 vote
0 answers
39 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')...
  • 536
1 vote
1 answer
34 views

How should we configure Config link on custom module?

I need to create Config link while enabling module. In routing file, I have mention the path name of config form, but its not directly show in the Configuration page. Below is my routing code. ...
  • 450
1 vote
1 answer
28 views

How to temporarily override configuration?

I want to be able to contextually modify configuration variables, i.e. within a page controller. Example I have a custom ad module which besides other settings has an option to globally disable or ...
  • 615
0 votes
0 answers
18 views

Getting possible values for a property in a config entity form

I've defined a custom DataType plugin which implements Drupal\Core\TypedData\OptionsProviderInterface. I've also got a config entity type which defines one of its properties as being of this custom ...
  • 797
1 vote
1 answer
56 views

Config sync & Field default value for entity reference fields

Given two environments dev & live, how do you properly transfer field default values for entity reference fields when deploying with Drush (cex & cim)? The default value is a UUID, which is ...
  • 5,077
0 votes
0 answers
70 views

Import config on Drush install with config in non-standard directory

I've got a site set up with its config sync in a directory outside of web root; specifically ../config/sync (relative to the Drupal root). I have that path set for $settings['config_sync_directory'] ...
1 vote
1 answer
33 views

Custom theme settings not saving

I am in Drupal 9.3 and I am working to add 5 new fields to the theme settings. I am following all the instructions I can find. I have tried clearing caches a few times. I can see the fields. But ...
  • 1,290
0 votes
2 answers
154 views

How do I create a configuration schema of type array?

I have a PHP array where an instance may look like this: $mymodule_myarray = [ 'first' => 0, ]; I want to have it represented and initialised as part of the configuration for the custom module &...
  • 14.9k
0 votes
0 answers
20 views

How to inherit Payment Gateway configurations?

I have a main payment gateway which I want to configure. And multiple other payment gateways which I want to inherit the main gateway's configuration data. I only have the CommercePaymentGateway ID (...
0 votes
1 answer
96 views

After installing webform, unable to use composer

The crux of this matter is that composer is now not working. I get the following when I try to run almost any composer command. (This Drupal 9 site is a composer installed site, and I would like to ...
0 votes
1 answer
16 views

Is the config object adapted to store datas from many users ( for the purpose of a subscription custom module )?

I have created a custom module that allows to subscribe to some news. Each user ( and there will be thousands of them ) can register to some news category using that form On form submit, the couple [...
  • 2,865
2 votes
1 answer
60 views

Configuration import continues to list items as 'importable'

I am developing on a Drupal 9 site. I have found something a bit odd when running drush cim. There are a handful of configurations for which it DOES say there was a success, but when you run drush cim ...
  • 1,771
2 votes
1 answer
34 views

Installing configuration from a module that is tracked in configuration on deployment

I am trying to install a module on a higher level environment. The module installs configuration in its config/install directory, and that configuration was also exported to the main site ...
  • 27k
0 votes
1 answer
163 views

Is it possible to programmatically change the config_sync_directory path after profile installation?

Installing Drupal 9 using a custom profile installation, I have defined "config_sync_directory" in settings.php file in $settings array to pick up the profile config during installation. ...
1 vote
1 answer
105 views

Set nested value in storable config

I have a settings form that saves site wide configuration information My submit form function looks something like this $data = []; foreach ($groups as $key) { $data[$key] = $form_state->getValue(...
  • 5,270
0 votes
1 answer
361 views

There were errors validating the config synchronization

Locally I deleted custom block "CTA" from custom blocks and block types. Then I exported configs and created merge request. After merge is accepted, the pipeline runs commands on the dev ...
1 vote
1 answer
50 views

How to ignore block region placements during config sync?

When we perform config export and import our block placements are getting hosed. Is there a way to no export block placements/regions?
  • 1,027
0 votes
2 answers
150 views

How to hide the fields in manage display when layout module is installed and display when module is uninstalled programmatically?

In the below config I want to remove the body field from content and add it in hidden as body: true when I uninstall the layout module. Basically when I install the layout module the fields in manage ...
1 vote
1 answer
140 views

"Items in your active configuration have changes"

I'm trying to setup configuration management for our team, so i test the workflow on my local machine: Starting from a fresh copy of our website + database backup, with an empty /config folder ($...
0 votes
1 answer
49 views

How can I programmatically add or remove a new request_path to block visibility?

It seems like I could utilize the getVisibilityConditions method on the block, which returns a ConditionPluginCollection object with a setInstanceConfiguration method, which is apparently easy enough ...
  • 349
1 vote
1 answer
32 views

Adding sequence item to configuration

I have a configuration item in my custom module, part of which is a sequence, basically I'm attempting to create something akin to an array of items my_module.schema.yml my_module.settings: type: ...
0 votes
1 answer
51 views

How to Install new module, add code to existing module that requires the new module, and import config for the new module in the same build

I seem to be running into a circular dependency issue in the scenario where my new build has a new module (B), new code in an existing module (A) that depends on the new module (B) and new config ...
  • 880
0 votes
1 answer
49 views

How to prevent changing specific module installed status during config syncs?

I know there are methods for preventing specific configurations from being exported but how do you prevent specific module's installed/un-installed status from being exported? For example, I'd like ...
  • 1,027
1 vote
0 answers
107 views

Field Label Translation not working

I have a Drupal 9 site. The default language is English, second language is German. I keep having problems with translations in the backend. Lots of field labels and other text shows up in English, ...
0 votes
1 answer
429 views

Migrate PHP version - The "" plugin does not exist

I'm using Drupal 9.3.11 on PHP 7.3. Site is running perfectly. I need upgrade to PHP 8, but I am getting this error. Drupal\Component\Plugin\Exception\PluginNotFoundException: The "" plugin ...
  • 143
0 votes
0 answers
100 views

Webform Confirmation settings on form submission not working

I am using Acquia site studio components for web pages. In all the pages I have a pop-up with a webform submit button to enter to the site. In Webform confirmation settings I have selected the option -...
0 votes
1 answer
76 views

"[message] => DB Error: no such table" error after installing civicrm

I installed CiviCRM 5.47.3 plugin using composer in the centos 8 server. my drupal version is 9.3.5 After installing CiviCRM on the server CiviCRM plugin is enabled automatically in admin extension ...
0 votes
1 answer
40 views

How to create a configuration export such that it installs two modules, one of which has a dependency on the other?

I've written a custom module that uses jwt.transcoder service from the jwt module. In turn, it provides another service: $ cat mymodule.services.yml services: mymodule.jwt: class: Drupal\...
  • 3,849
0 votes
0 answers
37 views

configuring backup migrate file name in settings file

Drupal 9.3.7, backup_migrate 5.0.1 --- On my dev machine, I've set the name for backup_migrate backup files in the config settings. When I export the database to my production machine, I'd like to use ...
  • 409
3 votes
0 answers
18 views

How are the Ignored and Undefined config schema classes supposed to be used?

In Drupal\Core\Config\Schema there are two classes Ignored and Undefined, but they're empty. How are they meant to be used?
  • 797
4 votes
1 answer
225 views

Properly storing an array in a config object

In a config object, I want to store an array of values. The keys matter. The stored value is coming from a checkboxes element, so the array would look something like: ['article' => 'article', 'page'...
  • 27k
1 vote
1 answer
99 views

Add simple config object as a cacheable dependency?

I am building a custom breadcrumb that has some admin settings from a module in Drupal 9. When that settings form is saved, I want any breadcrumb cache that was built with this builder to be ...
  • 27k
0 votes
0 answers
109 views

How to configure trusted hosting pattern for Docker containers

From Drupal 8, if my running Docker project for Drupal is loading in my browser at... http://docker.drupalphp:17223/ what should I put in my sites/default/settings.php file to approve the ...
  • 101
-2 votes
2 answers
174 views

Is there any `drush` command to delete any (previously exported) setting files? [closed]

Can we use drush to simply delete any (previously exported) config-directory files?
-3 votes
1 answer
400 views

How does `drush cim` find and handle the config-directory? [closed]

I would like to know where the config directory is, and how drush cim command exactly handles it, to be more specific: Where are the setting files imported from, can you provide me with a path ...
0 votes
0 answers
46 views

Fixing different configs

After I have run drush cim successfully, I can run drush cst and I see a great number of entries where the configs are "different". What is the best method to fix this?
  • 289
2 votes
0 answers
30 views

How to automize the config export to a custom distribution

We use a custom Drupal distribution on our websites. There are also our custom modules in the distribution. The modules contain configurations. When I change some configurations in Drupal ...
0 votes
0 answers
51 views

How can improve performance?

I have a very complicated form with 7-8 tabs and 150 elements on forms. The form initially loads very slowly and it will take 30 - 40 seconds to load and sometimes gateway times out error. When I used ...
  • 109
1 vote
1 answer
47 views

Why isn't config for Views plugin module translatable?

I am trying to write up a patch for this module: https://www.drupal.org/project/readmore. There is a patch for it: https://www.drupal.org/project/readmore/issues/3055200 which adds configurable text ...
  • 936
2 votes
0 answers
67 views

How to deal with config sync changing the order of lines in files causing spurious changes in source control?

I am really enjoying Drupal 8/9's built-in config sync mechanism which allows you to export config to a directory. This makes it possible to store config in a git repo and easily deploy from dev to ...
  • 1,003
1 vote
1 answer
322 views

drush configuration import export order of the yml

I recently upgraded some minor versions of modules and upgraded Drupal core-recommended to 9.3.3 from 9.2.9. I followed the usual drush updatedb, drush cim -y drush cr and everything looks fine. In my ...
  • 31
1 vote
1 answer
39 views

How do I control config names?

When creating a config entity, we get an example_entity.schema.yml file: example_module.example_entity.*: type: config_entity label: 'Example config' mapping: id: type: string ...
0 votes
0 answers
56 views

Creating tabbed config settings

I'm trying to create a tabbed configuration page for my custom module, although I can't see a lot of information on exactly what is supposed to be done. I've seen this page but it's not exactly in ...
0 votes
1 answer
89 views

Custom Module Rename

We have three custom pieces of code for our Drupal website: module, theme and a non-drupal php library. The names of these components have become awkward over time. I would like to rename our custom ...
  • 533
2 votes
1 answer
229 views

ConfigNameException: Missing namespace in Config object name xxx

Drupal\Core\Config\ConfigNameException: Missing namespace in Config object name media_entity_file_replace. in Drupal\Core\Config\ConfigBase::validateName() (line 97 of core/lib/Drupal/Core/Config/...
  • 2,865
0 votes
0 answers
27 views

What is langcode in config export used for?

When exporting configuration into .yml files with drush csex, some files have a langcode property set. After some weeks or months of working with the system, they sometimes disappear in some files ...
  • 144
1 vote
1 answer
71 views

Can you install exported site config as part of a kernel test?

I am using the Configuration Sync module to export config specific to my site out into a config directory that lives outside my main Drupal directory. When writing kernel tests I know that you can use ...
0 votes
0 answers
21 views

How can I load a translated version of my custom config? [duplicate]

I created a custom configuration form that can be translated into all available languages. My question is how we can get the translated version of the configuration for a specific language on the ...

1
2 3 4 5
17