amazon-s3

AWS credentials in Dockerfile

感情迁移 提交于 2020-06-27 07:49:30
问题 I require files to be downloaded from AWS S3 during container build, however I've been unsuccessful to provide the AWS credentials to the build process without actually hardcoding them in the Dockerfile. I get the error: docker fatal error: Unable to locate credentials despite previously having executed: aws configure Moreover, I was not able to use --build-arg for this purpose. My question: is it possible to have these credentials in build time without hardcoding them in the Dockerfile and

Cost of renaming a folder in AWS S3 bucket

杀马特。学长 韩版系。学妹 提交于 2020-06-27 07:22:20
问题 I want to rename a folder in S3 bucket, I understand that rename will run a PUT request which costs 1 cent per 1000 request. However, the PUT request is defined as a COPY and involves with also a GET My question is, when we rename a folder in S3 bucket, does it involve copying all sub-folders and files to a new folder with the name I want (which costs more than 1 PUT request), or it just simply 1 PUT request to change the name without touching all the items within the folder. 回答1: In case you

Receiving Email is not working in Amazon SES

不问归期 提交于 2020-06-27 06:53:38
问题 I tried to access the email and tried to store email in S3 bucket but it is not working. SES configuration: domain verified email address verified created rule set in rule set Recipient has provided In S3 action bucket name given AMAZON_SES_SETUP_NOTIFICATION has received. After that if I receive any email from particular recipient it is not stored in S3. 回答1: If you are using Route53 for your domain management, you may have forgotten to set up MX record for it. Here is an instruction of how

Using Amazon S3 as a Database storage for use with Xodus

末鹿安然 提交于 2020-06-27 04:14:23
问题 We built our platform using a Java-based database developed by Jetbrains, it is called Xodus. However, it is designed for a monolith platform that Jetbrains provides as a service, if I remember correctly, YouTrack and Hub platforms. So we banked on that production use when we built our own platform. Xodus is very lightweight and very fast, really performant, pound per pound to other databases out there. Xodus provides efficient blob storage that we use to store all sorts of files, the main

Rename written CSV file Spark

偶尔善良 提交于 2020-06-27 03:52:09
问题 I'm running spark 2.1 and I want to write a csv with results into Amazon S3. After repartitioning the csv file has kind of a long kryptic name and I want to change that into a specific filename. I'm using the databricks lib for writing into S3. dataframe .repartition(1) .write .format("com.databricks.spark.csv") .option("header", "true") .save("folder/dataframe/") Is there a way to rename the file afterwards or even save it directly with the correct name? I've already looked for solutions and

How change S3 file ownership while cross-account uploading

安稳与你 提交于 2020-06-25 10:40:30
问题 I have an application which upload ( copy ) some files to a S3 bucket in another AWS account, I use copyObject command from AWS SDK ( Nodejs ) var params = { Bucket: "MyBucket_AccountB", CopySource: encodeURI('/Accunt_A_Bocket/file.png'), Key: "file.png", ACL: 'bucket-owner-full-control' }; s3.copyObject(params, function(err, datas) { if (err) console.log(err, err.stack); // an error occurred else console.log(datas); // successful response }); This code, run from a diffrent AWS Account, let's

Reading contents of a gzip file from a AWS S3 in Python

无人久伴 提交于 2020-06-24 05:04:09
问题 I am trying to read some logs from a Hadoop process that I run in AWS. The logs are stored in an S3 folder and have the following path. bucketname = name key = y/z/stderr.gz Here Y is the cluster id and z is a folder name. Both of these act as folders(objects) in AWS. So the full path is like x/y/z/stderr.gz. Now I want to unzip this .gz file and read the contents of the file. I don't want to download this file to my system wants to save contents in a python variable. This is what I have

How do you automate pyspark jobs on emr using boto3 (or otherwise)?

吃可爱长大的小学妹 提交于 2020-06-24 04:51:08
问题 I am creating a job to parse massive amounts of server data, and then upload it into a Redshift database. My job flow is as follows: Grab the log data from S3 Either use spark dataframes or spark sql to parse the data and write back out to S3 Upload the data from S3 to Redshift. I'm getting hung up on how to automate this though so that my process spins up an EMR cluster, bootstraps the correct programs for installation, and runs my python script that will contain the code for parsing and

AWS lambda read zip file perform validation and unzip to s3 bucket if validation is passed

走远了吗. 提交于 2020-06-23 14:53:06
问题 I have a requirement in which a zip files arrives on s3 bucket, I need to write a lambda using python to read the zip file perform some validation and unzip on another S3 bucket. Zip file contains below: a.csv b.csv c.csv trigger_file.txt trigger_file.txt -- contain names of files in zip and record count (example: a.csv:120 , b.csv:10 , c.csv:50 ) So using lambda I need to read trigger file check if number files in zip folder is equal to number of files mentioned in trigger file if pass the

Credentials can't be located for S3 Flask app in Heroku

廉价感情. 提交于 2020-06-18 10:47:53
问题 My flask app works locally with AWS S3 bucket, but when I try to get it to work in Heroku, I keep getting this error 2020-06-07T00:58:29.174989+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.6/site-packages/botocore/signers.py", line 160, in sign 2020-06-07T00:58:29.174989+00:00 app[web.1]: auth.add_auth(request) 2020-06-07T00:58:29.174989+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.6/site-packages/botocore/auth.py", line 357, in add_auth 2020-06-07T00:58:29.174989+00:00