# Need help for setting up simple config file for Nakama

**URL:** <https://forum.heroiclabs.com/t/need-help-for-setting-up-simple-config-file-for-nakama/2207>\
**Category:** Local Setup\
**Tags:** getting-started\
**Created:** [December 26, 2021, 9:18am UTC](https://forum.heroiclabs.com/t/need-help-for-setting-up-simple-config-file-for-nakama/2207 "2021-12-26T09:18:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bear](https://avatars.discourse-cdn.com/v4/letter/b/ac8455/32.png) [@bear](https://forum.heroiclabs.com/u/bear)\
**Post date:** [December 26, 2021, 9:18am UTC](https://forum.heroiclabs.com/t/need-help-for-setting-up-simple-config-file-for-nakama/2207/1 "2021-12-26T09:18:34Z")

</div>

I am new to Nakama and networking.

Things I done:

1. Download Docker Desktop (Window).

2. Follow the link to run nakama and setup configuration file: [Docker compose - Heroic Labs Documentation](https://heroiclabs.com/docs/nakama/getting-started/docker-quickstart/#running-nakama).

3. Reload the nakama console, but the config file doesn’t seem being applied. I still able to login with default **admin:password**. Suppose I should only can login with **my\_user:my\_password**?

4. I already checked on the yml spacing as this post said: [I have an issue with making Nakama read the config files [Windows]](https://forum.heroiclabs.com/t/i-have-an-issue-with-making-nakama-read-the-config-files-windows/2159).

I have included both **docker-compose.yml** and **my-config.yml** below.

```auto
version: "3"
services:
  cockroachdb:
    image: cockroachdb/cockroach:latest-v20.2
    command: start-single-node --insecure --store=attrs=ssd,path=/var/lib/cockroach/
    restart: "no"
    volumes:
      - data:/var/lib/cockroach
    expose:
      - "8080"
      - "26257"
    ports:
      - "26257:26257"
      - "8080:8080"
  nakama:
    image: heroiclabs/nakama:3.2.1
    entrypoint:
      - "/bin/sh"
      - "-ecx"
      - >
        /nakama/nakama migrate up --database.address root@cockroachdb:26257 &&
        /nakama/nakama --config /nakama/data/my-config.yml
    restart: "no"
    links:
      - "cockroachdb:db"
    depends_on:
      - cockroachdb
      - prometheus
    volumes:
      - ./data:/nakama/data
    expose:
      - "7349"
      - "7350"
      - "7351"
      - "9100"
    ports:
      - "7349:7349"
      - "7350:7350"
      - "7351:7351"
    healthcheck:
      test: ["CMD", "curl", "-f", "http://localhost:7350/"]
      interval: 10s
      timeout: 5s
      retries: 5
  prometheus:
    image: prom/prometheus
    entrypoint: /bin/sh -c
    command: |
      'sh -s <<EOF
        cat > ./prometheus.yml <<EON
      global:
        scrape_interval: 15s
        evaluation_interval: 15s
      scrape_configs:
        - job_name: prometheus
          static_configs:
          - targets: ['localhost:9090']
        - job_name: nakama
          metrics_path: /
          static_configs:
          - targets: ['nakama:9100']
      EON
      prometheus --config.file=./prometheus.yml
      EOF'
    ports:
      - "9090:9090"
volumes:
  data:

```

**my-config.yml**

```auto
name: nakama-node-1
data_dir: "./data/"

logger:
  stdout: false
  level: "warn"
  file: "/nakama/data/logfile.log"

console:
  port: 7351
  username: "my_user"
  password: "my_password"

```

Is there any step I missing to make Nakama loads the config file?

---

<div class="post-metadata">

**Author:** ![mofirouz](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.heroiclabs.com/mofirouz/32/1523_2.png) [@mofirouz](https://forum.heroiclabs.com/u/mofirouz)\
**Post date:** [December 27, 2021, 2:45pm UTC](https://forum.heroiclabs.com/t/need-help-for-setting-up-simple-config-file-for-nakama/2207/2 "2021-12-27T14:45:29Z")

</div>

From the [documentation](https://heroiclabs.com/docs/nakama/getting-started/docker-quickstart/):

> You must edit the `nakama:volumes:` entry in your `docker-compose.yml` file so that it looks like the following: `/c/Users/<username>/projects/docker:/nakama/data` .

---

<div class="post-metadata">

**Author:** ![bear](https://avatars.discourse-cdn.com/v4/letter/b/ac8455/32.png) [@bear](https://forum.heroiclabs.com/u/bear)\
**Post date:** [December 27, 2021, 6:29pm UTC](https://forum.heroiclabs.com/t/need-help-for-setting-up-simple-config-file-for-nakama/2207/3 "2021-12-27T18:29:19Z")

</div>

Done a couple of trial-and-error, modify the _entrypoint_ as below seems solve the issue.

```auto
    entrypoint:
      - "/bin/sh"
      - "-ecx"
      - >
        /nakama/nakama migrate up --database.address root@cockroachdb:26257 &&
        exec /nakama/nakama --database.address root@cockroachdb:26257 --config /nakama/data/my-config.yml

```

Thanks anyway for helping me to figure out :))
