https://www.prisma.io/ logo
Join SlackCommunities
Powered by
# orm-help
  • l

    Lucas Munhoz

    08/14/2018, 10:01 AM
    I’m following this doc https://oss.prisma.io/content/GraphQL-CLI/08-Codegen.html
  • a

    andrey

    08/14/2018, 11:27 AM
    Hi, my subscription is not working when using a local server. I tried to switch to Prisma Cloud and it's working. Is there an extra configuration that I need to provide?
    n
    g
    • 3
    • 6
  • m

    martin

    08/14/2018, 1:50 PM
    In case it’s useful: Sonatype offers developers free security scan tool on GitHub - TechCrunch https://techcrunch.com/2018/08/14/sonatype-now-offers-free-open-source-vulnerability-scans-to-github-users/
    n
    • 2
    • 2
  • d

    dex

    08/14/2018, 3:12 PM
    hello, i'm looking for tutorial how to use multiple database in one prisma?
    d
    a
    n
    • 4
    • 10
  • m

    Mike

    08/14/2018, 9:59 PM
    @nilan @divyendu Can one of you add me as a contributor to https://github.com/prismagraphql/prisma-templates ? I’m trying to get a fix for a security vulnerability merged, but it looks like nobody’s maintaining that repo. We’re using it in production and we have a strong interest in maintaining and improving it, including support for horizontal scaling, which I plan on adding a second template for as soon as we get it working. My github is https://github.com/mcmar
    🙌 2
    d
    n
    • 3
    • 2
  • c

    CCBCodeMonkey

    08/15/2018, 3:43 AM
    hey, I am trying to start using prisma for a new project, I have it set up
  • c

    CCBCodeMonkey

    08/15/2018, 3:43 AM
    is there any tutorial for setting up auth with prisma from the ground up?
    s
    • 2
    • 2
  • c

    CCBCodeMonkey

    08/15/2018, 3:44 AM
    all the docs seem to be about migrating auth from graph.cool
  • c

    CCBCodeMonkey

    08/15/2018, 3:46 AM
    also it seems like previously thre was a lot more setup around prisma, with like graphql-yoga when I watch tutorials or read them
  • c

    CCBCodeMonkey

    08/15/2018, 3:46 AM
    but my prisma basically has nothing but a datamodel.graphql file in the root directory.. a docker-compose, and a prisma.yml and nothing else
  • c

    CCBCodeMonkey

    08/15/2018, 3:47 AM
    so I am guessing that stuff got internalized?
  • c

    CCBCodeMonkey

    08/15/2018, 4:14 AM
    actually I found some tutorials I missed
  • c

    CCBCodeMonkey

    08/15/2018, 4:17 AM
    the side menu on the docs site is a bit wonky
  • c

    CCBCodeMonkey

    08/15/2018, 4:18 AM
  • c

    CCBCodeMonkey

    08/15/2018, 4:18 AM
    one view looks like that
  • c

    CCBCodeMonkey

    08/15/2018, 4:18 AM
    but I can get to a view that looks like this
  • c

    CCBCodeMonkey

    08/15/2018, 4:19 AM
  • c

    CCBCodeMonkey

    08/15/2018, 4:19 AM
    with much more useful tutorials
  • g

    Gareth

    08/15/2018, 7:26 AM
    @CCBCodeMonkey - it’s not really wonky - it’s just different versions of Prisma - so the one with more tuts is v1.13 rather than v1.4 with the less tuts
  • m

    Moritz

    08/15/2018, 8:29 AM
    Hi all, I created a prisma service using the typescript boilerplate and included middlewhere in it like so:
    Copy code
    const getUser = async (resolve, root, args, context, info) => {
      //context.user = await userServiceBinding.query.authenticateUser(context);
      console.log("first middlewhere called");
      const result = await resolve(root, args, context, info)
      console.log("second middlewhere called");
      return null;
    }
    const server = new GraphQLServer({
      typeDefs: './src/schema.graphql',
      resolvers,
      middlewares: [getUser],
      context: req => ({
        ...req,
        db: new Prisma({
          endpoint: '<https://eu1.prisma.sh/twigbit/vos_objectservice/dev>', // the endpoint of the Prisma API
          debug: true, // log all GraphQL queries & mutations sent to the Prisma API
          // secret: 'mysecret123', // only needed if specified in `database/prisma.yml`
        }),
      }),
    })
    server.start(() => console.log('Server is running on <http://localhost:4000'>))
    However, when I start the server using
    yarn dev
    , the middlewhere is called a lot without me fireing any queries or mutations against the server (console output: )
    Copy code
    first middlewhere called
    first middlewhere called
    first middlewhere called
    first middlewhere called
    first middlewhere called
    second middlewhere called
    second middlewhere called
    second middlewhere called
    second middlewhere called
    second middlewhere called
    Any ideas why this might be happening?
    n
    • 2
    • 4
  • m

    Moritz

    08/15/2018, 9:10 AM
    Hi, how can I set an auth header in a request to a binding created using
    graphql-bindings
    ? Thanks!
    n
    • 2
    • 4
  • m

    Moritz

    08/15/2018, 9:13 AM
    Oh, and one more: (What a busy day 🙂) How can I add an http error code (401) when throwing an error as a response to an unauthorized request in my typescript yoga service?
    n
    • 2
    • 3
  • e

    Emil

    08/15/2018, 10:20 AM
    hey, I am hosting a prisma container on a remote server and need to have a reverse proxy in front of it that routes traffic to the prisma container on a subpath (path prefix). Is there a way to tell the prisma cli to use that path in the managment api endpoint? Looking into the code I found out, that it’s derived by the endpoints origin. An option to override that would be handy. Thanks!
    👍 1
    n
    • 2
    • 1
  • s

    sandman

    08/15/2018, 10:55 AM
    Trying to setup Prisma with Heroku. Postgres Database gets created but then it gets caught in a loop and brings me right back to create another database when trying to start the service. Any ideas how to fix this?
    n
    • 2
    • 13
  • n

    Nick

    08/15/2018, 12:16 PM
    There is an import statement
    import { importSchema } from 'graphql-import'
    in one of the typescript version https://github.com/graphql-boilerplates/typescript-graphql-server/blob/master/basic/src/index.ts I wonder is the import statement doing anything at all?
    n
    • 2
    • 1
  • h

    halborg

    08/15/2018, 12:36 PM
    Does anyone know of a way to use multiple
    .env
    files along with Bitbucket Pipelines without having to commit the
    .env
    files?
  • c

    cory

    08/15/2018, 12:59 PM
    What are the big differences in Prisma and Prisma Cloud?
  • c

    cory

    08/15/2018, 12:59 PM
    I’m new to all this graphql stuff. 🙂
  • c

    cory

    08/15/2018, 1:00 PM
    Seems like Prisma:
    client -> graphql server -> prisma api -> database
    👍 1
  • c

    cory

    08/15/2018, 1:00 PM
    With Prisma Cloud do you still have to mess around with the
    graphql server
    piece?
1...9899100...637Latest