- Node.js 24 or later
- npm 11 or later
- Access to the REST service and its credentials
-
Clone the repository and enter the project directory:
git clone https://github.com/Ri5ha6h/align-board.git cd align-board -
Install dependencies:
npm install
-
Create
.env.localin the project root and provide the required values:APP_ORIGIN=http://localhost:3000 REST_URL=<rest-service-url> REST_USERNAME=<rest-service-username> REST_PASSWORD=<rest-service-password> TOKEN_SECRET=<jwt-signing-secret> TEST_USER_BACKEND_USERNAME=<test-user-backend-username> TEST_USER_BACKEND_PASSWORD=<test-user-backend-password> # Optional: both values are required to enable the test-user alias TEST_USER_ALIAS_USERNAME=<test-user-alias-username> TEST_USER_ALIAS_PASSWORD=<test-user-alias-password>
Set
APP_ORIGINto the browser-facing application origin in deployed environments, for examplehttps://tracking.alignbits.com. This keeps authentication redirects on the public host when Next.js runs behind a reverse proxy.TEST_USER_ALIAS_USERNAMEandTEST_USER_ALIAS_PASSWORDare optional, but must be set together. When configured, the alias credentials sign in as the account identified byTEST_USER_BACKEND_USERNAMEandTEST_USER_BACKEND_PASSWORD.Obtain the real values through the project's approved secure channel. Do not commit
.env.localor share its secrets. -
Start the development server:
npm run dev
-
Open http://localhost:3000 in a browser.
src/
actions/ # Server actions and API-facing business logic
app/ # Next.js routes, pages, and layouts
components/ # Shared and feature-specific React components
ui/ # Canonical shadcn/ui components
custom-wrappers/ # Application providers and wrappers
lib/ # Shared libraries and access helpers
utils/ # Schemas, types, queries, mutations, and default data
public/ # Static assets
styles/ # Global styles
- Use npm for dependency management and project scripts.
- Keep secrets in
.env.local; never commit credentials or tokens. - Keep canonical shadcn/ui primitives in
src/components/uiunchanged and extend them through feature components or wrappers. - Place feature-specific components in focused subdirectories under
src/components. - Put shared utilities in
src/liborsrc/utils. - Run
npm run lintandnpm run buildbefore submitting changes.