Questions tagged with AWS Command Line Interface

Content language: English

Sort by most recent

Browse through the questions and answers listed below or filter and sort to narrow down your results.

This works: ```bash aws servicecatalog update-provisioned-product \ --product-name my-product-name \ --provisioned-product-id pp-123 \ --provisioning-artifact-name latest \ --profile mypro ``` This fails: ```bash aws servicecatalog update-provisioned-product \ --product-name my-product-name \ --provisioned-product-id pp-123 \ --provisioning-artifact-name latest \ --profile mypro-github-cdk An error occurred (ResourceNotFoundException) when calling the UpdateProvisionedProduct operation: Product with name my-product-name not found ``` The only difference is the profile - `mypro-github-cdk` assumes the role `arn:aws:iam::1234:role/GitHub-CDK-Deploy`: ``` [profile mypro] region = us-east-1 credential_process = /usr/local/bin/aws_creds aws/mypro [profile mypro-github-cdk] region = us-east-1 role_arn = arn:aws:iam::1234:role/GitHub-CDK-Deploy source_profile = mypro ``` The `arn:aws:iam::1234:role/GitHub-CDK-Deploy` role has the following inline policy, which should allow anything[1]: ```json { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "*", "Resource": "*" } ] } ``` Grateful for any pointers, I'm lost. [1] Yes, I'll drop it down to much more limited permissions once it's working!
1
answers
0
votes
9
views
asked 21 hours ago
The Nameserver given by AWS isn't working as it is supposed to be, how can this be fix with new nameservers?
0
answers
0
votes
8
views
asked 2 days ago
I am using AWS CLI version:aws-cli/2.9.17 Python/3.9.11 Windows/10 exe/AMD64 prompt/off Openssl version: OpenSSL 1.1.1s 1 Nov 2022. I am trying to send http post request to aws IoT using Postman. Create Authorizer in IoT core with the following command: aws iot create-authorizer \ --authorizer-name "my-new-authorizer" \ --token-key-name "tokenKeyName" \ --status ACTIVE \ --no-signing-disabled \ --authorizer-function-arn "arn:aws:lambda:Region:57EXAMPLE833:function:custom-auth-function" \ --token-signing-public-keys FirstKey="-----PUBLIC KEY----" I am getting the following error: aws: error: the following arguments are required: --authorizer-name, --authorizer-function-arn Kindly help
1
answers
0
votes
14
views
asked 3 days ago
How can we access user through command line interface if there is no availability of AWS Access Key ID and AWS Secret Access Key
2
answers
0
votes
16
views
asked 4 days ago
I have administrator access. I follow [Amazon macie Getting Started](https://docs.aws.amazon.com/macie/latest/user/getting-started.html) I make sure that I successfully generate sample findings ![generate sample findings](/media/postImages/original/IMo4J9SFa0SpKZH71LJNdXzQ) But I want to delete bucket: macie-sample-finding-bucket ![delete bucket](/media/postImages/original/IM8Q3uf3QGTwmOWSnNXGoY1Q) however I can not see this bucket in the S3 console ![s3 buckets](/media/postImages/original/IMPNILWcQyRS-SmP7vZ-0L5Q) and in the command ![command](/media/postImages/original/IMw5A2XYt7TAKnuIVhVZNqJw) how to delete this bucket?
3
answers
0
votes
43
views
angle N
asked 4 days ago
I created token signature with the below command: echo -n tokenKeyValue | openssl dgst -sha256 -sign private-key.pem| openssl base64 NOw testing the authorizer by test invoke authorizer in aws CLI with the command: aws iot test-invoke-authorizer \ --authorizer-name my-new-authorizer \ --token tokenKeyValue \ --token-signature {created signature} I am getting an error : unknown options:tokenKeyValue. Please guide
1
answers
0
votes
30
views
asked 5 days ago
I am using the following script to get the list of ec2 instances but running into [1]. I am able to use the same creds with session.get_available_regions(service) and session.client('sts') but it doesn't work with session.resource('ec2', region_name=region). I've verified the clock on the machine and it is synced. I would appreciate any help! ``` session = boto3.Session( aws_access_key_id=key, aws_secret_access_key=secret, ) ec2_instance = session.resource('ec2', region_name=region) for instance in ec2_instance.instances.all(): print(instance) ``` [1] ``` Failed to run listener function (error: An error occurred (AuthFailure) when calling the DescribeInstances operation: AWS was not able to validate the provided access credentials) Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/ops/listener/thread_runner.py", line 120, in run_ack_function_asynchronously listener.run_ack_function(request=request, response=response) File "/usr/local/lib/python3.10/dist-packages/ops/listener/custom_listener.py", line 50, in run_ack_function return self.ack_function( File "/home/ops/codeserver/awsops.py", line 439, in get_ec2_instances for instance in ec2_instance.instances.all(): File "/usr/local/lib/python3.10/dist-packages/boto3/resources/collection.py", line 81, in __iter__ for page in self.pages(): File "/usr/local/lib/python3.10/dist-packages/boto3/resources/collection.py", line 171, in pages for page in pages: File "/usr/local/lib/python3.10/dist-packages/botocore/paginate.py", line 269, in __iter__ response = self._make_request(current_kwargs) File "/usr/local/lib/python3.10/dist-packages/botocore/paginate.py", line 357, in _make_request return self._method(**current_kwargs) File "/usr/local/lib/python3.10/dist-packages/botocore/client.py", line 530, in _api_call return self._make_api_call(operation_name, kwargs) File "/usr/local/lib/python3.10/dist-packages/botocore/client.py", line 960, in _make_api_call raise error_class(parsed_response, operation_name) botocore.exceptions.ClientError: An error occurred (AuthFailure) when calling the DescribeInstances operation: AWS was not able to validate the provided access credentials ```
1
answers
0
votes
26
views
asked 5 days ago
I have granted full access using bucket policy to Anonymous user. With this setting, can anyone upload the objects? If yes, what is the procedure and commands/options using CLI to upload?
1
answers
0
votes
12
views
profile picture
asked 5 days ago
I'm currently trying to deploy a Vue App to ECS. (with EC2) However, when executing the task, it was confirmed that "Essential container in task exited" was the cause of the interruption. Additionally, it returns exit code 1 for details. To check more detailed error logs, get the running container id through the docker-ps command, and docker logs <container-id> | I checked the log by entering the command head. The error log confirmed that msg="CREDENTIALS_FETCHER_HOST_DIR not found, err: stat /var/credentials-fetcher/socket/credentials_fetcher.sock: no such file or directory" module=parse_linux.go. Can you identify the cause of the problem and how to solve it?
0
answers
0
votes
7
views
JuYoung
asked 6 days ago
I have done the following : 1.Added invoke Function "Addpermission"API with the following command. aws lambda add-permission --function-name FunctionName --principal iot.amazonaws.com --source-arn AuthorizerARn --statement-id Id-123 --action "lambda:InvokeFunction" 2.Verify Authorizer Response with the command aws iot test-invoke-authorizer --authorizer-name NAME_OF_AUTHORIZER --token TOKEN_VALUE In AWS CLI. gives the following error: aws: error: argument operation: Invalid choice, valid choices are: And Postman API is still giving {message Forbidden} :( Note:TOKEN_VALUE is up to date
1
answers
0
votes
20
views
asked 7 days ago
When we describe an IoT endpoint for a specific region using the AWS CLI - e.g. for the iot:CredentialProvider and region eu-west-1 - will this IoT endpoint change in future? Or does this endpoint remain stable forever? The question refers to the AWS CLI Command Reference: https://docs.aws.amazon.com/cli/latest/reference/iot/describe-endpoint.html Thank you for your reponses.
1
answers
0
votes
13
views
asked 7 days ago
Hi folks, I am starting to use the aws emr-containers cli and am having an issue as follows. The cli does not display the responses to the requests issued with it (for instance: create-virtual-cluster and describe-virtual-cluster). Only when there is an error it displays the error message, but when the request succeeds it displays nothing. I run the same requests (those for which I am not seeing any response on success) with the --debug option set and found out that the cli is receiving the correct answer from the server. It just does not display it. I also tested on the same machine (MacOS) and same environment a couple of aws emr cli commands and verified that they worked just fine (that is, aws emr api requests display the responses normally on success). Can someone help?
1
answers
0
votes
32
views
asked 7 days ago