Skip to content
pasuruandevPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Pasuruan Dev App

Monorepo for the Pasuruan Dev platform, managed with Turborepo and Bun.

Contributors

Name Email LinkedIn
Rahmat Ramadhan Putra rahmatrdn.dev@gmail.com https://www.linkedin.com/in/rahmatrdn/

Services

Service / Package Path Tech Stack Port Description
Web apps/web Next.js, React, Tailwind CSS 3010 Main public web application
API apps/api Elysia, Bun, Drizzle ORM, Better Auth 3011 Backend API server & authentication
Portal Admin apps/portal-admin Laravel, Blade, Vite 8000 Admin management portal

Prerequisites

Make sure the following tools are installed and available on your machine before setting up the project:

  • Bun (1.4.3 or later)
  • MySQL (running locally on port 3306, or accessible via network)
  • PHP (>= 8.2) and Composer (required for apps/portal-admin)

Setup Guide

1. Install Dependencies

Install JavaScript/TypeScript workspace dependencies from the repository root:

bun install

Install PHP dependencies for apps/portal-admin:

cd apps/portal-admin
composer install
cd ../..

2. Start MySQL & Create Database

Make sure your MySQL server is running, then create a database named pasdev_db:

CREATE DATABASE IF NOT EXISTS pasdev_db;

3. Configure Environment Variables

Copy .env.example to .env in each service and update the values for your local environment:

cp apps/api/.env.example apps/api/.env
cp apps/web/.env.example apps/web/.env
cp apps/portal-admin/.env.example apps/portal-admin/.env

Key settings to verify in each .env:

  • apps/api/.env
    • Set DATABASE_URL to point to pasdev_db (e.g., mysql://root:root@localhost:3306/pasdev_db).
    • Set BETTER_AUTH_SECRET (generate with openssl rand -base64 32).
    • Set GOOGLE_CLIENT_ID and GOOGLE_CLIENT_SECRET if testing Google OAuth sign-in.
  • apps/web/.env
    • Verify NEXT_PUBLIC_API_URL=http://localhost:3011 and NEXT_PUBLIC_SITE_URL=http://localhost:3010.
  • apps/portal-admin/.env
    • Set DB_DATABASE=pasdev_db along with your DB_USERNAME and DB_PASSWORD.

    • Generate the Laravel application key:

      cd apps/portal-admin
      php artisan key:generate
      cd ../..

4. Run Database Migrations

Run the Drizzle migrations for apps/api:

cd apps/api
bun run db:migrate
cd ../..

Note: You do not need to run migrations for the Laravel app (apps/portal-admin); the database schema is managed by apps/api.

5. Run the Project

Start all apps in development mode from the repository root:

bun run dev

Once running, the services are available at:

Other Useful Commands

Run from the repository root:

bun run build      # Build all apps and packages
bun run lint       # Run linters across the workspace
bun run format     # Format code across the workspace
bun run typecheck  # Run TypeScript type checking

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages