title: How to run TensorFlow in Google App Engine Flexible Enviroment?
body: <p>Before I asked why GAE can't find TensorFlow lib here <a href="https://stackoverflow.com/questions/40241846/why-googleappengine-gives-me-importerror-no-module-named-tensorflow">https://stackoverflow.com/questions/40241846/why-googleappengine-gives-me-importerror-no-module-named-tensorflow</a></p>
  
  <p>And <code>Dmytro Sadovnychyi</code> told me that GAE can't run TensorFlow, but GAE flexible can.</p>
  
  <p>So I created my project in USA zone and trying to deploy my simple project:</p>
  
  <pre><code>import webapp2
  import tensorflow as tf
  
  class MainHandler(webapp2.RequestHandler):
      def get(self):
          hello = tf.constant('Hello, TensorFlow!')
          sess = tf.Session()
          self.response.write(sess.run(hello))
          a = tf.constant(10)
          b = tf.constant(32)
          self.response.write(sess.run(a + b))
          #self.response.write('asd');
  
  
  app = webapp2.WSGIApplication([
      ('/', MainHandler)
  ], debug=True)
  </code></pre>
  
  <p>witn <code>vm: true</code> in yaml.</p>
  
  <p>This is yaml:</p>
  
  <pre><code>application: tstmchnlrn
  version: 1
  runtime: python27
  vm: true
  api_version: 1
  threadsafe: yes
  
  handlers:
  - url: /favicon\.ico
    static_files: favicon.ico
    upload: favicon\.ico
  
  - url: .*
    script: main.app
  
  libraries:
  - name: webapp2
    version: "2.5.2"
  </code></pre>
  
  <p>Deploy successes, but I getting Server Internal Error when visiting my app at <code>appspot</code> and console still shows me <code>ImportError: No module named tensorflow</code>.</p>
  
  <p>What I need to do to make TensorFlow based app to run in <code>flexible enviroment</code>?</p>