Giter VIP home page Giter VIP logo

prisma-heroku's People

Contributors

dpetrick avatar joserocha3 avatar stefl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

prisma-heroku's Issues

Database connection issues

Hi, thank you for writing this up!

I've been following this in order to deploy to Heroku and found some issues when connecting to the database. These are the issues I'm seeing.

When the server starts I get:

SEVERE: Connection error:
org.postgresql.util.PSQLException: FATAL: permission denied for database "postgres"
Detail: User does not have CONNECT privilege.

This is very weird, because I passing a database name which is not postgres. And then later I start getting the error:

SEVERE: Connection error:
org.postgresql.util.PSQLException: FATAL: too many connections for role "nfcsdwxwnplgnf"

This second error makes more sense, because it informs the correct user I am using to connect. But since Heroku Postgres database has a connection cap for 20, there is not much I can do to solve this. Is there a way to set Prisma connection pool max connections?

With my deployment I am able to run prisma deploy and see that my tables were created. But I can't query the Graphql API because of the connection errors.

Issue with port number not being set

Hi there, first off, thanks so much for this little guide!

However, I keep getting this error whenever the app starts on Heroku:

2019-04-24T15:24:04.658285+00:00 heroku[web.1]: Starting process with command `/bin/sh -c /app/start.sh`
2019-04-24T15:24:09.517957+00:00 heroku[web.1]: State changed from starting to crashed
2019-04-24T15:24:09.490802+00:00 heroku[web.1]: Process exited with status 1
2019-04-24T15:24:09.228159+00:00 app[web.1]: Exception in thread "main" java.lang.RuntimeException: Unable to load Prisma config: com.prisma.config.InvalidConfiguration: Expected Int for field port, got <unset>
2019-04-24T15:24:09.228523+00:00 app[web.1]: at scala.sys.package$.error(package.scala:26)
2019-04-24T15:24:09.228609+00:00 app[web.1]: at com.prisma.config.ConfigLoader$.load(ConfigLoader.scala:40)
2019-04-24T15:24:09.228744+00:00 app[web.1]: at com.prisma.local.PrismaLocalDependencies.<init>(PrismaLocalDependencies.scala:48)
2019-04-24T15:24:09.228833+00:00 app[web.1]: at com.prisma.local.PrismaLocalMain$.delayedEndpoint$com$prisma$local$PrismaLocalMain$1(PrismaLocalMain.scala:13)
2019-04-24T15:24:09.228971+00:00 app[web.1]: at com.prisma.local.PrismaLocalMain$delayedInit$body.apply(PrismaLocalMain.scala:8)
2019-04-24T15:24:09.229064+00:00 app[web.1]: at scala.Function0.apply$mcV$sp(Function0.scala:34)
2019-04-24T15:24:09.229157+00:00 app[web.1]: at scala.Function0.apply$mcV$sp$(Function0.scala:34)
2019-04-24T15:24:09.229304+00:00 app[web.1]: at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12)
2019-04-24T15:24:09.229405+00:00 app[web.1]: at scala.App.$anonfun$main$1$adapted(App.scala:76)
2019-04-24T15:24:09.229485+00:00 app[web.1]: at scala.collection.immutable.List.foreach(List.scala:388)
2019-04-24T15:24:09.229729+00:00 app[web.1]: at scala.App.main(App.scala:76)
2019-04-24T15:24:09.229822+00:00 app[web.1]: at scala.App.main$(App.scala:74)

It seems the ${PORT} referenced in prerun_hook.sh is not being set somehow. Any ideas what might resolve this? I've tried setting it manually but that doesn't do anything

Permission denied

First of all, thank you very much for this repo! Saved my day.

I did, however, have to change the Dockerfile to

ARG tag
FROM prismagraphql/prisma:$tag
COPY ./prerun_hook.sh /app/prerun_hook.sh

RUN chmod a+x /app/start.sh
RUN chmod a+x /app/prerun_hook.sh

CMD bash /app/start.sh

as I was getting Permission denied errors when it tried to run the shell scripts.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.