You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
Trent Larson a035077b18 add JWT validation 7 months ago
sql add JWT validation 7 months ago
.gitignore add DB to record each image upload 7 months ago
README.md add JWT validation 7 months ago
package.json add JWT validation 7 months ago
pnpm-lock.yaml add JWT validation 7 months ago
server.js add JWT validation 7 months ago

README.md

Image Server

setup

sh <(curl https://pkgx.sh) +pnpm sh
pnpm install
# create the directory for files that are being uploaded; should stay empty afterward
mkdir uploads
pnpm run migrate

Now set up an AWS S3 bucket & Infura project, and manually set these variables inside a .env file:

AWS_ACCESS_KEY=
AWS_SECRET_KEY=
AWS_REGION=

INFURA_PROJECT_ID=

dev

node server.js

test

curl -X POST -F "image=@./test.png" http://localhost:3000/image

deploy to prod first time

  • Do the necessary steps from "setup" above.

  • In AWS, set up bucket and erase any test data.