New project structure #6

Merged
akrdzic merged 24 commits from new-project-structure into master 2018-07-31 13:43:29 +02:00
akrdzic commented 2018-07-30 19:09:38 +02:00 (Migrated from gitlab.com)

New project structure for wordpress backend

https://app.asana.com/0/697944902557002/762876339942279

New project structure based on Bedrock project structure.
This approach enables:

  • Better folder structure
    • wordpress core is in separate folder and is treated as dependency
    • separate environment config file for non sensitive wordpress config (ex: SCRIPT_DEBUG, DISALLOW_FILE_MODS)
    • dedicated plugin folder for dev team under version control management (wiaas)
  • Dependency management with Composer (wordpress core and plugins)
  • Environment variables with Dotenv
  • Enhanced security (all sensitive information is accessed with environment variables)
  • Composer as task runner for automatic wordpress db updates

Go to project README file for detailed description.

NOTICE

This PR requires update to deployment procedure since it includes new environment variables.

SMOKE TEST

  1. Check if docker works as before

    1. Copy provided environment.env file to .env file and update environment variables

    2. Execute

    docker-compose build && docker-compose up
    
    1. Go to http://localhost:8081 and check wordpress admin is avaialable and has following plugins activated:

      'jwt-authentication-for-wp-rest-api', 'groups', 'woocommerce-jetpack'

      Also check under woocommerce booster settings that 'Product Visibility by User Role' is enabled

    2. Go to http://localhost:8080 and check that you can login as wordpress administrator user.

  2. Check that local development works as before

    1. Copy provided environment.env file to development.env file and add your environment variables

    2. Execute

    cd backend && composer install && composer update-db
    
    1. Point your apache web server to backend directory and copy .htaccess from docker/php to backend folder

    2. Test that wp admin is available on your desired url and has following plugins activated:

      'jwt-authentication-for-wp-rest-api', 'groups', 'woocommerce-jetpack'

      Also check under woocommerce booster settings that 'Product Visibility by User Role' is enabled

    3. Run frontend application to point to your local url and check that you can login as wp admin.

**New project structure for wordpress backend** https://app.asana.com/0/697944902557002/762876339942279 New project structure based on [Bedrock](https://roots.io/bedrock/) project structure. This approach enables: - Better folder structure - wordpress core is in separate folder and is treated as dependency - separate environment config file for non sensitive wordpress config (ex: SCRIPT_DEBUG, DISALLOW_FILE_MODS) - dedicated plugin folder for dev team under version control management (wiaas) - Dependency management with Composer (wordpress core and plugins) - Environment variables with [Dotenv](https://github.com/vlucas/phpdotenv) - Enhanced security (all sensitive information is accessed with environment variables) - Composer as task runner for automatic wordpress db updates Go to project *README* file for detailed description. **NOTICE** This PR requires update to deployment procedure since it includes new environment variables. **SMOKE TEST** 1) Check if docker works as before 1) Copy provided *environment.env* file to *.env* file and update environment variables 2) Execute docker-compose build && docker-compose up 3) Go to http://localhost:8081 and check wordpress admin is avaialable and has following plugins activated: *'jwt-authentication-for-wp-rest-api', 'groups', 'woocommerce-jetpack'* Also check under woocommerce booster settings that *'Product Visibility by User Role'* is enabled 4) Go to http://localhost:8080 and check that you can login as wordpress administrator user. 2) Check that local development works as before 1) Copy provided *environment.env* file to *development.env* file and add your environment variables 2) Execute cd backend && composer install && composer update-db 3) Point your apache web server to *backend* directory and copy *.htaccess* from *docker/php* to *backend* folder 4) Test that wp admin is available on your desired url and has following plugins activated: *'jwt-authentication-for-wp-rest-api', 'groups', 'woocommerce-jetpack'* Also check under woocommerce booster settings that *'Product Visibility by User Role'* is enabled 5) Run frontend application to point to your local url and check that you can login as wp admin.
akrdzic commented 2018-07-30 19:10:08 +02:00 (Migrated from gitlab.com)

assigned to @bilal.catic

assigned to @bilal.catic
akrdzic commented 2018-07-30 19:14:26 +02:00 (Migrated from gitlab.com)

changed the description

changed the description
akrdzic commented 2018-07-31 13:41:27 +02:00 (Migrated from gitlab.com)

changed the description

changed the description
bilal.catic commented 2018-07-31 13:43:29 +02:00 (Migrated from gitlab.com)

merged

merged
bilal.catic commented 2018-07-31 13:43:44 +02:00 (Migrated from gitlab.com)

mentioned in commit 158a3a97ad

mentioned in commit 158a3a97adfcf5643a0e124a14619c1ff91917fe
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: senaduka/old-new-wiaas#6