-
Notifications
You must be signed in to change notification settings - Fork 0
Setting up a Drupal 8 site
Deploying a site with Deployer will setup shared files and folder automatically.
The deployment path, in the deployer script (dep.php
), should be set at /usr/share/nginx/html/mynewsite
.
On first deployment, deployer will setup a directory structure like:
- mynewsite
|- releases
|- current (symlink to latest release)
|- shared
|- |- sites
|- |- |- default
|- |- |- |- settings.php
|- |- |- |- services.yml
|- |- |- |- files
In the following sections, each file and folder in the shared folder will be addressed.
An empty settings file is setup.
Copy the default.settings.php
from the sites/default
folder and make it writeable by Drupal.
Same as the settings.php, only it won't have to be writeable.
The files folder in the shared folder, will most likely not be used. If set up properly, the Docker configuration for the site, should use a data volume for the files folder, like:
- mynewsite_files:/var/www/html/sites/default/files
If the site being set up, is not a new site, a file directory should probably be copied into the data volume.
To do this, copy the tarball of the files folder, into the running Docker container.
docker cp files.tar.gz mynewsite.site:/var/www/html/sites/default/files
Now enter the container, and extract the tarball in the files directory.
docker exec -ti mynewsite.site bash
cd /var/www/html/sites/default/files
tar -zxvf files.tar.gz
rm files.tar.gz
cd ..
chmod -R 777 files