akuiper
akuiper

Reputation: 214927

deploy prisma project to local with docker

Trying to follow this prisma tutorial to boot a local graphql server, but received the following error while selecting the local as the deployment option:

Error: Could not connect to cluster local. Please use prisma local start to start your local Prisma cluster.

But when I run prisma local start, I got another error:

Error: Couldn't connect to Docker daemon at http+docker://localunixsocket - is it running?

If it's at a non-standard location, specify the URL with the DOCKER_HOST environment variable.

I have already installed docker. But not sure where the problem comes from. Maybe it's the location not set correctly? Can some one with relevant experience point out what could be wrong?

Upvotes: 0

Views: 668

Answers (1)

akuiper
akuiper

Reputation: 214927

It turns out I have to add my user to the docker group, as in the docker documention.

sudo groupadd docker

sudo usermod -aG docker $USER

Also note in order for the change to take effect, you have to Log out and log back in so that your group membership is re-evaluated. After running the above commands, I restarted my machine and everything worked fine.

Upvotes: 1

Related Questions