Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add SaaS structure to Jupiter #35

Draft
wants to merge 21 commits into
base: main
Choose a base branch
from
Draft
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 0 additions & 5 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,6 @@ CLOUDFLARE_STORAGE_BUCKET_NAME="jupiter-dev"

OPENAI_API_KEY=""

# Panda

PANDAVIDEO_API_KEY=""
PANDAVIDEO_UPLOAD_FOLDER="91568d19-8f77-40a7-b2c2-dd87502568ee"

# Auth

NEXTAUTH_URL="http://localhost:3000"
Expand Down
5 changes: 3 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
next.config.js
node_modules
.next
.next
.turbo
.vercel
11 changes: 0 additions & 11 deletions .eslintrc.json

This file was deleted.

24 changes: 2 additions & 22 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,36 +1,16 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
# turborepo
.turbo
8 changes: 7 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
{
"cSpell.words": [
"barberpole",
"bunnycdn",
"cloudflare",
"eden",
"elysia",
"hookform",
"immer",
"Immer",
"neondatabase",
"NEXTAUTH",
"nextjs",
"nivo",
"openai",
"PANDAVIDEO",
"presigner",
"qstash",
"QSTASH",
"superjson",
"tanstack",
"upstash"
"upstash",
"webvtt"
]
}
12 changes: 2 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
Jupiter is a video upload hub that automates the generation of titles, descriptions and transcripts through AI.
# Nivo

### To-do

- Whisper JAX
- New FFMPeg (@ffmpeg/core)
- Datadog / Sentry
- DeadLetter queue (manual retry)
- store number of retries and if its the last maybe notice somewhere and display a button for manual retry
- Find possibly typos in transcription based on commit diff
- Tests please?!
The all-in-one video solution for online learning.
39 changes: 39 additions & 0 deletions apps/web/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts

# turborepo
.turbo
File renamed without changes.
43 changes: 43 additions & 0 deletions apps/web/next.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
logging: {
fetches: {
fullUrl: true,
},
},

typescript: {
ignoreBuildErrors: true,
},

eslint: {
ignoreDuringBuilds: true,
},

images: {
remotePatterns: [
{ hostname: 'lh3.googleusercontent.com' },
{ hostname: 'github.com' },
],
},

/**
* @param {import('webpack').Configuration} config
*/
webpack: (config) => {
/**
* Suppress warning about not found modules
*/
config.resolve.fallback = {
'aws-crt': false,
encoding: false,
'@aws-sdk/signature-v4-crt': false,
bufferutil: false,
'utf-8-validate': false,
}

return config
},
}

export default nextConfig
95 changes: 95 additions & 0 deletions apps/web/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
{
"name": "web",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "eslint ."
},
"dependencies": {
"@hookform/resolvers": "3.3.4",
"@nivo/auth": "workspace:*",
"@nivo/bunny": "workspace:*",
"@nivo/cloudflare": "workspace:*",
"@nivo/dayjs": "workspace:*",
"@nivo/drizzle": "workspace:*",
"@nivo/env": "workspace:*",
"@nivo/ffmpeg": "workspace:*",
"@nivo/openai": "workspace:*",
"@nivo/qstash": "workspace:*",
"@nivo/trpc": "workspace:*",
"@nivo/webhooks": "workspace:*",
"@radix-ui/react-accordion": "^1.1.2",
"@radix-ui/react-alert-dialog": "1.0.4",
"@radix-ui/react-avatar": "1.0.3",
"@radix-ui/react-checkbox": "1.0.4",
"@radix-ui/react-dialog": "1.0.4",
"@radix-ui/react-dropdown-menu": "2.0.5",
"@radix-ui/react-hover-card": "1.0.6",
"@radix-ui/react-icons": "1.3.0",
"@radix-ui/react-label": "2.0.2",
"@radix-ui/react-popover": "1.0.6",
"@radix-ui/react-progress": "1.0.3",
"@radix-ui/react-scroll-area": "1.0.4",
"@radix-ui/react-select": "1.2.2",
"@radix-ui/react-separator": "1.0.3",
"@radix-ui/react-slot": "1.0.2",
"@radix-ui/react-switch": "1.0.3",
"@radix-ui/react-tabs": "1.0.4",
"@radix-ui/react-toast": "1.1.4",
"@radix-ui/react-tooltip": "1.0.6",
"@tanstack/react-query": "5.18.0",
"@trpc/client": "next",
"@trpc/react-query": "next",
"@trpc/server": "next",
"@upstash/kafka": "1.3.5",
"ai": "2.1.17",
"apexcharts": "^3.45.2",
"axios": "1.4.0",
"bunnycdn-stream": "^2.2.2",
"cmdk": "0.2.0",
"drizzle-orm": "^0.29.3",
"form-data": "4.0.0",
"immer": "10.0.3",
"jotai": "2.6.3",
"jotai-immer": "0.2.0",
"lucide-react": "0.319.0",
"next": "14.1.0",
"next-themes": "0.2.1",
"node-webvtt": "1.9.4",
"react": "^18.2.0",
"react-apexcharts": "^1.4.1",
"react-dom": "^18.2.0",
"react-dropzone": "14.2.3",
"react-hook-form": "7.49.3",
"recharts": "2.11.0",
"server-only": "^0.0.1",
"superjson": "^2.2.1",
"tailwind-merge": "2.2.1",
"tailwind-variants": "0.1.20",
"zod": "3.22.4"
},
"devDependencies": {
"@types/node": "20.4.0",
"@types/react-dom": "18.2.19",
"@types/react": "18.2.55",
"@types/recharts": "1.8.24",
"autoprefixer": "10.4.17",
"postcss": "8.4.33",
"tailwindcss": "3.4.1",
"tailwindcss-animate": "1.0.6",
"@nivo/tsconfig": "workspace:*",
"@nivo/eslint-config": "workspace:*",
"@nivo/prettier": "workspace:*",
"typescript": "5.3.3"
},
"eslintConfig": {
"root": true,
"extends": [
"@nivo/eslint-config/next"
]
},
"prettier": "@nivo/prettier"
}
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { Metadata } from 'next'
import { Suspense } from 'react'

import { Loading } from '@/components/summary/loading'
import { Storage } from '@/components/summary/storage'
import { TotalCount } from '@/components/summary/total-count'
import { ViewsCount } from '@/components/summary/views-count'
import { env } from '@/env'

export const metadata: Metadata = {
title: 'Dashboard',
Expand All @@ -16,11 +16,12 @@ export default function DashboardPage() {
<>
<h2 className="text-3xl font-bold tracking-tight">Dashboard</h2>
<div className="grid grid-cols-2 gap-4">
<TotalCount />
<Storage />
</div>
<div className="grid grid-cols-1">
{env.PANDAVIDEO_API_KEY && <ViewsCount />}
<Suspense fallback={<Loading />}>
<TotalCount />
</Suspense>
<Suspense fallback={<Loading />}>
<Storage />
</Suspense>
</div>
</>
)
Expand Down
Loading