Skip to main content

Local Setup

Before you start

tip

You can use the pre-configured devcontainers in the .devcontainer directory to get started quickly.

You will need:

Getting started

  1. Clone the repository

    git clone git@github.com:dvsa/vol-app.git
  2. Change into the project directory

    cd vol-app
    warning

    If you are resetting the database you will need to be be authenticated with the AWS VOL nonprod account.

    If you have the ZSH AWS plugin installed & configured, you can run the following command to get temporary credentials:

    acp [profile]

Running the app

  1. Install the NPM dependencies in the root directory

    npm install
  2. Add DNS entries to your /etc/hosts file

    warning

    You only need to do this once.

    sudo echo "127.0.0.1 iuweb.local.olcs.dev-dvsacloud.uk ssweb.local.olcs.dev-dvsacloud.uk api.local.olcs.dev-dvsacloud.uk cdn.local.olcs.dev-dvsacloud.uk mailpit.local.olcs.dev-dvsacloud.uk" >> /etc/hosts
  3. Start the application

    warning

    The olcs-etl project needs to be mounted as a volume in the db container. By default, the directory is set to ../olcs-etl.

    You can customise this using the OLCS_ETL_DIR environment variable before running the docker compose command.

    export OLCS_ETL_DIR=/path/to/olcs-etl
    docker compose up -d
  4. Run the local setup script - this script will also as a local reset and is safe to run multiple times.

    info

    If this is the first time you are running the application, you will need to run all the steps.

    npm run refresh
success

All done!

You can visit the application in your browser:

Any email sent by the app can be viewed via: Mailpit

Logging in

The local dataset has a number of different users that you can log in as.

info

The default password for all users while using LDAP is Password1.

Selfserve

UsernameRole
usr542Operator - User
usr543Operator - Transport Manager
usr611Operator - Admin
usr612Operator - Admin
usr778Partner - Admin
usr779Partner - Admin
usr1964Partner - User
usr1965Partner - User
usr20131Local Authority administrator
usr20132Local Authority user

Internal

UsernameRole
usr20Case worker
usr21Case worker
usr59Admin
usr273Admin
usr291System Admin
usr322Admin
usr331Limited read only
usr342Limited read only
usr455Admin
usr528Read only
usr529Read only
usr1071Admin
usr29431IRHP Admin
usr36047Admin
usr39158Admin
usr68648Admin
usr73852Admin
usr76189Admin
usr76754Admin
info

In the event that the local dataset changes, the above tables can be reproduced using the SQL:

SELECT u.login_id, r.description, IF(u.team_id IS NULL, "Selfserve", "Internal") as tenant FROM user u JOIN user_role ur ON u.id = ur.user_id JOIN role r ON r.id = ur.role_id;