UniverseColumbus opened a new issue, #2218:
URL: https://github.com/apache/hop/issues/2218

   ### Apache Hop version?
   
   2.3.0
   
   ### Java version?
   
   11.0.16
   
   ### Operating system
   
   macOS
   
   ### What happened?
   
   I have encountered a problem when trying to download & upload files from an 
S3 bucket using a "Text File Input" action in Apache hop GUI (version 2.3.0) 
running on the local macOS environment using the following VFS url 
(s3://sdi-snowflake-bucket/snowflake-data/fake-data.csv). AWS credentials 
(AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY) are being set as [system environment 
variables](https://hop.apache.org/manual/latest/vfs/aws-s3-vfs.html#_variables) 
which I can verify exist using the “Write to Log” action in hop. When trying to 
download the S3 files there is an error in hop that says:
   
   ERROR: org.apache.commons.vfs2.FileSystemException: Could not determine the 
type of file "s3:///sdi-snowflake-bucket/snowflake-data/fake-data.csv".
   Caused by: com.amazonaws.services.s3.model.AmazonS3Exception: Access Denied 
(Service: Amazon S3; Status Code: 403
   
   The AWS credentials set as system environment variables work when using the 
[“Shell” 
action](https://hop.apache.org/manual/latest/workflow/actions/shell.html) with 
AWS cli and the following command: aws s3 ls 
s3://sdi-snowflake-bucket/snowflake-data/fake-data.csv
   
   Also, downloading a file from S3 using aws cli and the following command 
works: aws s3 cp s3://sdi-snowflake-bucket/snowflake-data/fake-data.csv .
   
   Additionally, the AWS credentials set as system environment variables work 
fine with variable substitution when targeting a S3 bucket with the “COPY INTO” 
sql statement from Snowflake. 
   
   Lastly, I would like to mention that it is possible to upload and download 
files from our S3 bucket when everything is set to a public access level in AWS 
using the “Text File Input/Output” action. However, the credentials don't work 
otherwise with the "Text File Input" action through the VFS connection to AWS, 
even though they work fine using AWS cli and the “Execute SQL Script” action in 
hop.
   
   ### Issue Priority
   
   Priority: 2
   
   ### Issue Component
   
   Component: VFS


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@hop.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to