title: Deploy ruby api google cloud
body: <p>I'm pretty new to Google cloud and I have this issue when I try to deploy my ruby api to google cloud, here goes what I have done:</p>
  
  <p>I have uploaded my ruby api to github (it works fine on localhost), here >> <a href="https://github.com/guisantogui/it" rel="nofollow noreferrer">https://github.com/guisantogui/it</a></p>
  
  <p>I have been trough hello world google tutorial >> <a href="https://cloud.google.com/ruby/getting-started/hello-world" rel="nofollow noreferrer">https://cloud.google.com/ruby/getting-started/hello-world</a></p>
  
  <p>and it worked as expected, but when I upload my own application I got this <code>http 502 bad gateway</code> message, here goes the logs:</p>
  
  <pre><code>2017-10-30 23:48:53 default[20171030t213633]  =&gt; Booting Puma
  2017-10-30 23:48:53 default[20171030t213633]  =&gt; Rails 5.1.4 application starting in production 
  2017-10-30 23:48:53 default[20171030t213633]  =&gt; Run `rails server -h` for more startup options
  2017-10-30 23:48:53 default[20171030t213633]  Puma starting in single mode... 
  2017-10-30 23:48:53 default[20171030t213633]  * Version 3.10.0 (ruby 2.4.1-p111), codename: Russell's Teapot
  2017-10-30 23:48:53 default[20171030t213633]  * Min threads: 5, max threads: 5
  2017-10-30 23:48:53 default[20171030t213633]  * Environment: production
  2017-10-30 23:48:53 default[20171030t213633]  * Listening on tcp://0.0.0.0:3000 
  2017-10-30 23:48:53 default[20171030t213633] Use Ctrl-C to stop 
  2017-10-30 23:58:01 default[20171030t213633]  "GET /" 502 
  2017-10-30 23:58:02 default[20171030t213633]  "GET /favicon.ico" 502 
  2017-10-30 23:58:06 default[20171030t213633]  "GET /" 502 
  2017-10-30 23:58:06 default[20171030t213633]  "GET /favicon.ico" 502 
  2017-11-01 10:54:50 default[20171030t213633]  "GET /" 502 
  2017-11-01 10:54:50 default[20171030t213633]  "GET /favicon.ico" 502 
  2017-11-01 10:55:02 default[20171030t213633]  "GET /favicon.ico" 502 
  2017-11-01 10:55:02 default[20171030t213633]  "GET /tatoo_artis/list" 502
  </code></pre>
  
  <p>And finally and i think more important the app.yaml file:</p>
  
  <pre><code>entrypoint: bundle exec rails server Puma -p 3000
  env: flex
  runtime: ruby
  </code></pre>
  
  <p>Thanks in advance, i got no idea what is the problem and how to fix it!</p>