Skip to content

Commit

Permalink
feat: added s3 bucket image saving route
Browse files Browse the repository at this point in the history
  • Loading branch information
kujo205 committed Feb 16, 2024
1 parent 35e502c commit 9e21179
Show file tree
Hide file tree
Showing 7 changed files with 1,253 additions and 5 deletions.
19 changes: 15 additions & 4 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,28 @@
# should be updated accordingly.

# Drizzle
# Get the Database URL from the "prisma" dropdown selector in PlanetScale.
# Get the Database URL from the "prisma" dropdown selector in PlanetScale.
# Change the query params at the end of the URL to "?ssl={"rejectUnauthorized":true}"
DATABASE_URL='mysql://YOUR_MYSQL_URL_HERE?ssl={"rejectUnauthorized":true}'
# DATABASE_URL='mysql://someurlYOUR_MYSQL_URL_HERE?ssl={"rejectUnauthorized":true}'

# Next Auth
# You can generate a new secret on the command line with:
# openssl rand -base64 32
# https://next-auth.js.org/configuration/options#secret
# NEXTAUTH_SECRET=""
NEXTAUTH_SECRET==
NEXTAUTH_URL="http://localhost:3000"

# Next Auth Discord Provider
DISCORD_CLIENT_ID=""
DISCORD_CLIENT_SECRET=""
GOOGLE_CLIENT_SECRET=
GOOGLE_CLIENT_ID=

# Telegram stuff
TELEGRAM_BOT_TOKEN=
MY_TELEGRAM_CHAT_ID=

# S3 api stuff
S3_ACCESS_KEY=
S3_SECRET_ACCESS_KEY=
AWS_REGION=
BUCKET_NAME=
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
},
"dependencies": {
"@auth/drizzle-adapter": "^0.3.6",
"@aws-sdk/client-s3": "^3.515.0",
"@aws-sdk/s3-request-presigner": "^3.515.0",
"@hookform/resolvers": "^3.3.4",
"@planetscale/database": "^1.11.0",
"@radix-ui/react-avatar": "^1.0.4",
Expand All @@ -27,6 +29,7 @@
"@trpc/next": "^10.43.6",
"@trpc/react-query": "^10.43.6",
"@trpc/server": "^10.43.6",
"axios": "^1.6.7",
"class-variance-authority": "^0.7.0",
"clsx": "^2.1.0",
"cmdk": "^0.2.0",
Expand Down
Loading

0 comments on commit 9e21179

Please sign in to comment.