J. Doe
J. Doe

Reputation: 244

Connect Jupyter Notebook (locally) to AWS s3 without SageMaker

Is it possible to connect jupyter notebook that is running locally to one of the buckets on AWS S3 without using SageMaker and involving no or with access and secret keys?

Upvotes: 5

Views: 16964

Answers (2)

Gaurav Karki
Gaurav Karki

Reputation: 31

import boto3
s3_client = boto3.client('s3',aws_access_key_id="<Type your key>",aws_secret_access_key="<type your sec key>")
bucket = "<your bucket name>"
file_name = "<your file name>"
s3_clientobj = s3_client.get_object(Bucket=bucket, Key=file_name)

Upvotes: 3

dmigo
dmigo

Reputation: 3029

Apparently it is possible. You can find a tutorial here. However, you'll need to create an IAM role. The process is described here.

Upvotes: 4

Related Questions