Skip to main content

🚀 Quick Start

Welcome to Springular! This guide will help you set up and run Springular locally. You'll find instructions on requirements, setup, and how to run each service individually or all at once.


Requirements

Before you begin, ensure you have the following tools installed on your system:


Running Springular Using Docker Compose

To run all services together, execute:

docker-compose up

Before running, ensure you have the necessary environment variables set up. Copy the example .env file to create your configuration:

cp .env.example .env

This will start:

  • Backend (springular-server)
  • Frontend (springular-client)
  • Database (springular-db)
  • Documentation (springular-docs)

All services will be accessible on their respective ports:

  • Frontend: http://localhost:4200
  • Backend: http://localhost:8081
  • Documentation: http://localhost:3000

Note: The application will be functional, and email/password authentication will work. However, external systems will not work with random values entered in environment variables, specifically:

  • Sendgrid
  • Stripe
  • Google OAuth2 (social login)

These services will only work with valid credentials and configuration.


Running Each Service Individually

1. Database

To start the PostgreSQL database:

docker-compose up springular-db -d

This launches the database container in detached mode.


2. Frontend (Client)

The frontend service is an Angular application. To run it locally:

  1. Navigate to the client directory:

    cd client
  2. Install dependencies:

    npm install
  3. Start the development server:

    ng serve

The frontend will be accessible at http://localhost:4200.


3. Backend (Server)

The backend is a Spring Boot application. To run it locally using IntelliJ IDEA:

  1. Open your project in IntelliJ IDEA.

  2. In the toolbar, click on Run -> Edit Configurations.

  3. Click on the + button to create a new configuration.

  4. Select Spring Boot as the configuration type.

  5. Check the Enable EnvFile checkbox and add the path to the .env file in the table below.

  6. Click Apply and then OK.

  7. Now you can run the backend by clicking on the Run button.

The backend will be accessible at http://localhost:8081.

Note: Make sure the EnvFile plugin is installed and enabled in your IntelliJ IDEA.


4. Documentation (Docs)

The documentation is built using Docusaurus. To run it locally:

  1. Navigate to the docs directory:

    cd docs
  2. Install dependencies:

    npm install
  3. Start the development server:

    npm start

The documentation will be accessible at http://localhost:3000.