demo login doesnt work #377

Closed
opened 2026-02-04 18:52:11 +03:00 by OVERLORD · 26 comments
Owner

Originally created by @lucreista on GitHub (Oct 31, 2023).

image
installed on a fresh ubuntu 22.04 vps, demo details doesnt work, tried reinstalling and same thing happens

Originally created by @lucreista on GitHub (Oct 31, 2023). ![image](https://github.com/plankanban/planka/assets/57005050/a656888c-d66e-4eed-89af-c2405d28af2d) installed on a fresh ubuntu 22.04 vps, demo details doesnt work, tried reinstalling and same thing happens
Author
Owner

@meltyshev commented on GitHub (Oct 31, 2023):

Hi! We recently changed the creation of the initial admin account. You have to add these environment variables:

DEFAULT_ADMIN_EMAIL=YOUR_ADMIN_EMAIL # Do not remove if you want to prevent this user from being edited/deleted
DEFAULT_ADMIN_PASSWORD=YOUR_ADMIN_PASSWORD
DEFAULT_ADMIN_NAME=YOUR_ADMIN_NAME
DEFAULT_ADMIN_USERNAME=YOUR_ADMIN_USERNAME

This should be covered in the docs: https://docs.planka.cloud/docs/category/installalation/.

@meltyshev commented on GitHub (Oct 31, 2023): Hi! We recently changed the creation of the initial admin account. You have to add these environment variables: ``` DEFAULT_ADMIN_EMAIL=YOUR_ADMIN_EMAIL # Do not remove if you want to prevent this user from being edited/deleted DEFAULT_ADMIN_PASSWORD=YOUR_ADMIN_PASSWORD DEFAULT_ADMIN_NAME=YOUR_ADMIN_NAME DEFAULT_ADMIN_USERNAME=YOUR_ADMIN_USERNAME ``` This should be covered in the docs: https://docs.planka.cloud/docs/category/installalation/.
Author
Owner

@lucreista commented on GitHub (Oct 31, 2023):

Hi! We recently changed the creation of the initial admin account. You have to add these environment variables:

DEFAULT_ADMIN_EMAIL=YOUR_ADMIN_EMAIL # Do not remove if you want to prevent this user from being edited/deleted
DEFAULT_ADMIN_PASSWORD=YOUR_ADMIN_PASSWORD
DEFAULT_ADMIN_NAME=YOUR_ADMIN_NAME
DEFAULT_ADMIN_USERNAME=YOUR_ADMIN_USERNAME

This should be covered in the docs: https://docs.planka.cloud/docs/category/installalation/.

added it to the .env file but still cant even after a restart

@lucreista commented on GitHub (Oct 31, 2023): > Hi! We recently changed the creation of the initial admin account. You have to add these environment variables: > > ``` > DEFAULT_ADMIN_EMAIL=YOUR_ADMIN_EMAIL # Do not remove if you want to prevent this user from being edited/deleted > DEFAULT_ADMIN_PASSWORD=YOUR_ADMIN_PASSWORD > DEFAULT_ADMIN_NAME=YOUR_ADMIN_NAME > DEFAULT_ADMIN_USERNAME=YOUR_ADMIN_USERNAME > ``` > > This should be covered in the docs: https://docs.planka.cloud/docs/category/installalation/. added it to the .env file but still cant even after a restart
Author
Owner

@meltyshev commented on GitHub (Oct 31, 2023):

Hm, that's weird. Could you please show your .env file (need to remove all secret data).

@meltyshev commented on GitHub (Oct 31, 2023): Hm, that's weird. Could you please show your `.env` file (need to remove all secret data).
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

I have the same problem.
Just created a fresh Ubuntu 22.04 vps and ran the installer.

/opt/planka/.env looks like this:

BASE_URL=http://xx.xxxxxxxx.xx
SECRET_KEY=xxxxxxxxxxxxxxxxxxxxxxxxx
DEFAULT_ADMIN_EMAIL=some.email.de
DEFAULT_ADMIN_PASSWORD=verysecret
DEFAULT_ADMIN_NAME=Martin
DEFAULT_ADMIN_USERNAME=Martin

Yet despite multiple
/opt/planka# docker compose --env-file .env up -d
and downs it wont reckognize my E-Mail or username.

After removing virtuall everything i restarted the whole thing without any success:

root@xxxxx:/opt/planka# docker compose --env-file .env up -d
[+] Running 23/23
 ✔ postgres 8 layers [⣿⣿⣿⣿⣿⣿⣿⣿]      0B/0B      Pulled                                                                                                                      19.3s
   ✔ 96526aa774ef Pull complete                                                                                                                                              3.9s
   ✔ cae7778f1ca2 Pull complete                                                                                                                                              3.8s
   ✔ a068e763669a Pull complete                                                                                                                                              4.2s
   ✔ 0787333105a2 Pull complete                                                                                                                                              9.4s
   ✔ e1c22c2c0cb8 Pull complete                                                                                                                                              4.6s
   ✔ 5eaf5c39276d Pull complete                                                                                                                                              4.9s
   ✔ 03ec842f1e62 Pull complete                                                                                                                                              5.4s
   ✔ 1c5e4ba76017 Pull complete                                                                                                                                              5.8s
 ✔ planka 13 layers [⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿]      0B/0B      Pulled                                                                                                                  25.5s
   ✔ 7264a8db6415 Pull complete                                                                                                                                              0.3s
   ✔ 751194035c36 Pull complete                                                                                                                                              2.9s
   ✔ eff5dce73b38 Pull complete                                                                                                                                              0.4s
   ✔ c8ce5be43019 Pull complete                                                                                                                                              0.7s
   ✔ 2b80ad872417 Pull complete                                                                                                                                             10.1s
   ✔ 21247504e003 Pull complete                                                                                                                                              1.1s
   ✔ fdf465ced713 Pull complete                                                                                                                                              1.4s
   ✔ ec429d873e05 Pull complete                                                                                                                                              1.7s
   ✔ 0e408e6be231 Pull complete                                                                                                                                              2.0s
   ✔ a68a61c1b02d Pull complete                                                                                                                                              2.3s
   ✔ b8f464d926f4 Pull complete                                                                                                                                              4.1s
   ✔ 058806af9646 Pull complete                                                                                                                                              3.9s
   ✔ 7ff87f19dac3 Pull complete                                                                                                                                              4.2s
[+] Running 7/7
 ✔ Network planka_default                     Created                                                                                                                        0.1s
 ✔ Volume "planka_db-data"                    Created                                                                                                                        0.0s
 ✔ Volume "planka_user-avatars"               Created                                                                                                                        0.0s
 ✔ Volume "planka_project-background-images"  Created                                                                                                                        0.0s
 ✔ Volume "planka_attachments"                Created                                                                                                                        0.0s
 ✔ Container planka_db                        Started                                                                                                                        0.4s
 ✔ Container planka                           Started                                                                                                                        0.1s
root@xxxxxxx:/opt/planka#

Still my User/Pass or Mail/Pass is not recognized.

@Nachtwind85 commented on GitHub (Nov 6, 2023): I have the same problem. Just created a fresh Ubuntu 22.04 vps and ran the installer. /opt/planka/.env looks like this: ``` BASE_URL=http://xx.xxxxxxxx.xx SECRET_KEY=xxxxxxxxxxxxxxxxxxxxxxxxx DEFAULT_ADMIN_EMAIL=some.email.de DEFAULT_ADMIN_PASSWORD=verysecret DEFAULT_ADMIN_NAME=Martin DEFAULT_ADMIN_USERNAME=Martin ``` Yet despite multiple `/opt/planka# docker compose --env-file .env up -d ` and downs it wont reckognize my E-Mail or username. After removing virtuall everything i restarted the whole thing without any success: ``` root@xxxxx:/opt/planka# docker compose --env-file .env up -d [+] Running 23/23 ✔ postgres 8 layers [⣿⣿⣿⣿⣿⣿⣿⣿] 0B/0B Pulled 19.3s ✔ 96526aa774ef Pull complete 3.9s ✔ cae7778f1ca2 Pull complete 3.8s ✔ a068e763669a Pull complete 4.2s ✔ 0787333105a2 Pull complete 9.4s ✔ e1c22c2c0cb8 Pull complete 4.6s ✔ 5eaf5c39276d Pull complete 4.9s ✔ 03ec842f1e62 Pull complete 5.4s ✔ 1c5e4ba76017 Pull complete 5.8s ✔ planka 13 layers [⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿] 0B/0B Pulled 25.5s ✔ 7264a8db6415 Pull complete 0.3s ✔ 751194035c36 Pull complete 2.9s ✔ eff5dce73b38 Pull complete 0.4s ✔ c8ce5be43019 Pull complete 0.7s ✔ 2b80ad872417 Pull complete 10.1s ✔ 21247504e003 Pull complete 1.1s ✔ fdf465ced713 Pull complete 1.4s ✔ ec429d873e05 Pull complete 1.7s ✔ 0e408e6be231 Pull complete 2.0s ✔ a68a61c1b02d Pull complete 2.3s ✔ b8f464d926f4 Pull complete 4.1s ✔ 058806af9646 Pull complete 3.9s ✔ 7ff87f19dac3 Pull complete 4.2s [+] Running 7/7 ✔ Network planka_default Created 0.1s ✔ Volume "planka_db-data" Created 0.0s ✔ Volume "planka_user-avatars" Created 0.0s ✔ Volume "planka_project-background-images" Created 0.0s ✔ Volume "planka_attachments" Created 0.0s ✔ Container planka_db Started 0.4s ✔ Container planka Started 0.1s root@xxxxxxx:/opt/planka# ``` Still my User/Pass or Mail/Pass is not recognized.
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

Hi! It looks like I forgot to convert username and email to lower case when creating an initial user (this should definitely be fixed). Does your email also have an uppercase letter in it?

@meltyshev commented on GitHub (Nov 6, 2023): Hi! It looks like I forgot to convert username and email to lower case when creating an initial user (this should definitely be fixed). Does your email also have an uppercase letter in it?
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

No,
I just checkked by copy pasting the very same address i used in the .env into the login. Its a habit anyway i do to keep everything lowercased for logins..

@Nachtwind85 commented on GitHub (Nov 6, 2023): No, I just checkked by copy pasting the very same address i used in the .env into the login. Its a habit anyway i do to keep everything lowercased for logins..
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

Just tested it with docker compose --env-file .env up -d and got the same problem, trying to figure out why....

@meltyshev commented on GitHub (Nov 6, 2023): Just tested it with `docker compose --env-file .env up -d` and got the same problem, trying to figure out why....
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

I don't know why it doesn't work with --env-file .env, please try to uncomment and edit the DEFAULT_ADMIN_* environment variables directly in docker-compose.yml and restart the container.

@meltyshev commented on GitHub (Nov 6, 2023): I don't know why it doesn't work with `--env-file .env`, please try to uncomment and edit the `DEFAULT_ADMIN_*` environment variables directly in `docker-compose.yml` and restart the container.
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

This is the docker-compose.yml created/downloaded by the installer:

/opt/planka# tail -n 100 docker-compose.yml
version: '3'
services:
  planka:
    container_name: planka
    image: ghcr.io/plankanban/planka:latest
    command: >
      bash -c
        "for i in `seq 1 30`; do
          ./start.sh &&
          s=$$? && break || s=$$?;
          echo \"Tried $$i times. Waiting 5 seconds...\";
          sleep 5;
        done; (exit $$s)"
    restart: unless-stopped
    volumes:
      - user-avatars:/app/public/user-avatars
      - project-background-images:/app/public/project-background-images
      - attachments:/app/private/attachments
      - /opt/planka/logs/app:/app/logs
    ports:
      - 3000:1337
    environment:
      - TRUST_PROXY=0
      - DATABASE_URL=postgresql://postgres@postgres/planka
      - BASE_URL=${BASE_URL}
      - SECRET_KEY=${SECRET_KEY}

      # related: https://github.com/knex/knex/issues/2354
      # As knex does not pass query parameters from the connection string we
      # have to use environment variables in order to pass the desired values, e.g.
      # - PGSSLMODE=<value>

      # Configure knex to accept SSL certificates
      # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false
    depends_on:
      - postgres

  postgres:
    container_name: planka_db
    image: postgres:14-alpine
    restart: unless-stopped
    volumes:
      - db-data:/var/lib/postgresql/data
    environment:
      - POSTGRES_DB=planka
      - POSTGRES_HOST_AUTH_METHOD=trust

volumes:
  user-avatars:
  project-background-images:
  attachments:
  db-data:```

It currently does not offer these variables. i will add them and test the thing.. 
@Nachtwind85 commented on GitHub (Nov 6, 2023): This is the docker-compose.yml created/downloaded by the installer: ``` /opt/planka# tail -n 100 docker-compose.yml version: '3' services: planka: container_name: planka image: ghcr.io/plankanban/planka:latest command: > bash -c "for i in `seq 1 30`; do ./start.sh && s=$$? && break || s=$$?; echo \"Tried $$i times. Waiting 5 seconds...\"; sleep 5; done; (exit $$s)" restart: unless-stopped volumes: - user-avatars:/app/public/user-avatars - project-background-images:/app/public/project-background-images - attachments:/app/private/attachments - /opt/planka/logs/app:/app/logs ports: - 3000:1337 environment: - TRUST_PROXY=0 - DATABASE_URL=postgresql://postgres@postgres/planka - BASE_URL=${BASE_URL} - SECRET_KEY=${SECRET_KEY} # related: https://github.com/knex/knex/issues/2354 # As knex does not pass query parameters from the connection string we # have to use environment variables in order to pass the desired values, e.g. # - PGSSLMODE=<value> # Configure knex to accept SSL certificates # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false depends_on: - postgres postgres: container_name: planka_db image: postgres:14-alpine restart: unless-stopped volumes: - db-data:/var/lib/postgresql/data environment: - POSTGRES_DB=planka - POSTGRES_HOST_AUTH_METHOD=trust volumes: user-avatars: project-background-images: attachments: db-data:``` It currently does not offer these variables. i will add them and test the thing..
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

Well... i am one step ahead and could log in. Now i am facing and endless circle ;)

image

Gonna recreate the whole thing... brb

@Nachtwind85 commented on GitHub (Nov 6, 2023): Well... i am one step ahead and could log in. Now i am facing and endless circle ;) ![image](https://github.com/plankanban/planka/assets/60173070/234232fc-4d39-473f-8068-2a254f1ee47c) Gonna recreate the whole thing... brb
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

OK... still nothing...

but this should be unrelated to the .env problem...

root@xxxxx:/opt/planka# docker logs  --since=1h edbb82e8e78f
node:internal/process/promises:288
            triggerUncaughtException(err, true /* fromPromise */);
            ^

Error: connect ECONNREFUSED 172.22.0.2:5432
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16) {
  errno: -111,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '172.22.0.2',
  port: 5432
}

Node.js v18.17.1
Tried 1 times. Waiting 5 seconds...
debug: Detected Sails environment is "production", but NODE_ENV is `undefined`.
debug: Automatically setting the NODE_ENV environment variable to "production".
debug:

@Nachtwind85 commented on GitHub (Nov 6, 2023): OK... still nothing... but this should be unrelated to the .env problem... ``` root@xxxxx:/opt/planka# docker logs --since=1h edbb82e8e78f node:internal/process/promises:288 triggerUncaughtException(err, true /* fromPromise */); ^ Error: connect ECONNREFUSED 172.22.0.2:5432 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '172.22.0.2', port: 5432 } Node.js v18.17.1 Tried 1 times. Waiting 5 seconds... debug: Detected Sails environment is "production", but NODE_ENV is `undefined`. debug: Automatically setting the NODE_ENV environment variable to "production". debug: ```
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

This is the docker-compose.yml created/downloaded by the installer:

/opt/planka# tail -n 100 docker-compose.yml
version: '3'
services:
  planka:
    container_name: planka
    image: ghcr.io/plankanban/planka:latest
    command: >
      bash -c
        "for i in `seq 1 30`; do
          ./start.sh &&
          s=$$? && break || s=$$?;
          echo \"Tried $$i times. Waiting 5 seconds...\";
          sleep 5;
        done; (exit $$s)"
    restart: unless-stopped
    volumes:
      - user-avatars:/app/public/user-avatars
      - project-background-images:/app/public/project-background-images
      - attachments:/app/private/attachments
      - /opt/planka/logs/app:/app/logs
    ports:
      - 3000:1337
    environment:
      - TRUST_PROXY=0
      - DATABASE_URL=postgresql://postgres@postgres/planka
      - BASE_URL=${BASE_URL}
      - SECRET_KEY=${SECRET_KEY}

      # related: https://github.com/knex/knex/issues/2354
      # As knex does not pass query parameters from the connection string we
      # have to use environment variables in order to pass the desired values, e.g.
      # - PGSSLMODE=<value>

      # Configure knex to accept SSL certificates
      # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false
    depends_on:
      - postgres

  postgres:
    container_name: planka_db
    image: postgres:14-alpine
    restart: unless-stopped
    volumes:
      - db-data:/var/lib/postgresql/data
    environment:
      - POSTGRES_DB=planka
      - POSTGRES_HOST_AUTH_METHOD=trust

volumes:
  user-avatars:
  project-background-images:
  attachments:
  db-data:```

It currently does not offer these variables. i will add them and test the thing.. 

Oops, we need to update it. Thanks for reporting!

OK... still nothing...

but this should be unrelated to the .env problem...

root@xxxxx:/opt/planka# docker logs  --since=1h edbb82e8e78f
node:internal/process/promises:288
            triggerUncaughtException(err, true /* fromPromise */);
            ^

Error: connect ECONNREFUSED 172.22.0.2:5432
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16) {
  errno: -111,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '172.22.0.2',
  port: 5432
}

Node.js v18.17.1
Tried 1 times. Waiting 5 seconds...
debug: Detected Sails environment is "production", but NODE_ENV is `undefined`.
debug: Automatically setting the NODE_ENV environment variable to "production".
debug:

There is no connection to the database 🤔 Please check DATABASE_URL and that it's running.

@meltyshev commented on GitHub (Nov 6, 2023): > This is the docker-compose.yml created/downloaded by the installer: > > ``` > /opt/planka# tail -n 100 docker-compose.yml > version: '3' > services: > planka: > container_name: planka > image: ghcr.io/plankanban/planka:latest > command: > > bash -c > "for i in `seq 1 30`; do > ./start.sh && > s=$$? && break || s=$$?; > echo \"Tried $$i times. Waiting 5 seconds...\"; > sleep 5; > done; (exit $$s)" > restart: unless-stopped > volumes: > - user-avatars:/app/public/user-avatars > - project-background-images:/app/public/project-background-images > - attachments:/app/private/attachments > - /opt/planka/logs/app:/app/logs > ports: > - 3000:1337 > environment: > - TRUST_PROXY=0 > - DATABASE_URL=postgresql://postgres@postgres/planka > - BASE_URL=${BASE_URL} > - SECRET_KEY=${SECRET_KEY} > > # related: https://github.com/knex/knex/issues/2354 > # As knex does not pass query parameters from the connection string we > # have to use environment variables in order to pass the desired values, e.g. > # - PGSSLMODE=<value> > > # Configure knex to accept SSL certificates > # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false > depends_on: > - postgres > > postgres: > container_name: planka_db > image: postgres:14-alpine > restart: unless-stopped > volumes: > - db-data:/var/lib/postgresql/data > environment: > - POSTGRES_DB=planka > - POSTGRES_HOST_AUTH_METHOD=trust > > volumes: > user-avatars: > project-background-images: > attachments: > db-data:``` > > It currently does not offer these variables. i will add them and test the thing.. > ``` Oops, we need to update it. Thanks for reporting! > OK... still nothing... > > but this should be unrelated to the .env problem... > > ``` > root@xxxxx:/opt/planka# docker logs --since=1h edbb82e8e78f > node:internal/process/promises:288 > triggerUncaughtException(err, true /* fromPromise */); > ^ > > Error: connect ECONNREFUSED 172.22.0.2:5432 > at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16) { > errno: -111, > code: 'ECONNREFUSED', > syscall: 'connect', > address: '172.22.0.2', > port: 5432 > } > > Node.js v18.17.1 > Tried 1 times. Waiting 5 seconds... > debug: Detected Sails environment is "production", but NODE_ENV is `undefined`. > debug: Automatically setting the NODE_ENV environment variable to "production". > debug: > ``` There is no connection to the database 🤔 Please check `DATABASE_URL` and that it's running.
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

Just checked:

/opt/planka# docker container ls
CONTAINER ID   IMAGE                              COMMAND                  CREATED       STATUS       PORTS                                       NAMES
edbb82e8e78f   ghcr.io/plankanban/planka:latest   "docker-entrypoint.s…"   2 hours ago   Up 2 hours   0.0.0.0:3000->1337/tcp, :::3000->1337/tcp   planka
bde3e71e56ef   postgres:14-alpine                 "docker-entrypoint.s…"   2 hours ago   Up 2 hours   5432/tcp                                    planka_db

planka_db log:

PostgreSQL init process complete; ready for start up.

2023-11-06 10:39:49.359 UTC [1] LOG:  starting PostgreSQL 14.9 on x86_64-pc-linux-musl, compiled by gcc (Alpine 12.2.1_git20220924-r10) 12.2.1 20220924, 64-bit
2023-11-06 10:39:49.360 UTC [1] LOG:  listening on IPv4 address "0.0.0.0", port 5432
2023-11-06 10:39:49.360 UTC [1] LOG:  listening on IPv6 address "::", port 5432
2023-11-06 10:39:49.362 UTC [1] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2023-11-06 10:39:49.367 UTC [52] LOG:  database system was shut down at 2023-11-06 10:39:49 UTC
2023-11-06 10:39:49.371 UTC [1] LOG:  database system is ready to accept connections

Docker compose:

/opt/planka# tail -n 50 docker-compose.yml
        "for i in `seq 1 30`; do
          ./start.sh &&
          s=$$? && break || s=$$?;
          echo \"Tried $$i times. Waiting 5 seconds...\";
          sleep 5;
        done; (exit $$s)"
    restart: unless-stopped
    volumes:
      - user-avatars:/app/public/user-avatars
      - project-background-images:/app/public/project-background-images
      - attachments:/app/private/attachments
      - /opt/planka/logs/app:/app/logs
    ports:
      - 3000:1337
    environment:
      - TRUST_PROXY=0
      - DATABASE_URL=postgresql://postgres@postgres/planka
      - BASE_URL=${BASE_URL}
      - SECRET_KEY=${SECRET_KEY}
      - DEFAULT_ADMIN_EMAIL=xxxxxx # Do not remove if you want to prevent this user from being edited/deleted
      - DEFAULT_ADMIN_PASSWORD=xxxxxx
      - DEFAULT_ADMIN_NAME=Martin
      - DEFAULT_ADMIN_USERNAME=Martin


      # related: https://github.com/knex/knex/issues/2354
      # As knex does not pass query parameters from the connection string we
      # have to use environment variables in order to pass the desired values, e.g.
      # - PGSSLMODE=<value>

      # Configure knex to accept SSL certificates
      # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false
    depends_on:
      - postgres

  postgres:
    container_name: planka_db
    image: postgres:14-alpine
    restart: unless-stopped
    volumes:
      - db-data:/var/lib/postgresql/data
    environment:
      - POSTGRES_DB=planka
      - POSTGRES_HOST_AUTH_METHOD=trust

volumes:
  user-avatars:
  project-background-images:
  attachments:
  db-data:

Not sure here but the connection string looks ok. Tried it with "localhost" instead - same effect.

@Nachtwind85 commented on GitHub (Nov 6, 2023): Just checked: ``` /opt/planka# docker container ls CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES edbb82e8e78f ghcr.io/plankanban/planka:latest "docker-entrypoint.s…" 2 hours ago Up 2 hours 0.0.0.0:3000->1337/tcp, :::3000->1337/tcp planka bde3e71e56ef postgres:14-alpine "docker-entrypoint.s…" 2 hours ago Up 2 hours 5432/tcp planka_db ``` planka_db log: ``` PostgreSQL init process complete; ready for start up. 2023-11-06 10:39:49.359 UTC [1] LOG: starting PostgreSQL 14.9 on x86_64-pc-linux-musl, compiled by gcc (Alpine 12.2.1_git20220924-r10) 12.2.1 20220924, 64-bit 2023-11-06 10:39:49.360 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432 2023-11-06 10:39:49.360 UTC [1] LOG: listening on IPv6 address "::", port 5432 2023-11-06 10:39:49.362 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432" 2023-11-06 10:39:49.367 UTC [52] LOG: database system was shut down at 2023-11-06 10:39:49 UTC 2023-11-06 10:39:49.371 UTC [1] LOG: database system is ready to accept connections ``` Docker compose: ``` /opt/planka# tail -n 50 docker-compose.yml "for i in `seq 1 30`; do ./start.sh && s=$$? && break || s=$$?; echo \"Tried $$i times. Waiting 5 seconds...\"; sleep 5; done; (exit $$s)" restart: unless-stopped volumes: - user-avatars:/app/public/user-avatars - project-background-images:/app/public/project-background-images - attachments:/app/private/attachments - /opt/planka/logs/app:/app/logs ports: - 3000:1337 environment: - TRUST_PROXY=0 - DATABASE_URL=postgresql://postgres@postgres/planka - BASE_URL=${BASE_URL} - SECRET_KEY=${SECRET_KEY} - DEFAULT_ADMIN_EMAIL=xxxxxx # Do not remove if you want to prevent this user from being edited/deleted - DEFAULT_ADMIN_PASSWORD=xxxxxx - DEFAULT_ADMIN_NAME=Martin - DEFAULT_ADMIN_USERNAME=Martin # related: https://github.com/knex/knex/issues/2354 # As knex does not pass query parameters from the connection string we # have to use environment variables in order to pass the desired values, e.g. # - PGSSLMODE=<value> # Configure knex to accept SSL certificates # - KNEX_REJECT_UNAUTHORIZED_SSL_CERTIFICATE=false depends_on: - postgres postgres: container_name: planka_db image: postgres:14-alpine restart: unless-stopped volumes: - db-data:/var/lib/postgresql/data environment: - POSTGRES_DB=planka - POSTGRES_HOST_AUTH_METHOD=trust volumes: user-avatars: project-background-images: attachments: db-data: ``` Not sure here but the connection string looks ok. Tried it with "localhost" instead - same effect.
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

Please clarify, are you having an infinite loading or Error: connect ECONNREFUSED 172.22.0.2:5432 and Planka doesn't start at all? Because this error can be in the logs when the database starts before Planka starts, but this is normal.

@meltyshev commented on GitHub (Nov 6, 2023): Please clarify, are you having an infinite loading or `Error: connect ECONNREFUSED 172.22.0.2:5432` and Planka doesn't start at all? Because this error can be in the logs when the database starts before Planka starts, but this is normal.
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

Just had another look at logs of "planka":

:/opt/planka# docker logs planka
node:internal/process/promises:288
            triggerUncaughtException(err, true /* fromPromise */);
            ^

Error: connect ECONNREFUSED 172.22.0.2:5432
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16) {
  errno: -111,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '172.22.0.2',
  port: 5432
}

Node.js v18.17.1
Tried 1 times. Waiting 5 seconds...
debug: Detected Sails environment is "production", but NODE_ENV is `undefined`.
debug: Automatically setting the NODE_ENV environment variable to "production".
debug:

To me that looks like planka didnt retry the connection...

@Nachtwind85 commented on GitHub (Nov 6, 2023): Just had another look at logs of "planka": ``` :/opt/planka# docker logs planka node:internal/process/promises:288 triggerUncaughtException(err, true /* fromPromise */); ^ Error: connect ECONNREFUSED 172.22.0.2:5432 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '172.22.0.2', port: 5432 } Node.js v18.17.1 Tried 1 times. Waiting 5 seconds... debug: Detected Sails environment is "production", but NODE_ENV is `undefined`. debug: Automatically setting the NODE_ENV environment variable to "production". debug: ``` To me that looks like planka didnt retry the connection...
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

It looks like Planka started up normally. I'm lost in the problem, is it still "Now i am facing and endless circle ;)"?

@meltyshev commented on GitHub (Nov 6, 2023): It looks like Planka started up normally. I'm lost in the problem, is it still "Now i am facing and endless circle ;)"?
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

I cleared cookies etc and was able to log in but still the "circle" keeps turning endlessly.
Is there any verbose debugging i can activate to help?

@Nachtwind85 commented on GitHub (Nov 6, 2023): I cleared cookies etc and was able to log in but still the "circle" keeps turning endlessly. Is there any verbose debugging i can activate to help?
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

From the Developer console in Vivaldi:

websocket.js:248 WebSocket connection to 'ws://[correct URL]/socket.io/?__sails_io_sdk_version=1.2.1&__sails_io_sdk_platform=node&__sails_io_sdk_language=javascript&EIO=3&transport=websocket' failed: WebSocket is closed before the connection is established.
p.doClose @ websocket.js:248
@Nachtwind85 commented on GitHub (Nov 6, 2023): From the Developer console in Vivaldi: ``` websocket.js:248 WebSocket connection to 'ws://[correct URL]/socket.io/?__sails_io_sdk_version=1.2.1&__sails_io_sdk_platform=node&__sails_io_sdk_language=javascript&EIO=3&transport=websocket' failed: WebSocket is closed before the connection is established. p.doClose @ websocket.js:248 ```
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

Most likely the problem is that the BASE_URL is specified incorrectly or not specified.
You have in docker-compose.yml:

- BASE_URL=${BASE_URL}
- SECRET_KEY=${SECRET_KEY}

So you need to specify the correct BASE_URL and SECRET_KEY via the .env file and run with docker compose --env-file .env up -d. Or simply specify BASE_URL and SECRET_KEY directly in the docker-compose.yml file. The BASE_URL must exactly match the address in the browser.

@meltyshev commented on GitHub (Nov 6, 2023): Most likely the problem is that the `BASE_URL` is specified incorrectly or not specified. You have in `docker-compose.yml`: ``` - BASE_URL=${BASE_URL} - SECRET_KEY=${SECRET_KEY} ``` So you need to specify the correct `BASE_URL` and `SECRET_KEY` via the `.env` file and run with `docker compose --env-file .env up -d`. Or simply specify `BASE_URL` and `SECRET_KEY` directly in the `docker-compose.yml` file. The `BASE_URL` must exactly match the address in the browser.
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

I checked and tested both the BASE_URL in the compose and .env file.
Still the circle awaits me (after cleaning cookies and logging in again).

If i incorrectly set the base url (adding a trailing / or removing http etc) i dont make it to the login at all. So i suppose the base URL is correct at this point.

@Nachtwind85 commented on GitHub (Nov 6, 2023): I checked and tested both the BASE_URL in the compose and .env file. Still the circle awaits me (after cleaning cookies and logging in again). If i incorrectly set the base url (adding a trailing / or removing http etc) i dont make it to the login at all. So i suppose the base URL is correct at this point.
Author
Owner

@meltyshev commented on GitHub (Nov 6, 2023):

Sorry, I just can't reproduce it :(
Maybe there is something wrong with the installer or some part of it isn't fully updated. We'll try to test it.

@meltyshev commented on GitHub (Nov 6, 2023): Sorry, I just can't reproduce it :( Maybe there is something wrong with the installer or some part of it isn't fully updated. We'll try to test it.
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

ok, just for completeness..
I just installed the manual docker installation (not using the script) on a fresh unrelated debian and besides having the same problem with the username i get the same trouble of being unable to get the thing running..

Would it help you if i give you direct ssh access to my vps to track down the problem?

@Nachtwind85 commented on GitHub (Nov 6, 2023): ok, just for completeness.. I just installed the manual docker installation (not using the script) on a fresh unrelated debian and besides having the same problem with the username i get the same trouble of being unable to get the thing running.. Would it help you if i give you direct ssh access to my vps to track down the problem?
Author
Owner

@daniel-hiller commented on GitHub (Nov 6, 2023):

Hi @Nachtwind85 ,
i pushed an update for the installer. now the installer will ask for default admin credentials.

Anf no, we do not provide any support via SSH.

@daniel-hiller commented on GitHub (Nov 6, 2023): Hi @Nachtwind85 , i pushed an update for the installer. now the installer will ask for default admin credentials. Anf no, we do not provide any support via SSH.
Author
Owner

@Nachtwind85 commented on GitHub (Nov 6, 2023):

Hello Daniel,

Thank you for the updated installer. I think i will just reinstall the system and try again later. As for the SSH - it just appeared to me as support.. before you answered i thought about it as helping you guys to find a problem that may be in the installer/installed system. Sorry if it looked like a beg for free support ;)

@Nachtwind85 commented on GitHub (Nov 6, 2023): Hello Daniel, Thank you for the updated installer. I think i will just reinstall the system and try again later. As for the SSH - it just appeared to me as support.. before you answered i thought about it as helping you guys to find a problem that may be in the installer/installed system. Sorry if it looked like a beg for free support ;)
Author
Owner

@Nachtwind85 commented on GitHub (Nov 7, 2023):

As a short followup...

I reinstalled on a fresh Ubuntu 22.04 with the new installer (Thank you Daniel!) using the option without SSL (as i did yesterday) and ended up at the neverending wheel yet again.

Reinstalled the system yet again this time by accident into Debian 12 i installed Planka using the new installer WITH SSL and it works now right away.

So no idea what did the trick here, wether it was the OS or the SSL option.. but maybe this information helps you.

@Nachtwind85 commented on GitHub (Nov 7, 2023): As a short followup... I reinstalled on a fresh Ubuntu 22.04 with the new installer (Thank you Daniel!) using the option without SSL (as i did yesterday) and ended up at the neverending wheel yet again. Reinstalled the system yet again this time by accident into Debian 12 i installed Planka using the new installer WITH SSL and it works now right away. So no idea what did the trick here, wether it was the OS or the SSL option.. but maybe this information helps you.
Author
Owner

@neonwatty commented on GitHub (Jun 23, 2024):

Same problem here. I installed with docker-compose. Images pulled successfully, and containers start.

I can enter the planka container and echo out the default username, password, and email correctly.

However the defaults do not on login.

@neonwatty commented on GitHub (Jun 23, 2024): Same problem here. I installed with docker-compose. Images pulled successfully, and containers start. I can enter the planka container and echo out the default username, password, and email correctly. However the defaults do not on login.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/planka#377