Code Guide 2018/10/16

Installation directions in the development environment

  1. Clone the repository to a folder in the development server
  2. Create a virtual host in the web server pointing to the public folder where the repository was cloned to. Example for Windows Wampserver:

    <VirtualHost *:80>
    ServerName devel.hitachi-web.com
    DocumentRoot c:/wamp/www/hitachi-web/public/
    <Directory  "c:/wamp/www/hitachi-web/public/">
    Options +Indexes +Includes +FollowSymLinks +MultiViews
    AllowOverride All
    Require local
    </Directory>
    </VirtualHost>
  3. Set up a DNS for the created vhost
  4. Create a mysql database
  5. Create an .env file from the .env.example file included in the repository (you can find the explanation for the variables in the .env file later in this document)
  6. From the command line, from the repository folder, run:

    composer config -g bitbucket-oauth.bitbucket.org TcwyUpPHeJnRA2tbtC matQb8CdEBEm85QYMjPJDLb78uL5LZYF
    (sets up composer with the keys to access the private Bitbucket repository)

    composer install
    (installs the necessary dependencies in the /vendor folder)

    php artisan migrate:refresh
    (creates the DB tables and fills them out with master data)

    npm install
    (installs the necessary javascript dependencies in the /node-modules folder)

    npm run dev
    (compiles css and js assets)

    php artisan storage:link
    (creates a link in /public/storage pointing to /storage/app/public, which is the folder where files are stored via admin so they can be accessed via front-end)

The default user to access the administration panel is:
User: admin@test.com
Password: admin