The DFA (Disaster Financial Assistance) Portal consists of two separate projects:
-
DFA Private Sector Portal
- Serves homeowners, residential tenants, small businesses, farms, and charitable organizations
- Located in the
dfa/
directory
-
DFA Public Sector Portal
- Serves Indigenous communities and local governments
- Located in the
dfa-public/
directory
Both projects share similar setup requirements and architecture.
- Node Version Manager (nvm)
- Node.js 20.14.0
- Angular CLI 18.0.4
- pnpm
- .NET Core 6.0.x
- Visual Studio (for API development)
- Microsoft Edge (recommended browser for local development)
Both portals use trion/ng-cli-karma
as their base Docker image. To match the build environment:
nvm install 20.14.0
nvm use 20.14.0
Install the required global packages:
npm install -g @angular/cli@18.0.4
npm install -g pnpm
dfa/
├── src/
│ ├── UI/
│ │ └── embc-dfa/ # Frontend application
│ └── API/
│ └── EMBC.DFA.API/ # Backend API
dfa-public/
├── src/
│ ├── UI/
│ │ └── embc-dfa/ # Frontend application
│ └── API/
│ └── EMBC.DFA.PUBLIC.API/ # Backend API
-
Navigate to the frontend directory:
cd dfa/src/UI/embc-dfa
-
Install dependencies:
npm install
-
Start the application:
- With remote API:
npm run start
- With local API:
Note that when running
npm run startlocal
npm run startlocal
, the Angular application will use OpenAPI to automatically generate necessary TypeScript files based on the API specification.
- With remote API:
-
Navigate to the frontend directory:
cd dfa-public/src/UI/embc-dfa
-
Install dependencies:
npm install
-
Start the application:
- With remote API:
npm run start
- With local API:
npm run startlocal
- With remote API:
Both APIs require user secrets configuration for local development.
- Configure user secrets:
- Reference the structure from the Confluence page
- Configuration details should be added using .NET User Secrets
-
Navigate to the API directory:
cd dfa/src/API/EMBC.DFA.API
-
Start the API in watch mode:
dotnet watch
-
Navigate to the API directory:
cd dfa-public/src/API/EMBC.DFA.PUBLIC.API
-
Start the API in watch mode:
dotnet watch
- Both projects use GitHub Actions for CI/CD
- Builds are performed using Docker with
trion/ng-cli-karma
as the base image - The build process automatically uses the latest version of
trion/ng-cli-karma