‫So here I am in the Amazon S3 console.
‫And the first thing I'm going to do
‫is of course to create a bucket
‫because this is where the data is being stored.
‫So the bucket name has to have a name
‫and if I enter a name that someone
‫has already taken from before,
‫for example, if I enter test and leave this box
‫and I try to create this bucket,
‫I'm gonna get an issue
‫saying that the bucket with the same name already exists.
‫So even though in my account
‫I've never created a bucket named test,
‫someone in someone's accounts
‫has created a bucket named test and it's already taken.
‫And so therefore I cannot name my bucket like this.
‫So instead, I will name this stephane-demo-s3.
‫Something like this.
‫And perfect,
‫this bucket name should not have been taken before.
‫We'll have a look at it
‫when I create this bucket but it should be unique.
‫Next, if we have a look,
‫there is a region this bucket needs to be into so
‫I'm choosing a region that is close to me,
‫for example the Ireland region
‫and you can choose a region that is close to you.
‫But you will notice on the right hand side
‫on the top right that the console says that
‫it's a global selection for the Amazon S3 service.
‫So that means that within the S3 service
‫you will see your buckets across all regions in one view.
‫But remember that your buckets are not global.
‫Your buckets are created and live only within one region.
‫Okay, perfect. So we have a name, we have a region.
‫For object ownership,
‫we're going to disable the ACLs for now.
‫I will now go over the setting.
‫There's another security setting here
‫to block all public access.
‫We will leave this on by default.
‫Same for versioning,
‫we'll leave the disabled by default.
‫And for default encryption
‫I will leave the default settings.
‫So we'll just go ahead and create a bucket
‫with these settings set as defaults.
‫So now as you can see,
‫I've successfully created my bucket, stephane-demo-s3
‫and it's here in my bucket view.
‫So again, we have in this view
‫access to all the buckets
‫because we're in the global setting
‫but each bucket is assigned to a specific region.
‫Okay, so next, let's go into this bucket
‫and close the left-hand side panel.
‫And now in my bucket
‫I would like to start uploading objects
‫because currently you have zero objects.
‫So let's click on upload.
‫And then we can add files.
‫And I'll navigate into your code, go into the S3 folder
‫and then you will find a coffee.jpg file
‫so choose this coffee.jpg file.
‫As you can see, it's an image/jpeg,
‫it has 100 kilobytes in size.
‫And then the destination is s3 stephane-demo,
‫which is my bucket.
‫Okay, so let's upload this file.
‫We're done.
‫So I can close this on the right-hand side.
‫And now back into my S3 bucket.
‫I can see the coffee.jpg file
‫is under my objects
‫so I can do is now click on it
‫and have more details around that file.
‫So now that we are in the object page,
‫we can have a look at a bunch of overview
‫so a bunch of properties,
‫where it's been uploaded, the size, the type
‫and there is an object URL here,
‫we'll be playing it in a moment.
‫So how do we do this?
‫So now we want to open this object
‫and see if we can open it,
‫we can view it because we have uploaded it
‫onto our Amazon S3 buckets.
‫Therefore, I'm going to click on open.
‫And if I do click on open, as you can see,
‫I can see my coffee.jpg file.
‫So this is the one I have uploaded
‫and it is on the internet.
‫Awesome, right?
‫But if I go back to my overview
‫and click on this object URL over here.
‫So I copy it, I paste it, and I enter it.
‫As you can see, I get an access denied.
‫And this access denied
‫tells me that I cannot access my object
‫using what's called the public URL.
‫So as you can see here,
‫this public URL is not working,
‫but this URL is working.
‫So what's the difference?
‫Well, this URL right here, if you have a look at it,
‫the beginning is exactly the same,
‫but then the rest is a very, very complicated and long
‫URL because it's called an S3 pre-signed URL.
‫Why? Well, because this URL contains actually
‫a signature that verifies
‫that I am the one making the request
‫and therefore it has my credentials in it.
‫And so because my credentials are encoded in this URL
‫then Amazon S3 says,
‫"Well, Stephane is allowed to view his own object,
‫therefore I will display it."
‫So this public URL does not work,
‫but this pre-signed URL with my own credentials works.
‫And obviously this URL is only for me.
‫So we'll see how to make that object public later on
‫so that the public URL will function as well.
‫So let's go back into our bucket, the stephane-demo-s3.
‫And I have one object but I can create a folder.
‫And this folder name may be called images.
‫So we scroll down and create this folder.
‫So now I have the images folder in my buckets.
‫I can click on it and within it I can upload, again, a file.
‫And this time I will upload the beach.jpg file into,
‫as you can see the destination is my images folder
‫within my S3 bucket.
‫So let's upload this.
‫Close this.
‫As we can see now we have the beach.jpg object
‫within the images folder.
‫And if I go one level up, we can see the folder here.
‫So this looks just like, you know,
‫the cloud storage service you used to know
‫such as Google Drive or Dropbox or whatever you want.
‫Here we have something very similar
‫in terms of the user experience on Amazon S3.
‫So of course I can go to images
‫and I can delete this folder entirely.
‫So this will delete everything within the folder.
‫And to delete things,
‫I just type permanently delete into the text input,
‫delete my objects, and I'm good to go.
‫So that's it for this lecture.
‫We've seen how we can upload objects into Amazon S3.
‫We've seen how we can open them in two different ways,
‫creating folders, deleting folders, and so on.
‫So I hope you liked it
‫and I will see you in the next lecture.