So I have ran the following commands to initialize my amplify project:
amplify configure
amplify init
Then i run amplify add api.
when I select "REST" api, it says "There was an error adding the API resource" Running amplify status confirms that nothing was added. However, when I try to add the "GraphQL" api, it gives me the same error message, but running amplify status indicates that it was actually added successfully.
i want to add REST api to my amplify app. Not sure what the issue is. I have tried updating amplify cli and reinitializing my project multiple times. thanks in advance.
I am seeing a similar error in the step:
Try opening with system-default editor instead?
The error is:
There are 2 options that helped me
On this step select No
Install xdg-utils: sudo yum -y install xdg-utils (I am using EC2 linux 2 instance)
Try these options and let's see if it helps you.
Related
This questions maybe already asked but that is not solve my issue.
I'm trying to deploy my gactions script in google cloud function. So for that I have installed the gactions CLI in Ubuntu 20.04 machine, but I'm having some problems.
The mentioned gactions CLI comments not working in terminal, it's shows [ERROR] unknown command "test" for "gactions" error message.
Eg: gactions test --action_package action.json --project PROJECT_ID
Am using gactions version 3.2.0. Please suggest me how to use those comments in terminal.
I have tried with sudo gactions test --action_package action.json --project PROJECT_ID that also not working.
As the error [ERROR] unknown command "test" for "gactions" describes that the test command is not validating by the gactions CLI.
Might be due to below reasons, can you you have a check on this :
As per this official doc , you are trying to execute the text command
but make sure the action package name given by you is correct.
Can you try any other arguments mentioned in the gactions supported
arguments doc and have a try whether those are validating or not.
Enable the Actions API in the Google Cloud console by following the
instructions in Enable and disable APIs. This allows gactions to
interact with your project.
Make sure you have installed the gactions CLI correctly by running
the command 'gactions version' to check the version number. If the
version number matches the version you installed, then the CLI is
probably installed correctly. If not reinstall the CLI using this
gactions overview
I’ve been trying to deploy my svelte-kit project to aws amplify but whenever I do, despite the build and deploy stages being successful, the page returns a 404 error. I’ve changed the build settings to '/build' which is the output directory I've specified, and I'm using svelte-js/adapter-node but have tried a few other adapters. When I download the build artifacts from aws the build is the exact same as what is produced locally (by npm run build).
Build Log Image
Amplify Domain returns: "No web page was found for the web address:"
I've attatched an image of the end of the amplify build, which includes the warning 'no index.html found' as svelte-kit doesn't seem to produce an index.html. Does anyone know how to fix this issue? Anyway to deploy a dynamic svelte project to amplify is what I'm looking for.
I flipped over to using adapter-static (and svelte kit) and it seems to work for me.
I am using serverless framework along with localstack and getting a failed deploy with the error message
View the full error output: https://us-east-1.console.aws.amazon.com/cloudformation/home?region=us-east-1#/stack/detail?stackId=arn%3Aaws%3Acloudformation%3Aus-east-1%3A000000000000%3Astack%2Fpond5-api-local%2F00457845
That link will ask me to sign into AWS console... but i am running with localstack a mock environment, where can i get info about the failed deploy?
You're right, the link in the output directly points to AWS. I would suggest taking a look at the localstack logs as those will contain more detailed information about why the deployment failed. You can set DEBUG=1 in the environment for troubleshooting issues.
Additionally, you can display more logs from the serverless deploy command by setting SLS_DEBUG=* in your environment (but those were often not very helpful for me)
We have updated emr version for emr-5.30.0.Since then we are getting error in bootstrap.
"Terminated with bootstrap error"
If i change version back to emr-5.29.0 it work fine.I am not able to find reason for bootstrap error.
We are creating EMR cluster from step function.
We have changed version emr-5.29.0 to emr-5.30.0 as we are adding managed autoscalling and it supports only after 5.29.0
I checked logs but could not find any proper error message. Please suggest some pointers to troubleshoot this.
EMR version changes many thing including different applications you select to include like #Snighdhajyoti mentioned for example in emr 5.29.0 spark had version 2.4.4 and in emr 5.30.0 spark has version 2.4.5. You can see the basic list of application changes here.
But the point is, there can be some application or package that you install or configure in bootstrap scipt manually which might be conflicting with the other updated package.
For logs, bootstrap logs dont appear in cluster logs but are in stderr logs for your bootstrap action like below
s3://doc-example-bucket/cluster-id/node/instance-id/bootstrap-actions/
This link provides some more guidance how can you dig down the error, for example
If you can't determine why the script failed after reviewing the
stderr logs, modify your script to provide additional debug
information. For example, set the -ex parameters in the bash script.
This allows you to view the bash script flow in the bootstrap action
log files.
Note: If the failed bootstrap action isn't a bootstrap action that you
created (for example, if you created six bootstrap actions and the
error message is "bootstrap action 7 failed with non-zero exit code"),
it indicates that Amazon EMR couldn't install applications or start
services. This problem is rare. To resolve this issue, try launching
the cluster again.
I'm having the sample problem as Vaclav. I've followed the GCR quick start to the letter which entailed creating a new project (called gcr-project) and copying the code for a Flask (python) app.
After building the docker image, I entered the commands:
gcloud auth configure-docker
docker tag quickstart-image gcr.io/gcr-project/quickstart-image:tag1
docker push gcr.io/gcr-project/quickstart-image:tag1
The response was:
unauthorized: You don't have the needed permissions to perform this operation, and you may have invalid credentials. To authenticate your request, follow the steps in: https://cloud.google.com/container-registry/docs/advanced-authentication
So it would be nice to know if the issue is with the credentials (I'm using cloud SDK OK for other projects) or permissions. The documentation here suggests you need storage-admin rights but the projects already has it, see screen cap here
Would appreciate any tips for trouble shooting this as I was looking for to using the GCR but this problem is a hard stop for me.
UPDATE:
I tried the same process with the cloud shell
me#cloudshell:~ (gcr-project-XXXXXX)$ docker push gcr.io/gcr-project/quickstart-image:tag1
The push refers to repository [gcr.io/gcr-project/quickstart-image]
4399528b7213: Preparing
1d10b1eeca74: Preparing
75156020d862: Preparing
c5697656a146: Preparing
2a435270de82: Preparing
c35f70b5c25a: Waiting
28e260baaf1b: Waiting
556c5fb0d91b: Waiting
denied: Token exchange failed for project 'gcr-project'. Please enable Google Container Registry API in Cloud Console at https://console.cloud.google.com/apis/api/containerregistry.googleapis.com/overview?project=gcr-project before performing this operation.
me#cloudshell:~ (gcr-project-XXXXXX)$
This prompted me to check the API & Services dashboard to confirm the container-registry API was enabled - It is.
UPDATE 2:
I'm having these problems on a machine running ubuntu 19.04. Per the comments below I was able to do a push via the cloud shell. So I then went through the same exercise on a MacBook Pro - worked no problems.
So I then uninstalled Cloud SDK per the doco having used the standard linux install instructions previously. I then re-installed using the debian-ubuntu install instructions (version 274.0.1-0)... STILL no go.
When I do a docker pull on the image (because push worked on MBP) I get this error: Error response from daemon: unauthorized: You don't have the needed permissions to perform this operation, and you may have invalid credentials. To authenticate your request, follow the steps in: https://cloud.google.com/container-registry/docs/advanced-authentication
And when I do a push I get this error: unauthorized: You don't have the needed permissions to perform this operation, and you may have invalid credentials. To authenticate your request, follow the steps in: https://cloud.google.com/container-registry/docs/advanced-authentication
So at this stage, given the success on the MBP and the lack thereof on the linux/ubuntu machine, the problem is constrained to to linux/ubuntu installs.
UPDATE 3:
I got on to a separate ubuntu server, did a clean install with sudo snap install google-cloud-sdk --classic , did everything else per the docs and still had the exact same problem. So I recon this is a linux google cloud SDK specific problem.
Is there anyone out there Ubuntu land who as been able install and use cloud SDK with GCR recently?????????
I was able to replicate this issue on multiple ubuntu machines. I tried again after the most recent cloud SDK update (276.0.0) but had no luck.
In the end I went with json key file authentincati described in the docs here as a work around which worked fine.