Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running graphql get-schema project_name gives an error, because of incorrect relative path of prisma.yml #100

Closed
artem-korolev opened this issue Jun 25, 2018 · 1 comment

Comments

@artem-korolev
Copy link

artem-korolev commented Jun 25, 2018

I have this file structure:

  • workspace
    .graphqlconfig
    • servers
      --- prisma
      --- app
      --- admin
    • clients
      --- relay-native
      --- react-graphql

.graphqlconfig:

{
	"projects": {
		"graphql": {
			"schemaPath": "servers/app/src/generated/prisma.graphql",
			"extensions": {
				"prisma": "servers/prisma/prisma.yml"
			}
		}
	}
}

So that .graphqlconfig is placed in the root of workspace.
I run this:

cd servers/app
graphql get-schema -p graphql
× servers/prisma/prisma.yml could not be found.

if I update my config with this line:
"prisma": "../../servers/prisma/prisma.yml"
everything works okay then.
So I guess its a bug, that should be fixed

I want to have at least 2 applications for one prisma server.. its usually 1) app 2) admin... pretty logical.. different endpoints.. different auth rules, security flows and so on.
and I want auto update schemas in all applications when I change prisma schema... current approach support updating only one app.. well.. maybe i'm wrong.. this type of project structure looks to me pretty logical, but i'm not able to configure it properly for some reason

@marktani
Copy link

I'm closing this in favor of Urigo/graphql-cli#340 now. I'm not sure if this is a bug, and if it is in graphql-config or graphql-cli, but we'll find out 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants