Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This page has an intended audience of developer team members or technical team members looking to install Form.io on their local machine. This will allow for an isolated sandbox instance for investigation and research prior to preparing pull request or code commits

...

Docker compose is the preferred method as it is an automated process for setting up your environment.

Prerequisites

Pathfinder SSO client

Common Services API Access

This service requires an IDIR account. You can open this link https://getok.nrs.gov.bc.ca/app/requestAccount to request an account after logging in with your IDIR. This will provide you with API client id and secret to the CHES and CDOGS service.

It’s not necessary to immediately obtain access to CHES and CDOGS. If you wanted to take advantage of the document generator and email service in the future then this is where you would do it.

Setup

docker-compose

Docker compose is used to quickly set up the local environment, this is not how the production environment is hosted.

***New Changes Below******

This page has an intended audience of developers and other technical team members looking to install CHEFS on their local machines for testing and development. Following this documentation will set up an isolated sandbox CHEFS instance for investigation and research prior to preparing pull requests or code commits. 

CHEFS is based on the open-source Form.io platform. When using a form builder, Form.io creates a JSON schema that is used to render the forms within CHEFS as well as generate the REST API interface on the server. 

Prerequisites

  1. Request an SSO Integration from the Common Hosted Single Sign-on page in order to obtain a resource and secret that will be used for authentication when building CHEFS. View the detailed documentation about requesting the Pathfinder SSO integration. 

  2. Ensure that Docker is installed on your local machine. Using Docker allows for a quick CHEFS build on your local machine however this is not how the production environment is hosted. 

Setup

Start by cloning the CHEFS source code onto your local machine and download the local.json file below such that the directory structure follows /common-hosted-form-service/app/config/local.json 

View file
namelocal.json

Download chefs_build.zip which contains directory structure and docker file for building CHEFS.

View file
namechefs_build.zip

Open realm-export.json located at chefs_build/docker/imports/keycloak and search for XXXXXXXXXXXX. Leave this value as is or replace it with any value of your choice. Afterward, you must copy this value and paste it into local.json so that the CHEFS API can connect to your Keycloak instance. In order to do this, open local.json and search for XXXXXXXXXXXX, replacing it with the new value or leaving it as is if this value was not changed in realm-export.json. 

In the same realm-export.json file, search for YYYYYYYYYYYY and replace it with the client id (resource) you obtained from the Pathfinder SSO page. Search for ZZZZZZZZZZZZ and replace it with the client secret

All the files are now configured and you can run Keycloak and PostgreSQL by opening a terminal in the chefs_build directory. 

Run the following command: