Questions tagged [configuration-management]

Managing configurations across environments is part of the configuration management.

175 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
7
votes
0answers
1k views

How do I translate theme settings?

How do you translate custom theme settings in Drupal 8? I use hook_form_system_theme_settings_alter to add custom settings to a theme. One setting is the text string (e.g. 'Menu') to display beside ...
4
votes
1answer
81 views

Benefit of config entities over regular config entries?

In Drupal 8 it is possible to store configuration in "config entities". However, the same can also be achieved with non-entity config entries. E.g. one example for a config entity schema, from core....
4
votes
1answer
1k views

Configuration changes that will not import?

I have some configuration that will not import. If I run drush config-import --preview I see the changes to be imported; I hit 'y' to import. When I run the same command, the changes are still there? ...
3
votes
0answers
336 views

Update schema.yml variable type: string to integer

I would like to update my module schema variable from string to integer. mymodule.settings: type: config_object label: 'Module settings' mapping: identity: type: string -> integer ...
3
votes
2answers
545 views

Overriding permissions selectively via settings.php/settings.local.php

The use case is a development module that you would only have installed on a local environment. My thought was to use $config in settings.php to do this: $config['user.role.anonymous']['permissions']...
2
votes
1answer
60 views

How can I programmatically import configuration?

I try to import specific configuration. I use this : $config_path = config_get_config_directory(CONFIG_SYNC_DIRECTORY); $source = new FileStorage($config_path); $config_storage = \Drupal::service('...
2
votes
0answers
218 views

Configuration sync with deleted field

I have a field field.storage.node.field_create_ic created with type 'calendar_download_type' and it is one of the contributed module (ics_field). Now, in my local environment I deleted the field and ...
2
votes
1answer
466 views

Overriding system.site.uuid with an environment variable

I have a need to have separate sites behave as if they are clones of each other; that is, they each need to have the same site UUID. Due to the environment I am operating in, I am unable to change ...
2
votes
0answers
192 views

Exported field collection field has null UUID

In D8, I have a configuration management error. I have created a field named 'field_icon_link' of type “Field Collection”. I export my config. If I try to import this config I get a UUID error. ...
2
votes
0answers
149 views

What does a 'reset' refer to with Drupal?

In the docs for the State API, the term 'reset' is used, without any reference as to what a reset is: use State API to store transient information, that is okay to lose after a reset. I've spent ...
2
votes
1answer
851 views

TypeError on “drush config-export”

I've been receiving the following error message when trying to do a drush config-export command. However, I am able to successfully do the configuration export from the Drupal admin page (admin/config/...
2
votes
2answers
541 views

Can a domain redirect work for both http and https?

Currently hosting a site on Pantheon and I would like to redirect traffic to a single domain. There is already a lot of links inside my site that are using: http://example.com/somepage, http://www....
2
votes
3answers
91 views

Session is not getting maintain in settings.php drupal 7

I have Created one php file on root of drupal7 and access it using URL.I have one form in that file which has dropdown values and submit button. Now in settings.php i am getting those value in POST. ...
2
votes
1answer
137 views

logging in after exiting website under maintenance

i was installing updates for drupal website, while on maintenace mode. waited for updates to finish and then signed out. i've been trying a lot of things i'm reading online and it doesn't work. on ...
2
votes
1answer
166 views

Configuration Management Module Keeps Saying 'needs attention'

I've just started using the configuration module to keep my Drupal database in sync between my development and live environments. Documentation for this module is sparse, and I'm trying to understand ...
2
votes
0answers
1k views

How to optimize the unserialization of “variables” cache value

As we all know, the whole variable table is being cached in the drupal cache system and is being extracted into global $conf variable in each invoke. In one of our production site with the domain ...
1
vote
0answers
31 views

How to log configuration changes in a sensible way?

In order to log simple configuration changes like a site-name change, contributed modules like contrib_log work fine. It just diffs the changes files in active configuration and logs it. But when ...
1
vote
0answers
30 views

Where to describe a State API variable?

We can describe the configuration variables in the *.schema.yml files but there is a place to describe the State API variables? I searched in the Core for some State variables and I don't find a ...
1
vote
1answer
32 views

Contact email flood limit is per whole system(application) or user/ip based?

I have a question with contact emails flood limit which is present in contact.settings.yml, the limit is going to for whole system(application-wide) or is it going to limit the number of emails per ...
1
vote
1answer
28 views

How to delete paragraph when uninstalling the module?

I have been creating the custom module which have the paragraph configuration, when installing the custom module, the paragraph config will be stored in the database and then It will be available in ...
1
vote
1answer
479 views

How to check for differences in config

Is there any way to check for differences with config in Drush? I checked the list of drush 8 config commands and I couldn't find anything. The reason I need this is that I have a site that runs ...
1
vote
0answers
100 views

Difference between field and field storage in configuration type?

I am exporting a content type and field associated with the synchronize option available in Drupal 8. I exported and imported the YAML code for content type successfully. When I was about to do the ...
1
vote
0answers
102 views

Prevent block config from being exported?

In Drupal 8, how can I prevent block instance config from being exported? I want it to just be ignored.
1
vote
0answers
207 views

Add permission to existing role in custom module using configuration

Permissions may be added to existing roles programatically as described in this answer. However, I would like to put that into configuration. I can create a role calling king by putting user.role....
1
vote
0answers
135 views

Properly export text format and editor settings

I'm trying to export the CKeditor settings and restricted_html settings but it's partially imported in the end. I'm exporting the editor.editor.restricted_html.yml and the filter.format....
1
vote
0answers
36 views

Drupal 8 config yml differences due to ordering/positioning of elements

Got a really annoying thing related to config-import/export, due to the positioning of elements in the yml file the config never syncs between production server and development server. For example: ...
1
vote
1answer
188 views

PHPUnit Test run Error with ConfigFactory

I'm running an error with the following test I wrote including some config. I don't know if my test is even properly written so any advice in improving that code is welcomed. Since my test is not ...
1
vote
0answers
89 views

How to Add a Default Prefix into the Acquia Dev Desktop Settings

I'm using Acquia Dev Desktop for my local Drupal 7 development. All of the tables in my sites are prefixed with "dr_". Whenever I create or import a site, I have to manually change the settings to ...
1
vote
0answers
242 views

How can locally deleted fields also be deleted on production?

We are using D8's Configuration Management for our site. When we delete fields in our local development environment the corresponding content type and field yml files are updated to reflect the change....
1
vote
1answer
959 views

Config import constantly showing configs to import

Recently after doing a config import via drush (drush cim sync), the config files don't seem to import properly, as the files are listed after a supposed successful import. (and doing a cex sync shows ...
1
vote
2answers
426 views

Unable to save content language configuration

My Drupal 8 website is multilingual and has many entity type bundles for nodes, taxonomy terms, paragraphs, media et cetera. This leads to a content language settings form (admin/config/regional/...
1
vote
0answers
670 views

How should I solve a module load order problem in a custom install profile?

I'm building a custom install profile for Drupal 8.4. It uses the new core Media module, and includes custom config files for the entity forms for media's image and file entities. One of those changes ...
1
vote
1answer
192 views

Where is list of theme features in Drupal 8 that can be exposed on the “Settings” page?

In my theme.info.yml file, I can expose features to show up in the settings of my theme. It's documented here: drupal.org theming features: - comment_user_verification - comment_user_picture - ...
1
vote
0answers
474 views

Using config split to keep dev modules separate: how to manage enabled/disabled states?

I'm using the config split documentation to exclude dev module configuration on my site. I made a configuration split that blacklists the following modules: Devel Kint Field UI Menu UI Views UI I ...
1
vote
0answers
177 views

How to map (yml) D7 nodes with terms, images, comments and references for migrating to D8?

To better understand how a custom content migration really works apart from all the tutorials showing how to install Drupal and press the migrate button with a 3 lines test import file or endless ...
1
vote
0answers
1k views

PHP OPcode caching: Not enabled

I am new to everything Drupal, when trying to start my site under Verify Requirements Drupal 8.2.2 the following error shows: PHP OPcode caching Not enabled PHP OPcode caching can improve your site'...
1
vote
1answer
57 views

Feed content type field with configuration value

I have a config form with several config variables where i save some user preferences like «position» or «weight» Now, at the moment of generating a content type i want to feed a select field with ...
1
vote
0answers
21 views

How do I store editor-configurable snippets of configuration?

The Drupal 8 site I'm building contains some custom forms and pages. On those pages, bits information are inserted that must remain editable by the site editors. In D7, I would probably have used the ...
1
vote
0answers
79 views

Creating config entities in a functional browser test

I am extending Drupal\Tests\BrowserTestBase to create a functional test which attempts to edit and save a config entity. Creating this via MyEntity::create($data)->save(); has weird effects: They ...
1
vote
1answer
213 views

Unable to install lullabot/amp and sensiolabs/security-checker

i have installed amp and composer manager today i have been trying to get lullabot/amp installed, i have managed to install composer and drush on my computer but im not sure if they have been ...
1
vote
0answers
68 views

Rebuild config module

I have create file config in a module /custom /module_name /config /install /module_name.settings.yml this is ...
1
vote
0answers
392 views

Change existing field definition

I have Drupal8 site where client suddenly wanted to change some field from 2 decimal scale to 3. To X.XXX that is. Now I'm aware that changing field definition when there's stuff in db is not ...
1
vote
0answers
8 views

Why can I not see a field which depends on two other fields related by the OR operator?

I'm using the Conditional Fields module and I have a field that I can set while editing my custom content type. That field is dependent to two other fields which are related by the operator OR. The ...
1
vote
0answers
465 views

How to use third party settings to store an array of values

I'm making a module and almost complete, but I can't seem to get third party settings to save. Here is my schema.yml: editor.editor.*.third_party.ckeditor_styles: type: mapping label: 'CKEditor ...
1
vote
1answer
236 views

Revert configuration languages overrides

Suppose you have a Drupal 8 multi site installation, with multi language support, and a custom module used across multiple sites. This module has a view, with the yml file in: custom_module/config/...
1
vote
1answer
43 views

Using variables in Drupal

Would appreciate any assistance of how to handle configurable URLs for each environment. The links need to take the user to a different URL depending on the environment the site is installed in. In ...
1
vote
0answers
158 views

Change block configuration before render the block programmatically

I have a view that display some nodes and some of this nodes have a menu voice connected to them with sub menus. main menu: -node 1 [mid:407] --node 2 --node 3 -node 4 [mid:219] --node 5 I want ...
1
vote
0answers
37 views

Define config schema on an installation profile

I have a custom installation profile, which has a profiles/foo/config/install/foo.settings.yml. I try to declare a schema in profiles/foo/config/schema/foo.schema.yml but it seems that file is not ...
1
vote
1answer
229 views

Provide default site uuid on install

Can I provide default site's uuid static in Drupal 8. I am using docker with Drupal 8 and during configurations import the site is rebuild with docker resulting in different uuid each time. After that ...
1
vote
0answers
41 views

D8: Multilingual configuration and dynamic content

I'm currently working on a multilingual Drupal 8 project that also takes advantage of D8's new CMI system (Buzzwords: Content Manangement Initiative). Is there some sort of best practice here? I ...