Storing Images in S3 from Node Server

Поделиться
HTML-код
  • Опубликовано: 26 янв 2025

Комментарии • 231

  • @2ez2nv
    @2ez2nv Год назад +51

    A year later this is still the best tutorial on S3 uploading. It is criminal how easy you made this for everyone. Subbed & liked.

    • @noahmilliken4259
      @noahmilliken4259 10 месяцев назад +1

      Really love Sam's videos. There are few and far between quality, intermediate web dev content creators. His inclusion of Devops for solo devs is really great too.

  • @moodrow1234
    @moodrow1234 2 года назад +62

    Thank you so much for making this video. For a multi-billion dollar company, AWS sure does make it difficult to do simple things and the docs are incredibly hard to find and understand.

  • @Callumkloos
    @Callumkloos Год назад +11

    This should just be slapped on the top of the s3 documentation tbh. Thank you for this!

  • @SimoSensei
    @SimoSensei 2 года назад +41

    Dude you 're so underrated, you have hands down the best node express videos.
    Following along with you is super easy and your videos are so informative.
    Please don't stop doing what you are doing.
    You are awesome !

  • @night_city_nights
    @night_city_nights 2 года назад +14

    Dude I'm 2/3rds into the video. Lemme just say, BEST image processing tutorial on youtube for node/express; hands down.
    After 2 weeks of muddling through multer and sharp, only to realize heroku renews your files (thus erasing anything saved to it with FS), this is like EXACTLY what I needed to get past the image uploading process in my app. None of the tuts mention small details like the "fit" property in Sharp's resize method object, my portrait style uploads were looking so wonky before this.
    You have my subscribe. Shout out to you!

    • @stephen8906
      @stephen8906 2 года назад

      Oh I am so glad that I read this comment because I was specifically looking for something due to Heroku deleting apps.

  • @Eric-do8wy
    @Eric-do8wy Год назад +23

    Just in case anyone is running into trouble with adding the credentials parameter to the S3Client object, the current version of the AWS SDK (as of writing this) for Node doesn't require it as a parameter anymore. The credentials are automatically read from the .env file, and MUST be named AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY.

    • @vishnugopalakrishnan9539
      @vishnugopalakrishnan9539 9 месяцев назад +2

      thank you, this comment must be pinned :)

    • @daybot1634
      @daybot1634 Месяц назад

      This is an example from aws docs, you can use json file as well:
      "'
      You can load configuration and credentials from a JSON document on disk using AWS.config.loadFromPath. The path specified is relative to the current working directory of your process. For example, to load credentials from a 'config.json' file with the following content:
      { "accessKeyId": , "secretAccessKey": , "region": "us-east-1" }
      Then use the following code:
      var AWS = require("aws-sdk");
      AWS.config.loadFromPath('./config.json');
      "'

  • @ItalianVoid
    @ItalianVoid 2 года назад +5

    perfect timing, just was about to watch your older videos again but this is a treat! Thank you

  • @yashgaur1716
    @yashgaur1716 2 года назад +3

    Thank you for this Tutorial, Your Concept grasp has let me understand what really was going on in there. Thanks for the hard work for this video!!

  • @dylandelorie2067
    @dylandelorie2067 Год назад +6

    Watched a fair few tutorials for this topic - one of the clearest and detailed programming tutorials out there. It was well-paced, clear, to the point, and... I love it when you can tell that the teacher actually understands what they are doing at every step - a lot will just say, 'Create this, do these things and it will just magically work' (especially in areas such as the AWS setup) - that's okay I guess, I love it when things work, but to make it great I want to personally understand what I am doing and why certain actions do certain things. I totally got that from this! This gives me all of the knowledge to implement this into my own project and even take it further. You've gained a new subscriber and I will definitely recommend your channel - can't wait to check out your other videos. Keep up the great work! :)

    • @EIsenah
      @EIsenah Год назад

      Highly agree

  • @demiladeotunaiya5252
    @demiladeotunaiya5252 2 года назад +1

    I have been looking for a video to learn Lambda. I have watched 4 to 5 other videos that only ended making me more confused or were full of fluff. I decided to try out your video and this is the best and most explanatory video onS3 Lambda on RUclips. YOU ROCK! Congrats on gaining a new subscriber!

  • @hyunjoolee6121
    @hyunjoolee6121 2 года назад +2

    Such amazing timing...! I was asked today to utilize the S3 server in our short-term project and here you are... wow. Thank you.

  • @ethdev1729
    @ethdev1729 3 дня назад

    Absolutely loved it. Easiest explanation I have ever seen

  • @Elliott_Ives
    @Elliott_Ives 2 года назад +1

    Figuring out S3 through the docs is an absolute nightmare. Thank you for this

  • @KamalBoruah-uf9zo
    @KamalBoruah-uf9zo 11 месяцев назад

    Thank you so much. I was searching about this niche subject online for few days and very less on - point tutorials were actually available. It was a great help.

  • @mohsinmiyaji1801
    @mohsinmiyaji1801 Год назад

    thank you so much for making this video. I've been debuggin my code for almost 7 hours trying to upload an image and this finally solved the issue. thank you.

  • @berkeberke4284
    @berkeberke4284 9 месяцев назад

    20.04.2024 still best tutorial about S3. I use Nestjs but still very informative for me. Huge respect!!

  • @juancgalue
    @juancgalue 2 года назад +2

    Hello, I just want to say thank you for this mega explanation. You helped me a lot to understand this process. I just implemented that in my own MERN app. Thank you again.

  • @mohammedramadan740
    @mohammedramadan740 9 месяцев назад

    Thanks so much for this clear and concise video✨! Following your steps, I was able to successfully implement image uploads in my own project. This video was a lifesaver! I highly recommend it to anyone else who's getting started with S3

  • @shreejanregmi
    @shreejanregmi 10 месяцев назад

    What a terrific tutorial. Well-paced and covers all relevant topics.

  • @17a.studio
    @17a.studio 3 месяца назад

    Dziękujemy.

  • @simplehonestmusic2261
    @simplehonestmusic2261 5 месяцев назад

    You are my hero dude.
    I'm building a guitar lessons app, and this is the EXACT info I needed to keep going.

  • @mustafa-ahmed-dev
    @mustafa-ahmed-dev 2 года назад +1

    Thank you so much, this was one of the best tutorials I have ever watched

  • @ashutoshkumar4099
    @ashutoshkumar4099 10 месяцев назад

    Thanks. Just came across the best tutorial to store, fetch and delete images to and from S3. Please keep the good work going!

  • @HarisKhan-bh6uj
    @HarisKhan-bh6uj Год назад

    I have been recommending your videos to my peers as well !! they are amazing !!

  • @AKASH-sw9bs
    @AKASH-sw9bs 2 года назад

    Man you are just amazing . Gluing all the things up as a developer was a pain for me and you have reduced all the hustles . Thanks man . And surely you got a new subscriber.

  • @KingTMK
    @KingTMK Год назад +1

    This is such a great resource! Greatly explained as well. What a gem. Thank you.

  • @Abishek-b5y
    @Abishek-b5y 10 месяцев назад

    Thanks!

  • @bcr1532
    @bcr1532 Год назад

    Dude. You have no idea how much you've helped me. Awesome video!! Congrats.

  • @harryvince4265
    @harryvince4265 2 года назад

    Thank you for a brilliant Video, goes over everything in just enough depth to help you understand but also dosen't overcomplicate the process. Again, Thank You!

  • @aabhashrai6925
    @aabhashrai6925 Год назад

    This is awesome. Kudos mate. looking forward to seeing more videos rolling.

  • @Pedrothelima
    @Pedrothelima 8 месяцев назад

    Thank you very much for this video, simply the best video I found telling everything I need about access to S3, even though my application is a Java Backend I still managed to learn everything to apply to my system.

  • @isabellebidou
    @isabellebidou Год назад +1

    Thank you so much for all your work! you are an amazing developer and teacher! your videos are amazing!

  • @kevincastro5439
    @kevincastro5439 11 месяцев назад

    Forsure the best tutuorial I've watched on this topic. Thank you for this. Earned a sub and like.

  • @davesmith4151
    @davesmith4151 2 года назад

    really great walkthrough, clear and concise, thanks again Sam!

  • @GaryFrancis-q3r
    @GaryFrancis-q3r Год назад

    Very clear explanations and easy to follow. Thanks for the nice video series.

  • @TheDoguBati
    @TheDoguBati 2 года назад

    Thanks Sam for the great content. I find it really helpful and you make some of the concepts easy to understand. Thanks again.

  • @FunesdelaTorre
    @FunesdelaTorre 2 года назад

    it was the clearest video i found about express and s3. And I do a lot of research.

  • @karthikt3957
    @karthikt3957 2 месяца назад

    Great Video. No words to thank you. So much of learnings

  • @visheshdadhich6636
    @visheshdadhich6636 5 месяцев назад

    Thanks a lot Sam, prob the best tutorial out there on youtube!

  • @hasnainasif1657
    @hasnainasif1657 Год назад

    Thanks a lot. Your teaching style is awesome and the video is to the point.

  • @abdulmohiz001
    @abdulmohiz001 5 месяцев назад

    Such a nice explanation! Love it.

  • @farrukhahmad1430
    @farrukhahmad1430 2 года назад

    Great information in a precise and on-point manner 👌. Loved it bro ❤️

  • @camilosaavedrasalas3880
    @camilosaavedrasalas3880 Год назад

    This video is amazing, I have learned a lot from your video. Keep creating more content like this.

  • @rahmounioussama1624
    @rahmounioussama1624 6 месяцев назад

    thanks bro , this video is a life saving , keep up the good work !!

  • @raba650
    @raba650 2 года назад

    Just subscribed for the good explanation & code walkthrough!

  • @vasilymedvedev3077
    @vasilymedvedev3077 7 месяцев назад

    Thank you very much!!!! Perfect video! You have the talent of teaching.

  • @anirbanchakraborty4175
    @anirbanchakraborty4175 Год назад

    Instant follow, you are daa best!
    Please bring more web + was integrations with different was services!

  • @annabrooks5175
    @annabrooks5175 Год назад

    really straightforward and informative, thank you!

  • @VivekS-r4g
    @VivekS-r4g Месяц назад +1

    உங்கள் வீடியோ மிகவும் நன்றாக உள்ளது அண்ணா

  • @junaiderade3975
    @junaiderade3975 2 года назад

    Amazing video. I successfully applied the principles here to react native!

  • @teoramites
    @teoramites 3 месяца назад

    Great video bro. You are a really good teacher.

  • @anocre
    @anocre Год назад

    Tysm for making this video. Exactly what I am looking for.

  • @ashfakhossainevan791
    @ashfakhossainevan791 5 месяцев назад

    best s3 playlist available in yt

  • @bobdpa
    @bobdpa 2 года назад

    Great stuff here. I don't typically think to use the network tab. Lots of good info here!

  • @moiserwibutso4899
    @moiserwibutso4899 2 года назад

    Thanks for this amazing tutorial Sam!

    • @SamMeechWard
      @SamMeechWard  2 года назад

      You're welcome 🤗

    • @moiserwibutso4899
      @moiserwibutso4899 2 года назад

      @@SamMeechWard However, I had a minor issue. I did everything you did and got the URL using the getSignedUrl method but I can't open the image in my browser. I just get a white screen when I try to open it in my browser. I'd appreciate your help.

  • @osamahussam4351
    @osamahussam4351 Год назад

    such a great resource, thx a lot sam

  • @221miteshdevganiya2
    @221miteshdevganiya2 2 месяца назад

    Thank you so much it's very very much useful for me
    i'm cloud computing student so it's very useful for me

  • @notorious1298
    @notorious1298 3 месяца назад

    Best tutorial on S3 there is!

  • @jessewhite2431
    @jessewhite2431 Год назад

    Hands down the best video on the subject! Could you do a video, or even just a repo, of this with multiple images/attachments?

  • @diegopena6992
    @diegopena6992 2 года назад

    Great Video :) simple and clear with all the Information.

  • @ddwork-h6o
    @ddwork-h6o 11 месяцев назад

    Amazing tutorial. With this and another of your videos, now upload to S3 via Backend or directly via Frontend is very clear to me.
    It would be very nice to have a guide for doing the same with AWS Lightsail, where the documentation is very poor but the service is widely used.

  • @j0oj0o13
    @j0oj0o13 2 года назад

    Thanks for this tutorial!! If somebody try to fit this tut with mongoDB/mongoose when you generate a file url by looping the array, think about updating your schema by adding a new imageUrl entry 😉

    • @SamMeechWard
      @SamMeechWard  2 года назад +1

      This is only really good if you're not using a signed url

    • @GIOVANNYGARCIAHOLGUIN
      @GIOVANNYGARCIAHOLGUIN Год назад

      i'm using mongodb and mongoose and doesn' work for me when i try to add a signed url

    • @studiomiraba4463
      @studiomiraba4463 Год назад

      you have no idea how this helped me. Thank you!!

  • @Joao-pm8je
    @Joao-pm8je Год назад +1

    Would be awesome to get an updated version of this video using NextJS 14

  • @derik4622
    @derik4622 2 года назад

    great stuff! Enjoying all the aws content

  • @returnZeroo
    @returnZeroo Год назад

    Sam, we need more aws content from you, please :)

  • @VolodymyrSirenko
    @VolodymyrSirenko 7 месяцев назад

    Thank you for this video! I understood correctly: you run the express server to work in Node.js?

  • @gaurav22zero8
    @gaurav22zero8 Год назад

    Very Time saving tutorial, Thank you

  • @bhargavibhat7044
    @bhargavibhat7044 7 месяцев назад

    Out of topic but how did he do everything from 17:39 💀 I need to learn these shortcuts asap

  • @leanhtung9743
    @leanhtung9743 2 года назад

    this video could not be better.

  • @jimkk159
    @jimkk159 Год назад

    Awsome video!! However,
    I wonder how dose Sam change his code so fast at 17:40 ?
    Is there any keyboard shortcuts?

  • @27sosite73
    @27sosite73 Год назад

    mate, you are THE LEGEND!

  • @agustinmacazzaga828
    @agustinmacazzaga828 2 года назад

    Damn bro, you just save my proyect! AMAZING tutorial

  • @Bisibletoanyoneonyoutube
    @Bisibletoanyoneonyoutube Год назад

    Thanks for the video. I was really struggling for this and needed now qhat i was expecting

  • @aabidmahat2721
    @aabidmahat2721 6 месяцев назад

    Amazing Bro .. Just Perfect😁😁

  • @minnyanlin2051
    @minnyanlin2051 6 месяцев назад

    Thank for your extends my knowledge

  • @DTerminal-n2b
    @DTerminal-n2b 7 месяцев назад

    Excellent work here sir.

  • @nicocouss7849
    @nicocouss7849 2 года назад

    Exactly what i need. Thx a lot 😊

  • @quangtranoannhat2930
    @quangtranoannhat2930 Год назад

    awsome, thank you so much. Love your content.

  • @eparsons5265
    @eparsons5265 9 месяцев назад

    Thanks a lot Sam! but how can i avoid the images expiration date of 7 days?

  • @alexdospinoiu530
    @alexdospinoiu530 2 года назад

    @Sam Meech ... thanks for the video. I'm working on a React app and am following along. I got all the way to 22:08. I can't figure out why I'm getting this 'Resolved credential object is not valid' message on the server-side (i.e. nodemon server.js side). As soon as I hit 'submit' on the front-end .. I can see all the data of the req.body & req.file on the server-side (in VS code) ... but my nodemon then crashes and give the error I mentioned. Obviously the .png is not being pushed into my S3 bucket. Any help would be greatly appreciated.

    • @alexdospinoiu530
      @alexdospinoiu530 2 года назад

      You're not going to believe the stupid-ness of what it was ... it my .env file ... for the Access Key I had it as ACCESS-KEY instead of ACCESS_KEY. That was it, the little dash...

  • @jikaikas
    @jikaikas Год назад

    whats that auto-complete thingy 23:41 bro

  • @AstroRockit
    @AstroRockit Год назад

    You are a Godsend! Thank you so much

  • @lizempson2916
    @lizempson2916 Год назад

    Very clear tutorial and works perfectly on local server. However on live site the urls returning cannot be resolved into images. I'm thinking maybe this is connected to a permissions issue? Many thanks

  • @marvellousadesanya8480
    @marvellousadesanya8480 Год назад

    Thanks immensely for this!

  • @andrewma5056
    @andrewma5056 2 года назад

    Very helpful, thank you very much!

  • @shiveshanand5812
    @shiveshanand5812 6 месяцев назад

    Awesome video! You are a lifesaver!

  • @davidadediji3354
    @davidadediji3354 7 месяцев назад

    Thank you for this
    But what if i want to update an image and then delete the old image from S3 to save memory

  • @tranquilopablo
    @tranquilopablo 2 года назад

    Thanks for that video. It helped me alot!

  • @fixesdev
    @fixesdev 10 месяцев назад

    Bro excellent video! thank you

  • @andypark9201
    @andypark9201 Год назад

    amazing video, liked and subscribed

  • @inderkantkhandelwaal3402
    @inderkantkhandelwaal3402 Год назад

    Firstly: Thanks for this.
    And how can we achieve for eg:
    If i have ecommerce and user is not logged then how we can show image to all users ... Is there a way without url generate with proper security maintain... Please reply its urgent Thanks 🙏

  • @biju__1654
    @biju__1654 Год назад

    what is the cheapest way to run the node express server for frontend api calls on aws? and also for serving the react app?

  • @colbr6733
    @colbr6733 2 года назад

    Very useful stuff, I'm not using React but this is fine for me. Do appreciate the codeshare, if I need to fallback on that. The video/narrative is certainly thorough enough. I am looking forward to the CDN video. Thanks again. On a separate note, for possible future interest, I will be looking at automating integration of signup and deployment of the SaaS for each client.

  • @davidsoane5015
    @davidsoane5015 Год назад +1

    He mentioned something about uploading multiple images, how would I do that?

    • @jessewhite2431
      @jessewhite2431 Год назад

      I'm wondering the same thing. Were you able to figure it out?

  • @trevorg2069
    @trevorg2069 Год назад

    Should I use a package like file-type to determine the file type by checking the magic numbers and then compare that with the mimetype from multer and if they don't match reject the request?

  • @marvellousadesanya8480
    @marvellousadesanya8480 Год назад

    What if we just want to return the url of the image without any restrictions?

  • @AnonymousSoj
    @AnonymousSoj 2 года назад

    This was really helpful. Thanks.

  • @jasongrant2366
    @jasongrant2366 11 месяцев назад

    I'm still trying to find the pricing of AWS. I'm using cloudinary as of right now and I'm looking for other options. if you can tell me how much AWS costs i'd appreciate that

  • @miraklemonkey
    @miraklemonkey 10 месяцев назад

    What if you leave the getSignedUrl's "expires-in" part empty?

  • @santrajyadav196
    @santrajyadav196 Год назад

    Hello I could apply object property after fetching data from database so that I can add new temporary field to fetched data from data base but I did not mention this field in schema that ii want to add as new field in fetched data, I want to image URL as temporary field that's why please help me what I did mistake