An application developed using Node.js for backend, React.js for frontend and Amazon S3.
The application has the feature of create "Posts", using MongoDB as persistence. At the time, it only supports the feature of uploading files, but I have plans to add description, hashtags, likes and everything more.
The packages I've installed are all listed on package.json of each part (frontend and backend).
First, define the following environment variables:
-
APP_URL This is the url you have defined for the app to run (like http://localhost:3000)
-
STORAGE_TYPE: This one is for multer to know which one storage you are using, the defined storages are: local and s3, use the same values for the environment variable.
-
MONGODB_URI: This is the access url to your MongoDB instance.
-
AWS_ACCESS_KEY_ID: This is your secret key id for AWS (only if you're going to use AWS S3 service)
-
AWS_SECRET_ACCESS_KEY: This is your secret access key for AWS (only if you're going to use AWS S3 service)
-
AWS_DEFAULT_REGION: This is the region you have configured your bucket to run (only if you're going to use AWS S3 service).
Then must have Node.js installed, enter the backend folder run npm install
and then npm start
or npm run dev
. The npm run dev option runs the app with nodemon and watch files for alteration. Now your backend should be running (note that the .env file is required).
ON DEVELOPMENT