This repo holds a companion Node.js Express application called "AwesomeCRM" for the Modeling Organizations guide on the FusionAuth website. The guide walks through how to model organizations in FusionAuth using the Entity Management feature.
The docker-compose.yml file and the kickstart directory are used to start and configure a local FusionAuth server.
The /complete-application directory contains a fully working version of the application.
- Docker, to run FusionAuth
- Node 16 or later, to run the AwesomeCRM Express application
NOTE: Before running the command to install FusionAuth, add your FusionAuth license key to the ./kickstart/kickstart.json file. Find the licenseId field on line 24 and replace the field value with your license key. Please visit https://fusionauth.io/pricing to read more about FusionAuth licensing.
In the root of this project directory (next to this README) are two files: a Docker compose file and an environment variables configuration file. Assuming you have Docker installed on your machine, you can stand up FusionAuth on your machine with the following command.
docker compose up -dThe FusionAuth configuration files use a unique feature of FusionAuth called Kickstart. When FusionAuth comes up for the first time, it will look at the Kickstart file and mimic API calls to configure FusionAuth for use.
NOTE: If you ever want to reset the FusionAuth system, delete the volumes created by Docker Compose by executing
docker compose down -v.
FusionAuth will be configured with these settings:
- Your Client Id is:
e9fdb985-9173-4e01-9d73-ac2d60d1dc8e - Your Client Secret is:
super-secret-secret-that-should-be-regenerated-for-production - Your example usernames are:
richard@example.com, password ispassword. Richard is the admin for the "Pied Piper" entity.erlich@example.com, password ispassword. Erlich is the admin for the "Aviato" entity.jared@example.com, password ispassword. Jared is the admin for the "Hooli" entity.
- Your admin username for FusionAuth is
admin@example.comand your password ispassword. - Your
fusionAuthBaseUrlishttp://localhost:9011/
You can log in to the FusionAuth admin UI and look around if you want to, but with Docker and Kickstart, everything will already be configured correctly.
To run the application, first go into the project directory.
cd complete-applicationInstall dependencies.
npm installStart the application.
npm startBrowse to the application at http://localhost:3000.