title: Docker compose: Error: role "hleb" does not exist
body: <p>Kindly ask you to help with docker and Postgres.</p>
  <ul>
  <li><p>I have a local Postgres database and a project on NestJS.</p>
  </li>
  <li><p>I killed 5432 port.</p>
  </li>
  <li><p>My Dockerfile</p>
  </li>
  </ul>
  <pre><code>FROM node:16.13.1
  
  WORKDIR /app
  
  COPY package.json ./
  COPY yarn.lock ./
  
  RUN yarn install
  
  COPY . .
  
  COPY ./dist ./dist
  CMD [&quot;yarn&quot;, &quot;start:dev&quot;]
  
  </code></pre>
  <ul>
  <li>My docker-compose.yml</li>
  </ul>
  <pre><code>version: '3.0'
  
  services:
    main:
      container_name: main
      build:
        context: .
      env_file:
        - .env
      volumes:
        - .:/app
        - /app/node_modules
      ports:
        - 4000:4000
        - 9229:9229
      command: yarn start:dev
      depends_on:
        - postgres
      restart: always
  
    postgres:
      container_name: postgres
      image: postgres:12
      env_file:
        - .env
      environment:
        PG_DATA: /var/lib/postgresql/data
        POSTGRES_HOST_AUTH_METHOD: 'trust'
      ports:
        - 5432:5432
      volumes:
        - pgdata:/var/lib/postgresql/data
      restart: always
  
  volumes:
    pgdata:
  
  </code></pre>
  <ul>
  <li>.env</li>
  </ul>
  <pre><code>DB_TYPE=postgres
  DB_HOST=postgres
  DB_PORT=5432
  DB_USERNAME=hleb
  DB_NAME=artwine
  DB_PASSWORD=Mypassword
  
  </code></pre>
  <ul>
  <li><p>running <strong>sudo docker-compose build</strong> - NO ERRORS</p>
  </li>
  <li><p>running <strong>sudo docker-compose up --force-recreate</strong> - ERROR</p>
  </li>
  </ul>
  <p>ERROR [ExceptionHandler] role &quot;hleb&quot; does not exist.</p>
  <p>I've tried multiple suggestions from existing issues but nothing helped.
  What am I doing wrong?
  Thanks!</p>