Drupal Server Administration

Опубликовано
chesser
-
чт, 02/11/2021 - 13:16

Prepare system OS

yum update
yum install php-cli php-common php-fpm php-gd php-json php-mbstring php-mysqlnd php-opcache php-pdo php-xml

Install composer

php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
wget -q  https://composer.github.io/installer.sig
sha384sum composer-setup.php
php composer-setup.php --install-dir=/usr/local/bin --filename=composer
rm composer-setup.php installer.sig

Drupal Installation

cd www
composer create-project drupal/recommended-project new_drupal_folder
cd new_drupal_folder/web/sites
cp example.sites.php sites.php
mkdir -p drupal-site.com/files
chmod 777 drupal-site.com/files
cp default/default.settings.php drupal-site.com/settings.php
chmod 666 drupal-site.com/settings.php
echo -e "\n\$settings['trusted_host_patterns'] = [\n  '^'.\$_SERVER['HTTP_HOST'].'$'\n];" >> drupal-site.com/settings.php

Web installation process.....

chmod 644 drupal-site.com/settings.php

https://www.drupal.org/docs/develop/using-composer/using-composer-to-in…

Drupal Update

https://www.drupal.org/docs/updating-drupal/updating-drupal-core-via-co…

composer update drupal/core "drupal/core-*" --with-all-dependencies

Module Installation

composer require drupal/backup_migrate

composer require drupal/backup_migrate:5.*

composer --dry-run require drupal/backup_migrate:5.*

Теги