Skip to content
This repository was archived by the owner on Sep 6, 2022. It is now read-only.
This repository was archived by the owner on Sep 6, 2022. It is now read-only.

app.yaml handlers? #39

Open
Open

Description

@ppkn

I'm pretty new to Google App Engine.

What do I need to add to the handlers section of app.yaml to make it work?

Activity

  1. mdornseif commented on Feb 4, 2019

    @mdornseif
    Contributor

    You have to write your own WSGI application. https://github.com/graphql-python/graphene-gae/blob/master/tests/_webapp2/test_graphql_handler.py gives some hints.

    eg mygraphql.py:

    import webapp2
    from graphene_gae.webapp2 import graphql_application, GraphQLHandler
    
    [define query etc]
    schema = graphene.Schema(query=QueryRoot)
    
    graphql_application.config['graphql_schema'] = schema
    graphql_application.config['graphql_pretty'] = True
    
    application = webapp2.WSGIApplication([
            ('/graphql', GraphQLHandler)
        ])
    

    then in app.yaml:

    - url: /graphql
      script: mygraphql.application
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions