Skip to content

roadiz/core-bundle-dev-app

Repository files navigation

Roadiz development monorepo

Unit tests, static analysis and code style Packages Split

This is development app for Roadiz v2. It aggregates all Roadiz bundle and main repositories in one place.

Install

  • Clone this repository containing all monorepo packages in lib directory
  • Deploy bundles assets to public folder: bin/console assets:install --relative --symlink
  • Deploy legacy themes assets to public folder: bin/console themes:assets:install Rozier --relative --symlink

Generate JWT private and public keys

# Generate a strong secret
openssl rand --base64 16; 
# Fill JWT_PASSPHRASE env var in .env.local.
openssl genpkey -out config/jwt/private.pem -aes256 -algorithm rsa -pkeyopt rsa_keygen_bits:4096;
openssl pkey -in config/jwt/private.pem -out config/jwt/public.pem -pubout;

Run development server

  • Run docker-compose env to get a local database and Solr server
  • Run symfony serve

Manual configuration

These require a manual configuration in config/packages/*.yaml files and cannot be injected in Container, you'll find configuration example in RoadizCoreBundle/config/packages and RoadizCompatBundle/config/packages folders:

  • Doctrine ORM mapping
  • Doctrine migrations path
  • JMS Serializer naming strategy
  • Monolog custom doctrine handler
  • Roadiz security scheme

Run tests

make test

Note that phpstan can issue wrong errors if your lib/* bundles are symlinked.

Monorepo tools

Roadiz development env uses: https://github.com/symplify/monorepo-builder

  • vendor/bin/monorepo-builder merge: Makes sure all your packages deps are in development repository and
  • vendor/bin/monorepo-builder validate: Make sure all your packages use the same version
  • vendor/bin/monorepo-builder release patch --dry-run: List all steps to do when release a new tag (do not actually perform this when using GitFlow)