devowl-wp

devowl.io Workplace

Getting started

Installation is done for you as soon as you open the terminal within VSCode.

Prepare environment

All environment variables and secrets are loaded via Envkey. To get access to your Envkey account, please follow this steps:

If you need help setting up your environment please contact a Devop!

  1. Contact a Devop (e.g. Matthias G√ľnter) to get an invitation to Envkey
  2. Download and open the Envkey UI (downloadable via the website of Envkey)
  3. Accept the invitation so you have access to the devowl.io Gmbh organization within Envkey
  4. Create a file .env in the root of our cloned Git repository (do not save the file until we explicitely request this!)
  5. Copy the content of .env-default into the .env file
  6. Now, we create the first ENVKEY secret, which allows us to access the Envkey vault:
    1. Open the App Monorepo (Global) in Envkey UI
    2. Open the tab ENVKEYs
    3. Scroll down to Local Development Keys and create your key with name ci-runner-x.owlsrv.de (replace x with your runner number!)
    4. After creation copy the ENVKEY secret to your .env file (make sure to remove the ENVKEY= from the copied content to avoid something like ENVKEY_REAL_COMMERCE=ENVKEY=)
  7. Repeat this for all other ENVKEY_ variables within your .env for the proper app in Envkey, e.g. ENVKEY_REAL_COMMERCE belongs to the Real Commerce app.
  8. Now, we need to create required local overrides for your remote machine
    1. Open the App Monorepo (Global) in Envkey UI
    2. Open the tab Environments
    3. Left to the Development environment click the branch icon
    4. On the right side add the variable ENVIRONMENT_BASE_HOSTNAME with value ci-runner-x.owlsrv.de (replace x with your runner number!)
  9. Save the .env file

How to access the services?

Open the Traefik monitor at port 8080 to see the domains of all services (e.g. http://ci-runner-8.owlsrv.de:8080/).

Commands

Some often-used commands are provided via the native VSCode tasks view. Just open the Command Pallete, delete the > character and type in task (with space!). All other commands are available in the package.json#scripts section.

Domain prefixes of services

Each domain prefix must be prefixed to the FQDN of the host running the containers (e.g. host ci-runner-x.owlsrv.de and domain prefix commerce becomes commerce.ci-runner-x.owlsrv.de).

Description Environment Docker service Domain prefix
WordPress Plugins Development wordpress wordpress.
Real Product Manager (Backend) Development real_product_manager license.
Real Commerce (Backend) Development real_commerce commerce.
Real Cookie Banner (Backend) Development real_cookie_banner_backend rcb.
phpMyAdmin Development phpmyadmin pma.
phpRedisAdmin Development phpredisadmin pra.

Available package workspaces

Package type Allow side effects* Description
dev-packages No Packages, which are needed only for development purposes within this monorepo
api-packages No API interfaces and types, which can be consumed by backends and frontends
backend-packages No Logic, which can be consumed by backends
wordpress-packages No WordPress-specific packages with PHP and TS coding which can be consumed by wordpress-plugins
frontend-packages No Logic, which can be consumed by different types of frontends in different ecosystems
isomorphic-packages No Logic, which can be consumed anywhere and independent of the ecosystem (e.g. package provides logic for PHP and JavaScript) with feature-parity
frontends Yes Dockerized frontends (e.g. create-react-app)
backends Yes Dockerized backend services
wordpress-plugins Yes WordPress-specific plugins with PHP and TS coding

* Side effects: A side-effect free file does not execute code at import time, instead it only exports types, interfaces and reusable components. A side effect e.g. is starting a webserver in the main file.

Generated using TypeDoc