Skip to content
Merged

WTF #50

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 25 additions & 18 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,19 @@ POSTGRES_USER=betterbase
POSTGRES_PASSWORD=your_secure_password_here
POSTGRES_DB=betterbase

DATABASE_URL=postgresql://betterbase:your_secure_password_here@localhost:5432/betterbase
# Connection string for applications
# Format: postgresql://user:password@host:port/database
DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@localhost:5432/${POSTGRES_DB}

# ----------------------------------------------------------------------------
# Authentication
# ----------------------------------------------------------------------------
# Generate: openssl rand -base64 32
AUTH_SECRET=your-super-secret-key-min-32-chars-long
AUTH_URL=http://localhost:3000
# Generate a secure secret: openssl rand -base64 32
BETTERBASE_JWT_SECRET=your-super-secret-key-min-32-chars-long
BETTERBASE_PUBLIC_URL=http://localhost:3000

# ----------------------------------------------------------------------------
# MinIO (S3-compatible storage)
# MinIO (S3-compatible storage for local development)
# ----------------------------------------------------------------------------
MINIO_ROOT_USER=minioadmin
MINIO_ROOT_PASSWORD=minioadmin_password
Expand All @@ -36,9 +38,9 @@ STORAGE_BUCKET=betterbase
# Inngest (Durable Workflow Engine)
# ----------------------------------------------------------------------------
INNGEST_LOG_LEVEL=info
# Generate: openssl rand -hex 32
# Generate signing key: openssl rand -hex 32
INNGEST_SIGNING_KEY=
# Generate: openssl rand -hex 16
# Generate event key: openssl rand -hex 16
INNGEST_EVENT_KEY=

# ----------------------------------------------------------------------------
Expand All @@ -48,19 +50,21 @@ NODE_ENV=development
PORT=3001
HOST=0.0.0.0

CORS_ORIGIN=http://localhost:3000,http://localhost:5173
CORS_ORIGINS=http://localhost:3000,http://localhost:5173

LOG_LEVEL=debug

# ----------------------------------------------------------------------------
# Storage (S3-compatible - for production with external services)
# Production Settings
# ----------------------------------------------------------------------------
# STORAGE_PROVIDER=r2
# STORAGE_BUCKET=betterbase-storage
# STORAGE_REGION=auto
# HTTP port for nginx proxy (default: 80)
# HTTP_PORT=80

# Use external managed services instead of Docker (uncomment):
# DATABASE_URL=postgres://user:password@host:5432/database
# STORAGE_ENDPOINT=https://your-r2-endpoint.r2.cloudflarestorage.com
# STORAGE_ACCESS_KEY_ID=your-access-key
# STORAGE_SECRET_ACCESS_KEY=your-secret-key
# STORAGE_ACCESS_KEY=your-access-key
# STORAGE_SECRET_KEY=your-secret-key

# ----------------------------------------------------------------------------
# Email (optional)
Expand All @@ -83,12 +87,15 @@ LOG_LEVEL=debug
# ----------------------------------------------------------------------------
# Phone Auth (optional - Twilio)
# ----------------------------------------------------------------------------
# TWILIO_ACCOUNT_SID=your-twilio-sid
# TWILIO_AUTH_TOKEN=your-twilio-token
# TWILIO_PHONE_NUMBER=+1234567890
# STORAGE_PROVIDER=r2
# STORAGE_BUCKET=betterbase-storage
# STORAGE_REGION=auto
# STORAGE_ENDPOINT=https://your-r2-endpoint.r2.cloudflarestorage.com
# STORAGE_ACCESS_KEY_ID=your-access-key
# STORAGE_SECRET_ACCESS_KEY=your-secret-key

# ----------------------------------------------------------------------------
# Vector Search (optional)
# ----------------------------------------------------------------------------
# VECTOR_PROVIDER=openai
# OPENAI_API_KEY=your-openai-api-key
# OPENAI_API_KEY=your-openai-api-key
84 changes: 84 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
# Contributing to Betterbase

Thank you for your interest in contributing to Betterbase!

## Getting Started

1. **Fork** the repository
2. **Clone** your fork: `git clone https://github.com/your-username/betterbase.git`
3. **Install** dependencies: `bun install`
4. **Create** a branch: `git checkout -b feature/my-feature`

## Development Setup

```bash
# Install dependencies
bun install

# Build all packages
bun run build

# Run tests
bun test

# Run linting
bun run lint
```

## Code Style

We use Biome for code formatting and linting:

```bash
# Format code
bun run format

# Lint code
bun run lint

# Fix auto-fixable issues
bun run lint:fix
```

## Testing

```bash
# Run all tests
bun test

# Run tests for specific package
bun test --filter=@betterbase/cli

# Run tests in watch mode
bun test --watch
```

## Commit Messages

Follow Conventional Commits:

```
feat: add new feature
fix: resolve bug
docs: update documentation
refactor: restructure code
test: add tests
chore: maintenance
```

## Submitting Changes

1. Push your branch: `git push origin feature/my-feature`
2. Open a **Pull Request**
3. Fill out the PR template
4. Wait for review

## Good First Issues

Looking for a way to contribute? Check out our [Good First Issues](https://github.com/weroperking/Betterbase/labels/good-first-issue) label on GitHub.

## Community

Join our community:
- **Discord**: https://discord.gg/R6Dm6Cgy2E
- **GitHub Discussions**: https://github.com/weroperking/Betterbase/discussions
Loading
Loading