Skip to content
Merged
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
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,5 @@ npm-debug.log*
.DS_Store
*.pem

docs-output
docs-output
data
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@ pnpm install
pnpm docs:dev
```

## Running the database

From the root of the monorepo, run the following command to start the database locally:

```bash
docker-compose up
```

## Running the demo web app

Prepare the `.env.local` files by running the following command:
Expand Down
14 changes: 14 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
version: "3"

services:
postgres:
image: postgres:13-alpine
ports:
- 5432:5432
environment:
POSTGRES_PASSWORD: root
POSTGRES_USER: root
POSTGRES_DB: hyperjump-web-framework
volumes:
- ./data:/var/lib/postgresql/data
restart: unless-stopped
14 changes: 8 additions & 6 deletions packages/env/env.example
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
# How to use this env.example:
# 1. If you make changes to this file, run `pnpm build` from this `packages/env` directory.
# 2. Copy this file to .env.
# 3. Run ./dev-bootstrap.sh from the root of the monorepo to create symlinks of the .env file in other apps and packages.
# IMPORTANT: Always add comment above the env variable explaining what the var is for and where to get its value.

# The database of the E-learning with connection pool
DB_POOLING_URL="postgres://root:root@localhost:5432/turborepo" #required
DB_POOLING_URL="postgres://root:root@localhost:5432/hyperjump-web-framwork" #required

# The database of the E-learning without connection pool for Prisma migration
DB_URL_NON_POOLING="postgres://root:root@localhost:5432/turborepo" #required
DB_URL_NON_POOLING="postgres://root:root@localhost:5432/hyperjump-web-framework" #required

# this is used by demo app
NEXT_PUBLIC_DEFAULT_LANGUAGE=de #required

# the default timeout of the operation
NEXT_PUBLIC_DEFAULT_TIMEOUT_MS=10000 #number

# Just for testing
IS_ODD=true
IS_EVEN=false
2 changes: 0 additions & 2 deletions packages/env/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ export const env = createEnv({
server: {
DB_POOLING_URL: z.string().min(1),
DB_URL_NON_POOLING: z.string().min(1),
IS_ODD: z.string().optional(),
IS_EVEN: z.string().optional(),
},
client: {
NEXT_PUBLIC_DEFAULT_LANGUAGE: z.string().min(1),
Expand Down