title: Golang Cloud SDK - gcloud app deploy cannot find import package
body: <p>according to the official documentation for Google App Engine Standard environment (Go API) the "<a href="https://cloud.google.com/appengine/docs/standard/go/download" rel="noreferrer">preferred tooling to deploy a project</a>" is now the <em>Cloud SDK</em> and so we moved to gcloud from goapp.</p>
  
  <p>We are unable to deploy Go projects to GAE because all the sub-packages of every given project can't be found at "deploy time".
  The typical folder structure that we have been using for every GAE project was as follows:</p>
  
  <pre><code>-project-name
  --app.yaml
  --main.go
  --assets
  ---package1
  ---package2
  </code></pre>
  
  <p>When global libraries were put in the system GOPATH everything worked smoothly.</p>
  
  <p>Running <code>gcloud app deploy</code> we now get this:</p>
  
  <pre><code>You are about to deploy the following services:
   - yourproject/default/123456789 (from [/Path/to/app.yaml])
       Deploying to URL: [https://yourproject.appspot.com]
  
  Do you want to continue (Y/n)?  Y
  
  Beginning deployment of service [default]...
  ERROR: (gcloud.app.deploy) Staging command [/path/to/yourproject/app.yaml /var/folders/b6/5ydn0wdn64jd32sxzzz48b7c0000gn/T/tmpbd4oiG] failed with return code [1].
  
  ------------------------------------ STDOUT ------------------------------------
  ------------------------------------ STDERR ------------------------------------
  2017/03/24 10:25:58 failed analyzing /path/to/yourproject: cannot find package "yourpackage" in any of:
          ($GOROOT not set)
          /path/to/gopath/src/yourpackage (from $GOPATH)
  GOPATH: /path/to/gopath
  --------------------------------------------------------------------------------
  </code></pre>
  
  <p>while <code>dev_appserver.py</code> works perfectly keeping the same folder structure.</p>
  
  <p>Did we miss something? 
  How can we deploy to Google App Engine Standard environment using gcloud?</p>
  
  <p>If the project structure needs to be changed: how? Is there official documentation about it?</p>
  
  <p>Thanks in advance,</p>
  
  <p><strong>Edit --</strong> Further infos:</p>
  
  <pre><code>Luigi-Mac-Pro:path/to/yourproject distudio$ gcloud version
  Google Cloud SDK 148.0.0
  app-engine-go 
  app-engine-go-darwin-x86_64 1.9.50
  app-engine-python 1.9.50
  bq 2.0.24
  bq-nix 2.0.24
  core 2017.03.17
  core-nix 2016.11.07
  gcloud 
  gcloud-deps 2017.03.17
  gcloud-deps-darwin-x86_64 2017.02.21
  gsutil 4.23
  gsutil-nix 4.22
  </code></pre>