Commit 9086de84 authored by Sandeep Kadam's avatar Sandeep Kadam

Updated code comments to be more specific

parent c8c442d4
......@@ -32,7 +32,7 @@ function usage {
echo " ssh [command]";
echo " optional [command] can be shell command to run, otherwise will be interactive shell";
echo "";
echo " quick - Generate production wordpress site on local, spin up docker,";
echo " quick - Generate production wordpress site on local with production DB & files, spin up docker,";
echo " initialise solr (if enabled), login in browser";
echo "";
echo " quick_blank - setup basic wordpress installation, spin up docker,";
......@@ -127,6 +127,7 @@ case "${COMMAND}" in
rm -f ${WP_SETTINGS_PHP} || true
;;
# To create production website on local
quick)
${ROOT}/bin/dump sql $*;
${ROOT}/bin/dump files $*;
......@@ -144,9 +145,8 @@ wp config set WP_HOME $SITE_URL";
${ROOT}/bin/dev login;
;;
# To create empty blank wordpress site on local
quick_blank)
${ROOT}/bin/dump sql $*;
${ROOT}/bin/dump files $*;
${ROOT}/bin/dev up;
DOCKER_URL=${PROJECT_NAME}.docker.localhost;
DOCKER_PORT=$(docker-compose port traefik 80 | cut -d: -f2);
......@@ -187,7 +187,7 @@ wp config set WP_HOME $SITE_URL";
# internal only function to wait for db import for complete
db_wait)
if [ -f ${LOCAL_CORE_PATH}/${RELATIVE_SQLDUMP_SRC}/* ] && [ ! -d ${LOCAL_CORE_PATH}/${RELATIVE_SQLDATA_SRC}/${DOCKER_DATABASE} ]; then
if [ -f ${LOCAL_CORE_PATH}/${RELATIVE_SQLDUMP_SRC}/* ] || [ ! -d ${LOCAL_CORE_PATH}/${RELATIVE_SQLDATA_SRC}/${DOCKER_DATABASE} ]; then
echo "Please wait for database to import...";
# wait for drupal database to start importing
echo "Waiting for ${LOCAL_CORE_PATH}/${RELATIVE_SQLDATA_SRC}/${DOCKER_DATABASE} to be created";
......
......@@ -33,14 +33,13 @@ THEME_HEADER="vf_ebi_global_header"
THEME_FOOTER="vf_ebi_global_footer"
##############################################
# you shouldn't need to edit below this line
# you shouldn't need to edit below this line #
VM_CORE_PATH=/var/www/html
APACHE_DOCUMENT_ROOT=/var/www/html/dist
# repo specific paths
# Required all below config for repo specific paths for local development & folder creation for site setup
LOCAL_CORE_PATH=.
RELATIVE_DOCUMENT_ROOT=dist
RELATIVE_FILES_SRC=_files
RELATIVE_SQLDUMP_SRC=_sqldump
......@@ -48,14 +47,16 @@ RELATIVE_SQLDATA_SRC=_sqldata
RELATIVE_TEMP_SRC=_temp
USER_FILES=${RELATIVE_DOCUMENT_ROOT}/wp-content/uploads
USER_FILES_SYMLINK=../../${RELATIVE_FILES_SRC}
WP_SETTINGS_PHP=${RELATIVE_DOCUMENT_ROOT}/wp-config.php
WP_DEFAULT_SETTINGS_PHP=${RELATIVE_DOCUMENT_ROOT}/wp-config-sample.php
# Required for Local group site setup
### Required only for Local group site (microsites) setup ###
WP_SOURCE_THEMES_PATH=${LOCAL_CORE_PATH}/wp-content/themes
WP_SOURCE_PLUGIN_PATH=${LOCAL_CORE_PATH}/wp-content/plugins
WP_DEST_THEMES_PATH=${RELATIVE_DOCUMENT_ROOT}/wp-content/themes
WP_DEST_PLUGIN_PATH=${RELATIVE_DOCUMENT_ROOT}/wp-content/plugins
# docker specific details, used in docker-compose.yml
# docker specific details, used in docker-compose.yml for local development
DOCKER_DATABASE=docker
DOCKER_DATABASE_USER=docker
DOCKER_DATABASE_PASS=docker
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment