Skip to content

Production Setup ARCHIVED

Koen Teuwen edited this page Jul 16, 2021 · 1 revision

Production installation

  • Clone the repository.
  • Install dependencies using composer: php composer.phar install
  • Create a new MySQL database.
  • Copy config/autoload/doctrine.local.production.php.dist to config/autoload/doctrine.local.php and configure the database settings in it.
  • Give the webserver's user read and write permissions to the data/ and public/data/ directories.
  • Run ./web orm:schema-tool:create to populate the database.
  • Copy config/autoload/local.php.dist to config/autoload/local.php
  • Run php composer.phar install -o to generate a composer classmap
  • Run genclassmap.sh to generate module class maps
  • Set the environment variable APP_ENV to production in your webserver configuration
  • Set a cronjob for generating the photo of the week 0 0 * * 1 ./web photo weeklyphoto >/dev/null 2>&1
  • Set a cronjob for OASE updates
  • run ./web orm:generate-proxies

Upgrading

After upgrading to a new version complete the following steps (not all steps may be required)

  • Run php composer.phar install -o to generate a composer classmap
  • Run ./genclassmap.sh to generate module class maps
  • Run ./web orm:schema-tool:update (if needed)
  • Run ./web orm:generate-proxies
  • Update the css files (if needed)
  • Clear PHP's APC cache. (if enabled) (you can use apc_clear_cache(); and apc_clear_cache('web'); in php interactive mode, ran by php -a)