38 votes

Order of drush commands for automated deployment?

Drush 10.3.0 now provides a deploy command to standardize how Drupal deployment works. This command performs the following: drush updatedb --no-cache-clear drush cache:rebuild drush config:import ...
leymannx's user avatar
  • 18.1k
10 votes

How can I deploy user interface translation?

Helper function to add custom translations: /** * Helper to manually add a single translation string. * * @param string $source_string * Source string. * @param string $langcode * The ...
milkovsky's user avatar
  • 5,334
5 votes
Accepted

Best practice to deploy an update which depend of a new configuration

I would recommend that you create the field programatically. In your update function. You could also create multiple update functions, just create the field in one, then migrate the data then remove ...
Berdir's user avatar
  • 83.2k
4 votes

How do I deploy a local site?

There are many ways to migrate a local site to a server. Here are a few of the most common. SFTP/FTP is one way, you can "manually" move all the files up to the server and use PHPMyAdmin to import ...
Sam's user avatar
  • 603
4 votes

Order of drush commands for automated deployment?

The sequence of commands should be: updatedb (which runs update hooks) config-import You do not want to run entity-updates because it is deprecated, see https://www.drupal.org/node/3034742. Instead, ...
josephdpurcell's user avatar
4 votes
Accepted

How to deal with config changes in prod and by multiple developers?

Good use of git branching can definitely help with this. The key thing is that each individual branch has a stable configuration basis: nothing external to the branch should change the configuration ...
Les Lim's user avatar
  • 2,388
3 votes

Order of drush commands for automated deployment?

Here is our CI script, quite the same :) drush cr git pull composer install # drupal console enforce modules are enabled before any config is installed drupal config:import:single --directory="...
Rafael's user avatar
  • 329
3 votes

How can I deploy user interface translation?

For our project, we wrote a custom module with .po files in a subfolder. These are loaded by the Drupal 8 localization system using a few lines of code in the .info.yml. 'interface translation ...
bwaindwain's user avatar
3 votes
Accepted

Cloning a Drupal website without content

Have a look at Config Installer. It allows you to the initial install already based on your exported configuration and so replaces step 2 and 3. One problem is that you might notice that there is ...
Berdir's user avatar
  • 83.2k
3 votes

what is the use of universal unique identifier ,why its so much important in deployment?

UUID is used to identify the same objects (like nodes, taxonomy_terms and users) across environments. All of these has an ID, for nodes it's the nid (node id), but that is not reliable to use across ...
googletorp's user avatar
  • 35.4k
3 votes

Syncing Development Site with Production Site

You simply need to sync the database and the whole complete Drupal folder. Every single file except for .htaccess and settings.php as they may be different in every environment. And from now on you ...
leymannx's user avatar
  • 18.1k
3 votes
Accepted

How do you display a version number on a footer file?

One way I do it is to commit a text file and then check that live. This can be done while building the project in CI. Here is an example (note your CI variables may vary): In one of the final steps ...
Kevin's user avatar
  • 27.8k
3 votes
Accepted

All pages give 404 using nginx

Nginx can’t process htaccess files without a specific extension installed. You either need to install that extension or manually configure nginx to work with Drupal. There’s an example config here if ...
Clive's user avatar
  • 167k
3 votes

Azure web services does not remove index.php from URL

Start with the Drupal configuration for NGINX. NGINX’s default configuration requires modifications to run Drupal.
cilefen's user avatar
  • 5,967
2 votes

How to sql-sync database between two remotes which share the same host?

Another option I use is to use drush ssh command to execute drush on the source : drush @source ssh "drush sql-sync @self @destination"
Grubshka's user avatar
  • 287
2 votes

How can I deploy user interface translation?

It looks like it should also be possible to do this by writing a script to run commands from Drush locale sync, although I haven't tried that module myself.
bdsl's user avatar
  • 121
2 votes

Using 2 code repos, one Acquia and one private gitlab server for Drupal code base tracking

Definitely possible and it's what I do. Acquia provides some documentation on this. As Kevin mentioned you can do this by setting up two remotes for your local repository clone, one at GitHub/GitLab/...
StevenGFX's user avatar
2 votes
Accepted

Best method of pushing content changes that contains paragraph fields from dev to production?

One recommendation is to use "Features" to generate: a Feature export of any config changes to the content types, paragraph bundles, and fields a separate Feature export of the content/nodes ...
Anson W Han's user avatar
  • 1,252
2 votes

Order of drush commands for automated deployment?

If you need to import custom translations too make sure to run a drush cim afterwards importing as some of the lables are translated in config and some in the po files. At moment our update job looks ...
macbert's user avatar
  • 363
2 votes
Accepted

Create configuration storage programmattically for list_string

I finish by find what was the problem. When I read the config file, my allowed value are of format: [ [ 'value' => 'anchor', 'label' => 'Anchor' ], [ 'value' => 'internal', ...
Claire D's user avatar
  • 656
1 vote

How to deploy a site?

I had faced this problem a while ago. After lot of research, I found that running composer install from the site root resolves any problem.
Sensimple's user avatar
  • 106
1 vote
Accepted

How to keep Drupal site code in version control in sync with production code when using drush updates on servers?

You really have two options: Assuming you are deploying code to your test server by cloning your code base from a service like github then you can always go in the reverse direction for security ...
bleen's user avatar
  • 1,500
1 vote

How to change relative path in hyperlinks?

You may need to: Check the setting for RewriteBase in .htaccess (e.g make RewriteBase /) Check the $base_url setting is correct (Should be automatic in D8). Clear all caches ( Admin > Config > ...
David Thomas's user avatar
  • 21.9k
1 vote

Lock configurations

You could have a look at the drush CMI tools recently published by PreviousNext: https://www.previousnext.com.au/blog/introducing-drush-cmi-tools That allows you to have exclude patterns of certain ...
Berdir's user avatar
  • 83.2k
1 vote

Lock configurations

What you can do is to use --skip-modules if you sync configuration with drush. You can even put it in a drushrc file so you don't need to remember it. Doing will will make drush skip the sync of the ...
googletorp's user avatar
  • 35.4k
1 vote

how to deploy from dev to staging and production?

Any deployment strategy can be broken down primarly into three main streams Content(Node,taxonomies etc.) Code Configuration(Content types, Vocabularies etc.) Content Deployment I am assuming you ...
arpitr's user avatar
  • 7,836
1 vote
Accepted

Environment dependend workflow with configuration management

Drupal 7 Have you considered adding some intelligence to settings.php? You could test $_SERVER['HTTP_HOST'] there, and set $conf['some_variable'] accordingly. Below are some examples from Pantheon. ...
netgenius.co.uk's user avatar
1 vote
Accepted

How do I debug connection problems while testing Deploy module while using local host?

There are few issues with your examples. You're missing routing-script for the built-in PHP web server. It's recommended to use since you're using PHP built-in web server and by default it may have ...
kenorb's user avatar
  • 14.2k
1 vote

Why don't I get any CSS after deploying my Drupal site?

Be sure to check the logs at /admin/reports/dblog . In some cases, permission errors will not be available at /admin/reports/status , but they do show up on the log. In particular if you are getting ...
HongPong's user avatar
  • 272

Only top scored, non community-wiki answers of a minimum length are eligible