Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Вивчайте Конфігурація Amazon Simple Storage Service | Огляд AWS S3
Вступ до Хмарних Обчислень
course content

Зміст курсу

Вступ до Хмарних Обчислень

Вступ до Хмарних Обчислень

1. Вступ до хмарних технологій
2. Огляд AWS S3
3. Огляд EC2
4. Управління RDS

book
Конфігурація Amazon Simple Storage Service

Starting to learn AWS services should begin with the basics.

Therefore, we will start with a service like S3, which is used by everyone, always. Even the images I include in this course are stored on S3, any media information, and sometimes code snippets or scripts that perform various functions.

Let's start with the definition:

Creating a Bucket

Now, let's start working with S3. First, we need to access this service by clicking on the "Services" button in the top left corner. Then, at the bottom, we'll see the "Storage" section, and after clicking on it, a menu will appear where we should select S3:

After that, we'll go to the menu, where you can see a short video guide from Amazon, which will tell you how to work with S3, as well as a lot of other information. You can review it if you want, but what we're interested in now is the "Create Bucket" button, which is shown in the screenshot below:

Now you need to configure your bucket. You can read about each of the settings yourself, or you can replicate my settings listed below.

carousel-imgcarousel-imgcarousel-imgcarousel-imgcarousel-img

If you've done everything correctly, you should see a picture like this in front of you:

Now let's configure our bucket so that users can only use GET requests, for example, to view the image on the screen or download it. To do this, we need to go to the bucket, navigate to the permissions section, and scroll down to the Bucket Policy section.

Then we need to add this code there:

Цей JSON є політикою доступу Amazon S3, яка визначає дозволи для доступу до об'єктів у бакеті S3. В AWS ці політики використовуються для управління доступом до ресурсів у хмарних сервісах. У цьому випадку політика описує наступні дозволи:

  • Version: Це вказує на версію синтаксису політики. "2012-10-17" є останньою та найширше використовуваною версією політик;

  • Statement: Це основний елемент політики, який містить масив окремих заяв.

Кожна заява (у цьому випадку одна) містить:

  • Effect: Визначає, чи дозволено дію чи ні. У цьому випадку "Allow" означає, що дія дозволена;

  • Principal: Вказує, хто отримує дозвіл. Тут "*" означає, що дозвіл надається всім користувачам;

  • Action: Вказує, яка дія дозволена. "s3:GetObject" дозволяє користувачам отримувати доступ (завантажувати) об'єкти (файли) у бакеті S3;

  • Resource: Вказує на конкретний ресурс, до якого застосовуються дозволи. "arn:aws:s3:::codefinity-aws-course/*" відноситься до всіх об'єктів (позначених зірочкою *) у бакеті S3 з назвою "codefinity-aws-course".

Your permission file should look like this:

Note

Ignore any warnings from AWS because we are learning. We need the files in the bucket to be public so that we can visually see how the storage works through the code.

Great, we have successfully created a bucket and configured it for our needs. In the upcoming chapters, we will learn how to upload media files into it and use it in our code and applications.

Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 2. Розділ 2
We're sorry to hear that something went wrong. What happened?
some-alt