0

I am new to appengine and have installed google-cloud-sdk from the AUR(arch user repository) and and the google-appengine-go extention at /opt/google-cloud-sdk

thanks to this I am able to run a dev server using

dev_appserver.py app.yaml

But when using goapp serve I found

goapp: command not found

After adding /opt/google-cloud-sdk/platform/google_appengine:$PATH to my $PATH variable in zshrc and running goapp serve i now get the error.

zsh: permission denied: goapp

if sudo goapp serve

sudo: goapp: command not found

Due to this I am unable to use the updated sdk to run tests using goapp test Thank you in advance for your help.

Gaurav Raghuvanshy
  • 401
  • 1
  • 5
  • 11
  • Make sure you are in the same terminal session where you have updated the PATH. check `which goapp` and `sudo which goapp`. – sahaj Nov 03 '17 at 10:14
  • `which goapp` returns `goapp not found` `sudo which goapp` returns `which: no goapp in ` but when I `ls /opt/google-cloud-sdk/platform/google_appengine` i can see the goapp binary. But cannot use it even if i use the full path or sudo the full path. – Gaurav Raghuvanshy Nov 03 '17 at 18:26
  • Can you reinstall or do a clean install of the google-cloud-sdk to try to see if it will work? – JL-HaiNan Nov 03 '17 at 22:10

1 Answers1

1

I had the same problem and I think I figured out how it usually works.

  1. You download the google cloud sdk (https://cloud.google.com/sdk/downloads)
  2. After downloading and unzipping to the folder where you want to use it you have to executet the ./google-cloud-sdk/install.sh. Appengine is not part of the download. It can be chosen with that install.sh script. it will download items like appengine. Afterwards you have a folder called platform/google_appengine as you mentioned yourself.
  3. You might have to change execution permissions like chmod 755 platform/google_appengine/go*
  4. Add folder platform/google_appengine to the PATH if not done already. The command "which" will not show non-executable binaries. If you did not change permissions it will not show the path, even being within the PATH variable.
Janumar
  • 202
  • 2
  • 7
  • Thanks janumar, I had installed the appengine package by using `gcloud components install app-engine-go`. by `chmod 755 platform/google_appengine/go*` the issue was solved and now I am able to run goapp. Note to use goapp test I need to specify the folder containing the tests. else getting an error. maybe theirs a way around that as well. I changed the permissions but which shows goapp with its path. Any suggestions? – Gaurav Raghuvanshy Nov 04 '17 at 12:28