Saravanan666/pypi-org huggingface dataset:
Package: aws-role-switcher
aws_role_switcherThis is a CLI application makes it easier to switch roles using auto completion from parsing your aws config/credential file and setting"AWS_SECRET_ACCESS_KEY", "AWS_ACCESS_KEY_ID", "AWS_SESSION_TOKEN", "AWS_SECURITY_TOKEN"environment variables if present.This script does not support MFA roles, and designed to help cycle through profiles set manually, or as output from an SSO script like:https://github.com/Nike-Inc/gimme-aws-credsInstallationpython3 -m pip install -U aws_role_switcherIn order to work properly this script must be sourced, add the following to your .profile or .bashrc( you can adjust the alias name to whatever you want)alias ars='source aws-role-switcher.sh'Note: You can run this from the command line using. aws-role-switcher.shorsource aws-role-switcher.sh.ConfigurationYou can set the following environmental variables:AWS_PROFILE_SWITCHER_PATH- Override the default credential/config file location from$HOME/.aws/credentialsI would recommend adding to your ~/.profile or ~/.bash_profileExample Usagearsto start prompt. TAB or start typing to start auto completion list. TAB or use arrows to cycle through list, and enter to select.Pass profile and region positional variables (Optional)using a format of<script> <profile_arg> <region_arg>the utility will start the prompt process with the passed in args
i.ears admin uswest2Example config file:[default]
aws_access_key_id = REDACTED
aws_secret_access_key = redacted
aws_session_token = default
aws_security_token = default

[testing-administrator]
aws_access_key_id = REDACTED
aws_secret_access_key = redacted
aws_session_token = testing
aws_security_token = testing


[staging-administrator]
aws_access_key_id = REDACTED
aws_secret_access_key = redacted
aws_session_token = staging
aws_security_token = staging


[production-administrator]
aws_access_key_id = REDACTED
aws_secret_access_key = redacted
aws_session_token = production
aws_security_token = productionExample Usage:Updated Example (1.5.0):DevelopmentBug Reports & Feature RequestsPlease use the submit a issue to report any bugs or file feature requests.DevelopingIf you are interested in being a contributor and want to get involved in developing this CLI application feel free to reach outIn general, PRs are welcome. We follow the typical trunk based development Git workflow.Branchthe repoClonethe project to your own machineCommitchanges to your branchPushyour work back up to your branchSubmit aMerge/Pull Requestso that we can review your changesNOTE:Be sure to merge the latest changes from "upstream" before making a pull request!
Package: aws-rotate
aws-rotateRotate AWS Access Keys and update local credentials file.It's good practise to rotate access IDs and keys for AWS IAM users, but a pain to do, this simple script automates the processInstallationCreate a python virtual environment and activate itpip install aws-rotateUsageMake sure you have the relevant AWS_PROFILE environment variable set or the default profile will be used seeaws credentialsaws-rotate-keysDevelopmentClone this repo and install the dev packagespip install -e ".[dev]"Once you have made changes and the test pass create a pull request
Package: aws-s3-cli
aws-s3-cli :aws s3 bucket cli

upload, download, check file availability, and get all available list from AWS s3 bucket.Package Installation :pip install aws-s3-cliPypi Package LinkHow to import the module:FILE_OBJ=""# File objectFILE_NAME=""# File nameS3_FILE_NAME=""# S3 file name or uploaded file nameBUCKET_NAME=""# Bucket nameAWS_ACCESS_KYE=""# Access key IDAWS_SECRET_ACCESS_KYE=""# Secret access keyUpload File :fromaws_s3_cli.aws_s3_cliimportupload_filestatus=upload_file(BUCKET_NAME,AWS_ACCESS_KYE,AWS_SECRET_ACCESS_KYE,FILE_OBJ,FILE_NAME)print(status)Download File :fromaws_s3_cli.aws_s3_cliimportdownload_filestatus=download_file(BUCKET_NAME,AWS_ACCESS_KYE,AWS_SECRET_ACCESS_KYE,S3_FILE_NAME,FILE_NAME)print(status)Check File Status :fromaws_s3_cli.aws_s3_cliimportcheck_file_statusstatus=check_file_status(BUCKET_NAME,AWS_ACCESS_KYE,AWS_SECRET_ACCESS_KYE,S3_FILE_NAME)print(status)Get All File List :fromaws_s3_cli.aws_s3_cliimportget_all_file_listfile_list=get_all_file_list(BUCKET_NAME,AWS_ACCESS_KYE,AWS_SECRET_ACCESS_KYE)print(file_list)Get All File Dictionary :fromaws_s3_cli.aws_s3_cliimportget_all_file_dictfile_dict=get_all_file_dict(BUCKET_NAME,AWS_ACCESS_KYE,AWS_SECRET_ACCESS_KYE)print(file_dict)Required package’s:• pip install boto3License:MIT LicensedAuthor:Sujit MandalGitHubPyPiLinkedIn
Package: awss3filebrowser
=====awss3filebrowser=====awss3filebrowser is a simple Django app to browser AWS S3 BUCKET.You can create folder, delete folder and files, rename,upload file and get details .Feature List:1. Create Folder2. Delete Folder and files3. Upload files4. Rename Files and folders5. File Details6. Cut/Copy and pasteQuick start-----------pip install awss3filebrowser1. Add "awss3browser" to your INSTALLED_APPS setting like this::INSTALLED_APPS = [...'awss3browser',]2. Include the polls URLconf in your project urls.py like this::url(r'^filebrowser/', include('awss3browser.urls')),3. ADD SETTINGS to settings.pyAWS_ACCESS_KEY_ID = 'YOUR_AWS_KEY_ID'AWS_SECRET_ACCESS_KEY = 'YOUR_AWS_SECRET_ACCESS_KEY'AWS_STORAGE_BUCKET_NAME = 'YOUR_AWS_STORAGE_BUCKET_NAME'AWS_STORAGE_BUCKET_ROOT_FOLDER = 'YOUR_AWS_STORAGE_BUCKET_ROOT_FOLDER' // for example AWS_STORAGE_BUCKET_ROOT_FOLDER = 'public' is the root folder of my s3 bucket4. Visit 'http://127.0.0.1:8000/filebrowser/files/' to see the filelist.
Package: aws-s3-resource
aws-s3-resourceIntroductionGetting StartedExampleContributorsLicenseIntroductionThis library is to ease the operations done on AWS S3 buckets and objectsGetting StartedIn order to install,open the command prompt and type ✌️:pip install aws_s3_resourceExampleIn order to use refer to the followingexampleContributorsThis project exists thanks to all the people who contribute. [Contribute].""LicenseThis library is licensed under the MIT License - see theLICENSE.mdfile for details.
Package: aws_s3sync
# aws_s3sync## Installation`pip install aws_s3sync`## Execution#### Pre-requisitesSetup the following environment variables* **AWS_ACCESS_KEY_ID*** **AWS_SECRET_ACCESS_KEY**#### Commands`sync_to_s3``sync_from_s3`#### Arguments```-h, --help            show this help message and exit-b BUCKET, --bucket BUCKETUpload: Selects the S3 bucket to upload data to.Download: Selects the S3 bucket to download data from-f FILE_PATH, --file_path FILE_PATHUpload: Path of the file to be uploaded. Download:Path to download file to-k KEY, --key KEY     Key of the object. Same as file_path is undefined forupload-m {auto,sync,single-part-upload}, --mode {auto,sync,single-part-upload}Mode of upload/download--chunk_size CHUNK_SIZESize of chunk in multipart upload in MB--multipart_threshold MULTIPART_THRESHOLDMinimum size in MB to upload using multipart```##### Mode* `auto` : Upload: Single-part upload or multi-part upload will be chosen based on the file being smaller/larger than `multipart_threshold`* `sync` : Upload/downloand file to/from S3 only if the local/remote file have different signatures. Checked based on ETag/MD5* `single-part-upload` : Force single-part upload. Applicable only for files of size larger than `multipart_threshold`
Package: aws-s3-tools
AWS S3 ToolsAWS S3 Tools is a Python package to make it easier to interact with S3 objects, where you can:List S3 bucket contentCheck if an S3 object existsDownload/upload S3 objects to/from local filesRead/write S3 objects into/from Python variablesDelete/move/copy S3 objectsThe AWS S3 authentication is done via boto3 package, via environment variables, aws config file, or parameters.
All S3 objects functions, in this package, have the option to set AWS Session authentication by passing the following dictionary on theaws_authparameter, with the schema below (not all field are required).
To understand more about AWS authentication mechanism,read boto3 documentation.aws_auth={'region_name':'REGION','aws_access_key_id':'ACCESS_KEY','aws_secret_access_key':'SECRET_KEY','aws_session_token':'SESSION_TOKEN','profile_name':'PROFILE_NAME'}InstallationYou can install AWS S3 Tools from PyPi withpipor your favorite package manager:pipinstallaws-s3-toolsAdd the-Uswitch to update to the current version, if AWS S3 Tools is already installed.If you want to use theprogress barfeature when downloading or uploading,
you need to install an extra dependency.pipinstallaws-s3-tools[progress]UsageThe full documentation can be found here.froms3_toolsimportobject_existsifobject_exists("my-bucket","s3-prefix/object.data"):# Your code goes hereelse:print("Object not found")Example to use the progress bar:froms3_toolsimportupload_folder_to_prefixresult=upload_folder_to_prefix(bucket='dlite-tools',prefix='aws-s3-tools',search_str='*.py',threads=2,folder='s3_tools',show_progress=True)Progress bar when running the code above:ContributionsAll contributions, bug reports, bug fixes, documentation improvements,
enhancements and ideas are welcome.A detailed overview on how to contribute can be found in thecontributing guideon GitHub.IssuesGohereto submit feature
requests or bugfixes.License and CreditsAWS S3 Toolsis licensed under theMIT licenseand is written and
maintained by:Daniel Ferrari (@FerrariDG)Carlos Alves (@cmalves)Tomás Osório (@tomassosorio)AcknowledgementThe idea from these functions come from an amazing team that I worked with. This repo is a refactor and documentation to make this public to everyone.Many thanks to:Anabela NogueiraCarlos AlvesJoão MachadoRenato DantasRicardo GarciaTomás Osório
Package: aws-s3-url2uri
[![Circle CI](https://circleci.com/gh/keisuke-nakata/aws-cli-s3-url2uri.svg?style=shield&circle-token=d6eef26322de7a44559b42d363878b08e0a20cbf)](https://circleci.com/gh/keisuke-nakata/aws-cli-s3-url2uri)# aws-cli-s3-url2uriMakeaws s3commands work with URL showed in AWS web console.`bash aws_s3_url2uri ls"https://console.aws.amazon.com/s3/home?region=<your_region>#&bucket=mybucket&prefix=mydir/"--profilemyprof `will be converted into`bash aws s3 lss3://mybucket/mydir/--profilemyprof `# install`bash pip installaws-s3-url2uri`and commandaws_s3_url2uriwill be available.
Package: aws-sa
aws-script-automationScripting for AWS API configurations automationInstalationUse pip to make instalation:pip install --user aws-saLoading documentation files to deployJust pass the file path in the argument:aws-sa [filepath .json or .yaml]Examples:aws-sa file.yamloraws-sa /home/user/Documents/file.jsonConfigurationAt the first time you need from AWS API key fromIAM User.Insert de values into the next steps:AWS Access Key ID:<YOU_AWS_ID>AWS Secret Access Key:<SECRET_KEY>Default region name:<YOUR_REGION>First step: Configure endpointsInsert the Authorization key and domain from endpoints:Insert Authorization key (example: asd09aus81923aas112): <AUTHORIZATION_KEY>Insert Domain (example: https://example.com): <DOMAIN_WITH_HTTP(S)>After insert the name from deploy:Insert Deploy Name [prod]: <DEPLOY_NAME>The values ​​are stored if you want to use them later (bracketed value). If you want to use it, just press enter in the field.Second step: Configure CloudWatch GroupInsert the name from CloudWatch group:Insert CloudWatch Group [example]: <NAME_GROUP>third step: Configure custom domainSelect a custom domain using arrow keys.Insert value from Base path:Insert Base Path [v1]: <BASE_PATH>OutputA documentation file with the same name as the imported file will be generated with the ending.prod.yaml.Set name APIYou can use different names from documentation file using:aws-sa [file] --name [new_name]Example:aws-sa file.yaml --name testObservation: You only can use this command on create, not permitted in merge or overwrite.Use temporary regionYou can use a temporary region into API using:aws-sa [file] --region [region_name]Example:aws-sa file.yaml --region us-east-2You can find the region valueshere.Change RegionYou can change the default region using:aws configure set default.region [region]Merge or overwrite documentation fileYou can merge or overwrite a API with another documentation file using:aws-sa [file] --id <ID_API> [--overwrite|--merge]Configure automatically gateway-responsesYou can configure automatically gateway-responses using:aws-sa --id <ID_API> [--gateway-response]
Package: aws-sagemaker-remote
Remotely run and track ML research using AWS SageMaker.Standardized command line flagsRemotely run scripts with minimal changesAutomatically manage AWS resourcesAll code, inputs, outputs, arguments, and settings are tracked in one placeReproducible batch processing jobs to prepare datasetsReproducible training jobs that track hyperparameters and metricsTrack three types of objects in a standard way:Processing jobs consume file inputs and produce file outputs. Useful for data conversion, extraction, etc.Training jobs train models while tracking metrics and hyperparameters.Inference models provide predictions and can be deployed on endpoints. Can be automatically created from and linked to training jobs for tracking purposes or can deploy externally-created models.InstallationReleasepipinstallaws-sagemaker-remoteDevelopmentgitclonehttps://github.com/bstriner/aws-sagemaker-remotecdaws-sagemaker-remotepythonsetup.pydevelopDocumentationView latest documentation atReadTheDocsContinuous IntegrationView continuous integration atTravisCIPyPIView releases onPyPIGitHubView source code onGitHubGitHub tags are automatically released on ReadTheDocs, tested on TravisCI, and deployed to PyPI if successful.
Package: awssaml
PurposeAccess to the AWS Management Console and AWS API for my Active Directory users using federation (AD FS 2).
Use Keyring tool for store password.Main featuresSupport AD FS 2 and AD FS 4Allow to login to AWS ConsoleALlow to generate AWS Access KeyUsageRequirementsLinux (tested on Ubuntu 19.04+) or Windows (tested on 10)Python 3 -latest version 3.xPython 2 backward compatibleon Windows,pycryptorequireMicrosoft Visual C++ Build ToolsInstallationpip3 install awssamlConfiguration fileAll configuration is stored in~/.aws/configfile.Basic configuration[samlapi]
identity_url = https://adfs.example.com/adfs/ls/IdpInitiatedSignOn.aspx?loginToRp=urn:amazon:webservices
region = eu-west-1
adfs_connection = ntlmAdvanced samlapi configurationUse different ADFS connection methodsntlm- Use NTLM authentication (default)web_form- Use web form authenticationSet default username[samlapi]
#...
username = [SAML User]Default session durationSetup 12 hours (it's 43200 seconds):[samlapi]
#...
session_duration = 43200Advanced profile configurationYou can setup custom profiles to reuse.
Sample configuration entry for profile:[profile nonprod-application1]
role_arn = arn:aws:iam::[ID]:role/[role]
principal_arn = arn:aws:iam::[ID]:saml-provider/[provider]
source_profile = nonprod
session_duration = 43200Usage:> awssaml api nonprod-application1
> awssaml console nonprod-application1ReferenceHow to Implement Federated APIHow to grant my Active Directory users access to the API or AWS CLI with AD FS?
Package: awssamlpy2
As part of AWS Governance to enhance the security with the accounts and IAM users, Federated API access is recommended for AWS resources instead of hard-coded IAM AccessID and SecretKeys in the config file.# Steps:If this is the first time install of this python package, use below command:For Python2.x version, pip install awssamlpy2
For Python3.x version, pip install awssamlpy3To upgrade this python package to latest version, use below command:For Python2.x version, pip install awssamlpy2 –upgrade
For Python3.x version, pip install awssamlpy3 –upgradeCreate a ‘.awssaml.properties’ (~/.awssaml.properties) file under your user home directory like below -[UserProp]
aws-region=us-east-1
aws-outputformat=json
idpurl=https://<Your Company AWS SAML Domain>/adfs/ls/IdpInitiatedSignOn.aspx?loginToRp=urn:amazon:webservicesPlease refer to Mesh DOC-111675 for the idpurlCreate a ‘configure’ file under ~/.aws directory without providing the values for access and secret keys. Dont worry if haven’t yet; the package will automatically create one if this file is not present. You may just choose the output and region fields as per your need.[default]
output = json
region = us-east-1
aws_access_key_id =
aws_secret_access_key =We have taken care to package the required modules. But if there are any additional packages required, install the missing modules based on the error encountered like below:On Linux, pip install <module>Eg: pip install requestsOn Windows, easy_install <module>Eg: easy_install requestsWhenever you need SAML access to your AWS services, just the command:aws-samlThis does the following:Verifies your ~/.aws/configure file to set the approriate region; OR creates one if its not presentPrompts the user for AD username/password and does SAML auth with our ADFSNOTE: Username has to be in the format <domain><networkID>Based on SAML response, prompts the user to choose the roles available on AWS for that userThen, stores the temporarily created credentials (using Amazon STS service) for the user in the ~/.aws/credentials file along with STS tokenUse API calls to work on AWS resourcesSample API call used in the script is for listing the S3 buckets, which is in Boto2.x format
Package: awssamlpy3
As part of AWS Governance to enhance the security with the accounts and IAM users, Federated API access is recommended for AWS resources instead of hard-coded IAM AccessID and SecretKeys in the config file.# Steps:If this is the first time install of this python package, use below command:For Python2.x version, pip install awssamlpy2
For Python3.x version, pip install awssamlpy3To upgrade this python package to latest version, use below command:For Python2.x version, pip install awssamlpy2 –upgrade
For Python3.x version, pip install awssamlpy3 –upgradeCreate a ‘.awssaml.properties’ (~/.awssaml.properties) file under your user home directory like below -[UserProp]
aws-region=us-east-1
aws-outputformat=json
idpurl=https://<Your Company AWS SAML Domain>/adfs/ls/IdpInitiatedSignOn.aspx?loginToRp=urn:amazon:webservicesPlease refer to Mesh DOC-111675 for the idpurlCreate a ‘configure’ file under ~/.aws directory without providing the values for access and secret keys. Dont worry if haven’t yet; the package will automatically create one if this file is not present. You may just choose the output and region fields as per your need.[default]
output = json
region = us-east-1
aws_access_key_id =
aws_secret_access_key =We have taken care to package the required modules. But if there are any additional packages required, install the missing modules based on the error encountered like below:On Linux, pip install <module>Eg: pip install requestsOn Windows, easy_install <module>Eg: easy_install requestsWhenever you need SAML access to your AWS services, just the command:aws-samlThis does the following:Verifies your ~/.aws/configure file to set the approriate region; OR creates one if its not presentPrompts the user for AD username/password and does SAML auth with our ADFSNOTE: Username has to be in the format <domain><networkID>Based on SAML response, prompts the user to choose the roles available on AWS for that userThen, stores the temporarily created credentials (using Amazon STS service) for the user in the ~/.aws/credentials file along with STS tokenUse API calls to work on AWS resourcesSample API call used in the script is for listing the S3 buckets, which is in Boto2.x format
Package: awssamlwindows
As part of AWS Governance to enhance the security with the accounts and IAM users, Federated API access is recommended for AWS resources instead of hard-coded IAM AcessID and SecretKeys in the config file.# Steps:
- Install the python package based on the OS using below command:For Linux environment, pip install awssamllinux
For Windows environment, pip install awssamlwindowsCreate a ‘configure’ file under ~/.aws directory without providing the values for access and secret keys[default]
output = json
region = us-east-1
aws_access_key_id =
aws_secret_access_key =Based on the Python version and installation, the script might throw errors due to missing modules on your system like below -requests
html5lib
configparserInstall the required modules:On Linux, pip install <module>Eg: pip install requestsOn Windows, easy_install <module>Eg: easy_install requestsWhenever you need SAML access to your AWS services, just the command:aws-saml.pyThis does the following:Prompts the user for AD username/password and does SAML auth with our ADFSNOTE: Username has to be in the format rpega<networkID>
Eg: rpegamn001Based on SAML response, prompts the user to choose the roles available on AWS for that userThen, stores the temporarily created credentials (using Amazon STS service) for the user in the
.aws/credentials file along with STS tokenUse API calls to work on AWS resourcesSample API call used in the script is for listing the S3 buckets, which is in Boto2.x format
Package: aws-sam-translator
AWS SAM transformTheAWS Serverless Application Model(AWS SAM) transform is aAWS CloudFormation macrothat transformsSAM templatesintoCloudFormation templates.To use the SAM transform, addAWS::Serverless-2016-10-31to theTransformsectionof your CloudFormation template.Benefits of using the SAM transform include:Built-in best practices and sane defaults.Local testing and debugging with theAWS SAM CLI.Extension of the CloudFormation template syntax.Getting startedSave the following astemplate.yaml:Transform:AWS::Serverless-2016-10-31Resources:MyFunction:Type:AWS::Serverless::FunctionProperties:Runtime:nodejs18.xHandler:index.handlerInlineCode:|exports.handler = async (event) => {console.log(event);}And deploy it with theSAM CLI:samsync--stack-namesam-appTheAWS::Serverless::Functionresource will create aAWS Lambdafunction that logseventsit receives.Under the hood, the template is transformed into the JSON equivalent of the following CloudFormation template:Resources:MyFunction:Type:AWS::Lambda::FunctionProperties:Code:ZipFile:|exports.handler = async (event) => {console.log(event);}Handler:index.handlerRole:!GetAttMyFunctionRole.ArnRuntime:nodejs18.xTags:-Key:lambda:createdByValue:SAMMyFunctionRole:Type:AWS::IAM::RoleProperties:AssumeRolePolicyDocument:Version:"2012-10-17"Statement:-Action:-sts:AssumeRoleEffect:AllowPrincipal:Service:-lambda.amazonaws.comManagedPolicyArns:-arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRoleTags:-Key:lambda:createdByValue:SAMFor a more thorough introduction, see thethis tutorialin theDeveloper Guide.ContributingSetting up development environmentYou'll need to have Python 3.8+ installed.Create avirtual environment:python3-mvenv.venvsource.venv/bin/activateSet up dependencies:makeinitRun tests:makeprSeeDEVELOPMENT_GUIDE.mdfor further development instructions, andCONTRIBUTING.mdfor the contributing guidelines.Getting helpThe best way to interact with the team is through GitHub. You can eithercreate an issueorstart a discussion.You can also join the#samdevchannelon Slack.Learn moreWorkshops and tutorialsThe Complete AWS SAM WorkshopAWS Serverless Developer Experience WorkshopDeploying a "Hello, World!" applicationTesting in the cloud using the SAM CLIDocumentationSAM Developer GuideSAM template specificationSAM connectorsSAM policy templates
Package: aws-satella
aws-satellaA library to export Satella's metrics to AWS CloudWatchInstallationpipinstallaws-satellaUsageimportsysfromaws_satellaimportAWSSatellaExporterThread,InitializationErrortry:aws=AWSSatellaExporterThread('AppNamespace')aws.start()exceptInitializationError:print('Could not initialize the boto3 client')sys.exit(1)This spawns a daemonic thread. For details,
refer to thedocs.You can additionally usefromaws_satellaimportstart_if_not_startedstart_if_not_started(*args,**kwargs)Bothargsandkwargswill be passed to constructor.
This will initialize such thread, if one does not exist already.This also supports easy Django configuration, for details goread the docs.Change logChange log was movedhere.Special thanksMy special thanks go out to the team atMailerrizefor their support.