Hi everyone,
I will like to contribute the turborepo example, but I am wondering if anyone is interested what exactly are you looking to find in a turborepo example, a nextjs/expressjs combination or just a blank one like the one below.
Below is the proposed structure, happy to take any feedback and recommendations.
Cheers
Project Structure
coolify-turborepo-starter/
├── apps/
│ ├── web/
│ │ ├── Dockerfile
│ │ └── package.json
│ └── api/
│ ├── Dockerfile
│ └── package.json
├── packages/
│ ├── ui/
│ │ └── package.json
│ └── utils/
│ └── package.json
├── turbo.json
├── package.json
├── pnpm-workspace.yaml
├── .gitignore
├── coolify.yaml
└── README.md
Files
package.json
{
"name": "coolify-turborepo-starter",
"private": true,
"workspaces": ["apps/*", "packages/*"],
"scripts": {
"dev": "turbo run dev --parallel",
"build": "turbo run build"
},
"devDependencies": {
"turbo": "^1.12.0"
}
}
pnpm-workspace.yaml
packages:
- "apps/*"
- "packages/*"
turbo.json
{
"pipeline": {
"build": {
"dependsOn": ["^build"],
"outputs": ["dist/**"]
},
"dev": {
"cache": false
}
}
}
apps/web/package.json
{
"name": "web",
"scripts": {
"dev": "echo 'Starting web app...'",
"build": "echo 'Building web app...'"
}
}
apps/web/Dockerfile
FROM node:18-alpine
WORKDIR /app
COPY . .
CMD ["sh", "-c", "echo Hello from web app"]
apps/api/package.json
{
"name": "api",
"scripts": {
"dev": "echo 'Starting api app...'",
"build": "echo 'Building api app...'"
}
}
apps/api/Dockerfile
FROM node:18-alpine
WORKDIR /app
COPY . .
CMD ["sh", "-c", "echo Hello from api app"]
packages/ui/package.json
{
"name": "ui",
"version": "1.0.0"
}
packages/utils/package.json
{
"name": "utils",
"version": "1.0.0"
}
coolify.yaml
services:
- name: web
build:
context: .
dockerfile: ./apps/web/Dockerfile
source:
type: git
- name: api
build:
context: .
dockerfile: ./apps/api/Dockerfile
source:
type: git
Hi everyone,
I will like to contribute the turborepo example, but I am wondering if anyone is interested what exactly are you looking to find in a turborepo example, a nextjs/expressjs combination or just a blank one like the one below.
Below is the proposed structure, happy to take any feedback and recommendations.
Cheers
Project Structure
Files
package.json{ "name": "coolify-turborepo-starter", "private": true, "workspaces": ["apps/*", "packages/*"], "scripts": { "dev": "turbo run dev --parallel", "build": "turbo run build" }, "devDependencies": { "turbo": "^1.12.0" } }pnpm-workspace.yamlturbo.json{ "pipeline": { "build": { "dependsOn": ["^build"], "outputs": ["dist/**"] }, "dev": { "cache": false } } }apps/web/package.json{ "name": "web", "scripts": { "dev": "echo 'Starting web app...'", "build": "echo 'Building web app...'" } }apps/web/Dockerfileapps/api/package.json{ "name": "api", "scripts": { "dev": "echo 'Starting api app...'", "build": "echo 'Building api app...'" } }apps/api/Dockerfilepackages/ui/package.json{ "name": "ui", "version": "1.0.0" }packages/utils/package.json{ "name": "utils", "version": "1.0.0" }coolify.yaml