Questions tagged [aws-cli]

The AWS Command Line Interface (CLI) is a unified tool to manage AWS services.

The AWS Command Line Interface (CLI) is a unified tool to manage AWS services. Multiple AWS services can be controlled via the command line and various actions can be automated through this tool.

Questions involving an alternate implementation for Windows PowerShell, AWS Tools for PowerShell, should be tagged with instead.

Resources

3275 questions
1
vote
1 answer

How to automatically switch policies of roles (Terraform)

I've created 2 roles using Terraform (Engineering.tf, Finance.tf)- Engineering with AdministratorAccess policy, and -Finance with Billing policy. I need to write a script to switch the roles policies every 10 min (endless loop) I'm not sure how to…
1
vote
1 answer

How can access to My AWS account's console and API be limited to connections from my VPN?

I want to limit access to my AWS account to my VPN. I see the option of using sourceIP for IP whitelisting, alowing my proxy's and AWS IPs. Is there a way to do limit the calls to AWS API to VPN as well? I am not looking for VPC endpoint blocking.
user6317694
  • 743
  • 1
  • 4
  • 17
1
vote
2 answers

boto3 cannot import name copy

I installed boto3 few weeks ago and all worked fine until now tried to reinstall pip, reinstall boto3,reinstall aws cli, update machine (yum update) but nothing helped File "./get_reports.py", line 4, in import boto3 File…
Milister
  • 576
  • 7
  • 27
1
vote
2 answers

how to see console.log in AWS lambda functions

Where do you see the console.log() calls made inside of AWS Lambda functions? I looked at AWS Cloud Watch event log and didn't see them there. Is there a CLI way to see them?
honkskillet
  • 2,374
  • 1
  • 27
  • 41
1
vote
2 answers

AWS lambda update-function-code with jar package via AWS CLI

I'm trying to update my lambda function code with jar from my local machine via AWS CLI. The aws lambda has commands to update function code for zip file but not for jar. I can upload by using s3 bucket, but I need to update from local itself. I…
Vinod Singh
  • 55
  • 3
  • 8
1
vote
1 answer

How to stop all stack operations currently running in cloud formation?

Probably everyone that has worked before with CloudFormation knows how annoying it is when you run a provision or an update for one of your CloudFormation stacks and you realise you made a mistake. You then have to wait hours or days before all the…
1
vote
1 answer

AWS IoT CLI - list-things returning empty list

I created a thing in the AWS IoT console, assigned certificate and policies. I tested aws iot list-things and I got: { "things": [] } But, as I told, there is a thing created. Same occurs with list-certificates. Any help?
Dalton Cézane
  • 3,016
  • 2
  • 24
  • 48
1
vote
1 answer

How to provide blob of graphql schema to aws appsync api?

I am trying to use aws appsync api (StartSchemaCreation) to create schema of a new graphql api with the schema of an existing graphql api, that I dumped with GetIntrospectionSchema api of aws appsync. But the --definition param of…
Tapan Halani
  • 142
  • 8
1
vote
1 answer

Elastic Beanstalk confused about application versions?

When I run eb deploy I get ERROR: You cannot have more than 500 Application Versions. Either remove some Application Versions or request a limit increase. however, there is currently only one version of the application, and I can't delete that one…
Anders Martini
  • 616
  • 9
  • 27
1
vote
1 answer

Installing awscli without internet

I am trying to install awscli on a RHEL machine. Python 2.7.5 is installed, the machine does not have internet access. I have installed setuptools 38.5.2 and setuptools_scm 1.15.7 from sources successfully. Here is the command I have tried to run…
Vincent Teyssier
  • 1,900
  • 4
  • 22
  • 47
1
vote
1 answer

How to extract specific section from JSON and convert it to CSV

Part of output.json (file has multiple same sections-only role/policy name differs) full link:https://1drv.ms/u/s!AizscpxS0QM4hJl_VRQaWbm6D8T8_w { "AssumeRolePolicyDocument": { "Version": "2012-10-17", "Statement": [ { …
Milister
  • 576
  • 7
  • 27
1
vote
1 answer

aws-cli: getting error "argument --user-pool-id is required"

I am trying to get user information from cognito user pool using aws-cli. According to aws-cli documentation the synopsis should be like this: admin-get-user --user-pool-id --username [--cli-input-json…
Mahbubur Rahman
  • 4,261
  • 2
  • 28
  • 43
1
vote
1 answer

How to update AWS CloudFront error page response path via CLI?

Looking for a way to update the CloudFront instance error pages with the command line for continuous integration purposes. Have had some success with the update-distribution command for the root page but can't seem to figure out how update the the…
codeisforeva
  • 451
  • 4
  • 19
1
vote
1 answer

Download Lambda code using CLI

Planning to have code revision for our Lambda code. In-order to automate, I tried using get-function of AWS Lambda CLI. It returns configuration information with a location to the code. eg : { "Code": { "RepositoryType": "S3", "Location":…
Vineeth
  • 555
  • 1
  • 7
  • 16
1
vote
0 answers

aws s3 sync by cron doesn't work

I run command: /usr/bin/aws s3 sync --delete /var/www/html/wp-content/uploads s3://yemaoplanet-blog-mediaassets and it works. also, I tried to do command with --dryrun flag : /usr/bin/aws s3 sync --delete /var/www/html/wp-content/uploads…