GithubHelp home page GithubHelp logo

gabriel-hahn / files-upload Goto Github PK

View Code? Open in Web Editor NEW
4.0 2.0 0.0 1.16 MB

A ReactJS and NodeJS project to upload images using Amazon S3 :open_file_folder:

License: MIT License

JavaScript 96.11% HTML 3.58% Shell 0.30%
reactjs nodejs amazon-s3 multer aws mongodb

files-upload's Introduction

Images Upload Application

A ReactJS and NodeJS project to upload images using Amazon S3 ๐Ÿ“‚

Environment Variables

Before start, you must add a .env file for back-end and front-end at root folder of each one. For back-end, the .env file should be:

  APP_URL=Back-end url, normally http://localhost:3333 as local environment
  APP_DOMAIN=Front-end url, normally http://localhost:3000 as local environment

  MONGO_URL=MongoDB url connection

  STORAGE_TYPE=local or s3. Use local to save files inside temporary folder or s3 for AWS S3 repository.

  AWS_ACCESS_KEY_ID=AWS bucket key
  AWS_SECRET_ACCESS_KEY=AWS bucket secret key
  AWS_DEFAULT_REGION=AWS bucket region
  AWS_BUCKET_NAME=AWS bucket name

Front-end .env configuration is just about API url:

REACT_APP_API_URL=Back-end url, normally http://localhost:3333 as local environment

Getting Started

To run the back-end, we are using Docker & Docker compose and you can install it and just run the following command in api folder:

docker-compose up

It will download mongodb image for you.

After that you can just run yarn start at the same folder to run our NodeJS application. It will be available at http://localhost:3333

To run the front-end, just run the following command and the page will be open at http://localhost:3000:

yarn start

Online

This project is not available online because is needed to implement user validation, otherwise the application will show all files from all users. I have been using this project as a private application, but you can create an AWS S3 bucket and publish it on Heroku or Netlify and have your own upload images application :)

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

Gabriel Hahn Schaeffer | Rocketseat

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE.md file for details

files-upload's People

Contributors

dependabot[bot] avatar gabriel-hahn avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.