Fresh newb having trouble with dev environment setup

Hi everyone! I’m a junior developer whose experience is primarily in front-end React/React Native, and I’m hoping to make some contributions here. I’ve tried to follow the below instructions but am running into some issues.

https://docs.communityhealthtoolkit.org/contribute/code/core/dev-environment/#the-happy-path-installation

I assume the instructions for CHT 4.x are what I should be following for docker/couchDB, but in my quest to get up and running I went through the 3.x steps as well. 3.x went smoothly, but when I try 4.x I get the following error:

WARN[0000] The "COUCHDB_SECRET" variable is not set. Defaulting to a blank string. 
WARN[0000] The "COUCHDB_UUID" variable is not set. Defaulting to a blank string. 
permission denied while trying to connect to the Docker daemon socket at unix:///run/user/1000/docker.sock: Get "http://%2Frun%2Fuser%2F1000%2Fdocker.sock/v1.24/containers/json?all=1&filters=%7B%22label%22%3A%7B%22com.docker.compose.config-hash%22%3Atrue%2C%22com.docker.compose.project%3Dcht-docker%22%3Atrue%7D%7D": dial unix /run/user/1000/docker.sock: connect: permission denied

I’m guessing this is where the issue lies, but for additional context I also attempted the next step of getting the servers running in 3 terminals. I was able to get the first one going, but the second one gives me an error:

StatusCodeError: 401 - {"error":"unauthorized","reason":"Name or password is incorrect."}
    at new StatusCodeError (/home/jakemadash/cht-core/node_modules/request-promise-core/lib/errors.js:32:15)
    at Request.plumbing.callback (/home/jakemadash/cht-core/node_modules/request-promise-core/lib/plumbing.js:104:33)
    at Request.RP$callback [as _callback] (/home/jakemadash/cht-core/node_modules/request-promise-core/lib/plumbing.js:46:31)
    at Request.self.callback (/home/jakemadash/cht-core/node_modules/request/request.js:185:22)
    at Request.emit (node:events:513:28)
    at Request.<anonymous> (/home/jakemadash/cht-core/node_modules/request/request.js:1154:10)
    at Request.emit (node:events:513:28)
    at IncomingMessage.<anonymous> (/home/jakemadash/cht-core/node_modules/request/request.js:1076:12)
    at Object.onceWrapper (node:events:627:28)
    at IncomingMessage.emit (node:events:525:35) {
  statusCode: 401,
  error: { error: 'unauthorized', reason: 'Name or password is incorrect.' }

I tried scouring the forum before making this post but couldn’t find anything that quite aligned with my particular situation. Any help is greatly appreciated. Thanks!

Hi @cringleboy

The line is probably the initial problem you should solve. You will probably need to run all scripts with sudo or change permissions for the docker group. I believe these instructions will help detangle you: Linux post-installation steps for Docker Engine | Docker Docs

Welcome to the forum and to the CHT!