Open peaklabs-dev opened 9 months ago
- [ ] Eliminate dependency on all external services -> let us use them if we want, but also let us use local databases and also let us deploy the server whre want not only on Vercel.
Vercel:
You can deploy to Node JS just fine, SST allows decently easy AWS deployments, and Amplify could be used, Netlify also has NextJS deployment you just have to configure some basics for using turborepo with them, you'll also have to find a CRON system to use, SST works easily but you can roll any system you'd like if you configure the Auth Bearer Token for CRON Jobs
PlanetScale:
you can use a MySQL DB hosted anywhere including locally with minimal change
Upstash:
You can swap out the base connection to a standard redis connection without much difficulty and host that anywhere, similar applies to QStash features
The only thing you lose here is domain transfers are built around Vercel DNS, no guarantees on how you'll set that up.
You'll still need outside systems for things like Cloudinary or unsplash the full list of outside env vars is:
PlansetScale DB
"DATABASE_URL",Domain transfer
"TEAM_ID_VERCEL", "PROJECT_ID_VERCEL",TB analytics
"TINYBIRD_API_KEY",Upstash services
"UPSTASH_REDIS_REST_URL", "UPSTASH_REDIS_REST_TOKEN", "RATELIMIT_UPSTASH_REDIS_REST_URL", "RATELIMIT_UPSTASH_REDIS_REST_TOKEN", "QSTASH_TOKEN", "QSTASH_CURRENT_SIGNING_KEY", "QSTASH_NEXT_SIGNING_KEY",Magic link login + other emails
"RESEND_API_KEY", "RESEND_AUDIENCE_ID",Stripe for payment
"STRIPE_SECRET_KEY", "STRIPE_SECRET_KEY_LIVE", "NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY", "NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY_LIVE",OAuth
"GOOGLE_CLIENT_ID", "GOOGLE_CLIENT_SECRET", "GITHUB_CLIENT_ID", "GITHUB_CLIENT_SECRET",Bitly porting
"NEXT_PUBLIC_BITLY_REDIRECT_URI", "BITLY_CLIENT_SECRET",Unsplash images for OG
"UNSPLASH_ACCESS_KEY", "CLOUDINARY_URL"
How can I eliminate all external dependencies? or will this be possible along with docker hosting soon?
@ayntk-ai you could pull all the oauth deps and roll passwords on your self hosted DB, bitly and unsplash you'd just have to loose the features same with stripe. TB could be done with a kafka pipeline, domain transfer is also just lost, Resend could be done with Nodemailer and SMTP servers if you really wanted but it's a huge hassle
this is planned: https://dub.co/docs/self-hosting#caveats
@steven-tey any idea on how to replace Tinybird, kafka + clickhouse with a small node/express/next API to glue it together to match the TB interface?
Any news on this ?
@steven-tey any updates on when we will be able to host dub without any external services just local services via docker compose?