AWS - 22 - Access S3 Objects of One Account from EC2 Instance in Another Account

Поділитися
Вставка
  • Опубліковано 5 лис 2024

КОМЕНТАРІ • 25

  • @karthikaravikumar6083
    @karthikaravikumar6083 Рік тому

    Thank you so much for the wonderful video. Nice explanation. Its much much much helpful to do my task

    • @surojbera
      @surojbera  Рік тому

      Glad it was helpful! Keep learning ✌️

  • @Kunal-best
    @Kunal-best Рік тому

    Your way of teaching and the real time scenario explanation of all the concepts will make you one day an awesome Tech mentor and stand out among the crowded so-called mentors on UA-cam.
    So don't stop bro.
    Continue your channel with providing more and more real time scenario classes regularly.
    Best of luck bro.

    • @surojbera
      @surojbera  Рік тому

      Thank you Kunal. 😊 I really appreciate your valuable feedback. Keep learning and keep supporting. 🤞

  • @sachidanandshahane5709
    @sachidanandshahane5709 Рік тому

    Good Explained, keep it up, and create more troubleshooting videos.

    • @surojbera
      @surojbera  Рік тому

      Appreciate your valuable feedback. Keep learning. 🤞

  • @kalyansarkarsit
    @kalyansarkarsit Рік тому

    👌 awesome lecture...

    • @surojbera
      @surojbera  Рік тому

      Appreciate your valuable feedback. Keep learning.🤞

  • @MEHARAFROZ-ub1hr
    @MEHARAFROZ-ub1hr 7 місяців тому +1

    Awesome video.. Thankyou

    • @surojbera
      @surojbera  7 місяців тому

      My pleasure 😊

  • @vicky-xv1xs
    @vicky-xv1xs 3 місяці тому +1

    Don't we need to allow any permission in S3 bucket policy ?

    • @surojbera
      @surojbera  3 місяці тому

      No. Not required in this case.

  • @dideepakindorkar3413
    @dideepakindorkar3413 Місяць тому

    Thanks

  • @JohnsonThomas-g5u
    @JohnsonThomas-g5u 5 місяців тому

    can we use this method in daily backup process to s3 from ec2?

  • @mohankumarsharma-c2v
    @mohankumarsharma-c2v Рік тому

    Since service token is valid for limited period ,how we can make it permanent to access bucket of diff account through IAM Role?
    also please help me in how we can access it by IAM user also.

    • @surojbera
      @surojbera  Рік тому

      Thanks, Mohan for bringing new questions. I shall create videos on those scenarios.

  • @abhishekdubey-p9n
    @abhishekdubey-p9n Рік тому +1

    I have to do same connection i want to Access my S3 bucket in Putty but without IAM role and Aws Configure the same thing you r doing pls help me out is there any documentation or any BLOG ??

    • @surojbera
      @surojbera  Рік тому

      I am not sure at this moment. But I believe we can achieve this with S3 bucket policy. Let me check and get back to you.

    • @surojbera
      @surojbera  Рік тому

      Just to clarify one point. If you are using putty to login to an EC2 instance and want to access the S3 bucket in a different account, the EC2 instance should have a role attached to it or we need to configure credentials using the aws configure command.

    • @abhishekdubey-p9n
      @abhishekdubey-p9n Рік тому

      @@surojbera see we use this command to list S3(aws s3 ls) but it shows to do aws configure if i attach iam role to my instance it doesn't ask for this my use case is to do not attach IAM role and do no configure AWS but want to list my S3 bucket. So u r telling i can achieve this with bucket policy pls help me out ..

    • @surojbera
      @surojbera  Рік тому

      @@abhishekdubey-p9n You just create one EC2 instance and one s3 bucket in the same AWS account. In the bucket policy of the S3 bucket write the below policy.
      {
      "Version": "2012-10-17",
      "Statement": [
      {

      "Effect": "Allow",
      "Principal": "*",
      "Action": "s3:*",
      "Resource": [
      "arn:aws:s3:::",
      "arn:aws:s3:::/*"
      ],
      "Condition": {
      "IpAddress": {
      "aws:SourceIp": ""
      }
      }
      }
      ]
      }
      Now login to your ec2 instance and write the below command to list all the objects inside your bucket.
      aws s3 ls --no-sign-request
      It will list all the objects inside your bucket.
      Using the above policy you can do different operations with the S3 bucket objects. I am not sure at this moment how to list all the buckets in the AWS account without credentials. I shall create a video with cross-account access without credential setup.

    • @abhishekdubey-p9n
      @abhishekdubey-p9n Рік тому

      @@surojbera Better u make the video on this it will very helpfull if any other get same use case pls

  • @arpitamondal5602
    @arpitamondal5602 Рік тому

    😮