AWS CLI S3 Proxy Plugin

raw JSON →
0.5 verified Mon Apr 27 auth: no python

A plugin for the AWS CLI that allows using an HTTP proxy for S3 requests only, without affecting other AWS service calls. Latest version is 0.5. Low release cadence; last updated in 2018.

pip install awscli-plugin-s3-proxy
error ImportError: No module named 'awscli_plugin_s3_proxy'
cause Plugin not installed, or Python environment path is incorrect.
fix
Install with pip install awscli-plugin-s3-proxy and ensure the Python environment is active.
error botocore.exceptions.UnknownServiceError: Unknown service: 's3'
cause The plugin may be interfering if named incorrectly or awscli version is too old.
fix
Check that the plugin is properly configured in ~/.aws/config: plugins = s3_proxy (not awscli-plugin-s3-proxy). The module name is 'awscli_plugin_s3_proxy'.
error ValueError: Missing required parameter: 'url'
cause You have enabled the plugin but not set the proxy URL.
fix
Run aws configure set s3_proxy.url http://proxy.example.com:8080 or set AWS_S3_PROXY environment variable.
breaking Plugin requires awscli version 1.x; not compatible with AWS CLI v2 (which does not support plugins in the same way).
fix Use AWS CLI v1 or use the AWS CLI's built-in proxy configuration for all services.
gotcha The plugin only proxies S3 requests if the URL starts with 's3://' or the service is 's3'. Other AWS service calls are unaffected.
fix Ensure you only expect S3 traffic to be proxied; do not rely on this plugin to proxy other API calls.
gotcha If you set the proxy via environment variable, ensure it does not conflict with the aws configure setting. The plugin checks environment variable first.
fix Use consistent configuration; either use the config file or the env var, not both with different values.

Enable the plugin via AWS CLI configuration or environment variable. Then S3 requests go through the proxy.

aws configure set plugins.s3_proxy awscli-plugin-s3-proxy
aws configure set s3_proxy.url http://your-proxy:8080
export AWS_S3_PROXY=http://your-proxy:8080