Skip to content

Latest commit

 

History

History
53 lines (40 loc) · 2.59 KB

initial-setup.md

File metadata and controls

53 lines (40 loc) · 2.59 KB

Initial Setup

Source code

All source code is available on the GitHub project page.

Setup with Vagrant (in progress)

CultuurNet Vlaanderen vzw offers a ready-to-go setup with Vagrant which resembles the test and production environments the most. We recommend using this Vagrant box. Get in touch with CultuurNet Vlaanderen vzw to get access to the Vagrant box.

Setup on your own hosting stack

You will need a web server (for example Apache or Nginx) with at least PHP 5.6.

Web server requirements:

Steps:

  • Git clone the source code.
  • Install the dependencies with composer install.
  • Set the web directory as the document root in your web server configuration.
  • Configure your web server to rewrite all requests that do not match with an existing file, to index.php. If you are using Apache, the .htaccess file already takes care of this.
  • Copy config.dist.yml to [config.yml] and adapt to your needs.
  • Run following command in your terminal ./bin/console orm:schema-tool:create --force

Configuration

config.dist.yml contains an example configuration you can use to kickstart your own config.yml. If you need to know what the intention of a particular configuration setting is, look in here for the documentation.

Console commands

A console is provided in the application. This can be used to run certain silex commands. Most important ones:

  • projectaanvraag:consumer: Run this command if you want to consume messages on your rabbit mq. This is used to handle events async.
    • If you have supervisor. This is the required command that should be run.
    • If you have no supervisor: Make sure you run this command after you executed code that throws an event
  • orm:schema-tool:update: Run this command to show what sql is needed to update your DB to latest version. Use the --force flag to execute that query.
  • orm:schema-tool:create: When this is your first time running the project.
  • sync-consumers live test: Run this command to synchronize the local consumers with their CultureFeed API counterparts. test and live are the possible arguments for this command. The command can be run with only one of these present. This will create asynchronous events for processing on the RabbitMQ queue.