This guide provides step-by-step instructions to clone the repository, update the database, create a new .env
file, install dependencies, build, and run the project.
- Clone the Repository
- Update the Database
- Create a New .env File
- Install the Dependencies
- Build the Project
- Run the Project
First, you need to clone the repository to your local machine. Open your terminal and run the following command:
git clone https://github.com/esse-jacques-dansomon/maarchrmap-notifications.git
cd maarchrmap-notifications
Update maarchrmap database
CREATE TYPE axoneNotificationType AS ENUM('notVerified', 'canBeNotified', 'canNotBeNotified');
ALTER TABLE "lifeCycle"."event"
ADD COLUMN "axoneNotification" axoneNotificationType DEFAULT 'notVerified';
ADD COLUMN "axoneNotificationSent" boolean DEFAULT false;
Create a .env
file in the root of your project directory with the following content, replacing placeholders with your actual database configuration:
DATABASE_HOST=localhost
DATABASE_PORT=5432
DATABASE_USER=maarch
DATABASE_PASSWORD=maarch
DATABASE_NAME=maarchRMAP
MAIL_HOST=
MAIL_PORT=
MAILER_SECURE=
MAILER_TLS=
MAIL_USER=
MAIL_PASSWORD=
MAIL_FROM=
Ensure you have Node.js and npm installed. If not, install them from Node.js official website.
Install the project dependencies by running:
npm install
To build the project, run:
npm run build
Finally, to run the project, use:
npm run start:prod
Alternatively, if you are using Docker, you can build and run the project using Docker Compose:
-
Ensure Docker and Docker Compose are installed on your machine.
-
Build and start the containers:
docker-compose up --build
-
Your application should now be running and accessible at
http://localhost:3000
.
- Make sure to replace
yourusername
andyourrepository
with the actual username and repository name. - Ensure your PostgreSQL server is configured correctly to accept connections from your application.
- Check the Docker configuration if you are using Docker to ensure all services are set up correctly.
- For any issues or further customization, refer to the project's documentation or contact the maintainers.