Access S3 bucket object using direct URL and not through CLI

0

I have a requirement to call S3 objects using company load balancer (Which has security rules for static ips not dns). To achieve this

  1. I created reverse proxy on an EC2 and access s3 bucked in reserve proxy
  2. The reverse proxy simply does below --> proxy_pass http://bucketname.s3.region.amazonaws.com/
  3. This is working fine but i want to access the s3 bucket with private link so i created an interface private link
  4. I am able to access the objects with cli aws s3 ls s3://bucket/ --region region --endpoint-url https://bucket.Privatelink --no-verify-ssl
  5. However I am not sure if i have private full realized url that i can use in step 2

Any help?

ayan
gefragt vor einem Monat299 Aufrufe
3 Antworten
1

💡 You also can use the S3 object's pre-signed URL.

ℹ️ A pre-signed URL is a URL that grants temporary access to an S3 object, even if the object is private.

This approach has several advantages:

  • It allows you to access the S3 object directly without going through the CLI or the standard S3 endpoint, which can be useful when you have security restrictions on the allowed IP addresses or DNS names.
  • The pre-signed URL is temporary, so it provides a secure way to access the object without exposing your AWS credentials.
  • The pre-signed URL can be generated programmatically, which makes it easier to integrate into your application or infrastructure.

ℹ️ You can find more information about sharing objects using presigned URLs in the AWS S3 documentation. Please let me know if this meets your needs.

profile picture
EXPERTE
beantwortet vor einem Monat
1

You might find some assistance in this blog post - it sounds like you're trying to host a website privately within your VPC.

profile pictureAWS
EXPERTE
beantwortet vor einem Monat
0

Hello,

I guess you can access the private S3 Bucket through your PC using a Client VPN Endpoint. By connecting to the VPC using an ENI, you can then further connect through "transitive routing" to the VPC Endpoint Interface.

profile picture
Julian
beantwortet vor einem Monat
  • I am not trying to connect through PC but through EC2 but without using cli command .. so basically a url which i can do wget on but is on private link

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen