plane icon indicating copy to clipboard operation
plane copied to clipboard

[bug]: Provided default application user name and password don't work

Open andy47 opened this issue 1 year ago • 52 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Current behavior

When I have the application running via docker on my laptop I can't log into the application using the default user name and password provided on https://docs.plane.so/self-hosting

The login fails and I see this pop-up error message;

image

Steps to reproduce

  1. Start the application using docker-compose up
  2. Go to the application sign in page (on my machine that is http://localhost:8005/signin )
  3. Attempt to login with the default user name and password supplied on https://docs.plane.so/self-hosting
  4. Login fails.

Environment

Deploy preview

Version

Self-hosted

andy47 avatar Apr 05 '23 15:04 andy47

same here

airdogvan avatar Apr 05 '23 18:04 airdogvan

Thanks for reporting this @andy47, @airdogvan. We are working on fix for this with high priority. We'll revert back soon.

sphynxux avatar Apr 05 '23 18:04 sphynxux

same

galaris avatar Apr 08 '23 19:04 galaris

We have fixed the above issue in our develop branch we are still aggressively testing it and fixing any bugs.

pablohashescobar avatar Apr 09 '23 08:04 pablohashescobar

Related to #477.

vihar avatar Apr 09 '23 08:04 vihar

Still seeing this bug on develop branch

soxrok2212 avatar Apr 11 '23 03:04 soxrok2212

Same issue here, clicking on forgot password shows "Setting up you workspace" forever

tkerr97 avatar Apr 11 '23 04:04 tkerr97

Greetings everyone, I am the maintainer of Plane. I would like to inform you that the error you have encountered has been resolved in our latest development branch. In order to successfully apply this fix, kindly delete all volumes, network, and the container itself. After which, please proceed with rebuilding the images. Thank you.

pablohashescobar avatar Apr 11 '23 05:04 pablohashescobar

Unless you leave the nginx port at 80, you still get the error (it appears to be CORs related). It would be nice to be able to change the port, since I have another docker container on my machine that I would rather have that port.

tkerr97 avatar Apr 11 '23 06:04 tkerr97

Same problem here as @tkerr97 reports.

I already have services running on port 80 and 3000 on the host machine. So I changed nginx to run on port 8005 and plane-web to run on port 3003.

Same error message.

andy47 avatar Apr 11 '23 11:04 andy47

Hey, can you also please try by updating the Dockerfiles for both backend and frontend Dockerfile.api and Dockerfile.web also the compose as well.

pablohashescobar avatar Apr 11 '23 13:04 pablohashescobar

On a clean machine I did the following:

  1. Cloned the repo
  2. Ran setup.sh with my IP
  3. Edited the docker-compose.yml to have the port I want
  4. Ran docker-compose up
  5. Attempted to login with the default username and password and still got the error

tkerr97 avatar Apr 11 '23 18:04 tkerr97

same

heromiyo avatar Apr 13 '23 13:04 heromiyo

Develop branch solved for me, but I needed to run this to force a rebuild: docker compose up --build

Thanks to n1kh1l!

galaris avatar Apr 14 '23 11:04 galaris

Still getting this error when changing the nginx port in docker-compose.yml to - 4000:80 as I can't use port 80 on my machine.

ghost avatar Apr 18 '23 10:04 ghost

am still getting this error after doing all the suggested options, this is what i see in the logs nginx | 172.18.0.1 - - [19/Apr/2023:09:34:22 +0000] "POST /api/sign-in/ HTTP/1.1" 502 559 "http://localhost/signin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36" nginx | 2023/04/19 09:34:22 [error] 23#23: *7 connect() failed (111: Connection refused) while connecting to upstream, client: 172.18.0.1, server: , request: "POST /api/sign-in/ HTTP/1.1", upstream: "http://172.18.0.2:8000/api/sign-in/", host: "localhost", referrer: "http://localhost/signin"

heromiyo avatar Apr 19 '23 09:04 heromiyo

Hi @heromiyo are you running this on cloud server or local system and also can you please specify which branch are you in.

pablohashescobar avatar Apr 19 '23 09:04 pablohashescobar

for error above it was locally on windows but i have deployed the same app on the cloud VM and the branch is develop for both and for the cloud VM one i just cloned the repo just now and did the README step by step https://80-port-c649136594064ade.labs.kodekloud.com/signin

heromiyo avatar Apr 19 '23 10:04 heromiyo

please use https://80-port-c649136594064ade.labs.kodekloud.com/signin to test login using default credentials @pablohashescobar

heromiyo avatar Apr 19 '23 10:04 heromiyo

Hey @heromiyo can you check if the backend container is running

pablohashescobar avatar Apr 19 '23 10:04 pablohashescobar

it is, here is a terminal you can use to check aswel @pablohashescobar
https://terminal-c649136594064ade.labs.kodekloud.com/

heromiyo avatar Apr 19 '23 10:04 heromiyo

Hey @heromiyo all the containers are running. The problem is the frontend container is trying to access localhost for API. image

Can you please run the setup script again ./setup.sh https://80-port-c649136594064ade.labs.kodekloud.com again. Then please rebuild all the containers using docker compose up --build. Please let us know if the problem still persist

pablohashescobar avatar Apr 19 '23 10:04 pablohashescobar

@pablohashescobar still there but the api url is updated https://80-port-c649136594064ade.labs.kodekloud.com/signin

heromiyo avatar Apr 19 '23 10:04 heromiyo

and also fails on localhost image

heromiyo avatar Apr 19 '23 11:04 heromiyo

Hi @heromiyo it would be awesome if you could send your envs at apiserver/.env and apps/app/.env and also the nginx configuration.

pablohashescobar avatar Apr 19 '23 12:04 pablohashescobar

Hello everyone,

We have updated our docker setup and now have pushed pre-built images to DockerHub as well which can be used by using docker-compose -f docker-compose-hub.yml up. Detailed docs can be found here https://docs.plane.so/self-hosting

pablohashescobar avatar May 04 '23 04:05 pablohashescobar

Wonder if a comment will reopen this.

I've cloned the lasted -dev branch, clean setup, still incorrect password for default admin user.

HearthCore avatar May 07 '23 07:05 HearthCore

Hey @HearthCore it would be awesome if you could share browser network logs and docker logs as well.

pablohashescobar avatar May 07 '23 07:05 pablohashescobar

I've ran into this as well. Brand new Ubuntu 22.04 box. I'll gladly provide docker logs, but which containers? All of them?

As for network logs, when I attempt to login with the default creds, it sends the following headers:

OPTIONS /api/sign-in/ undefined
Host: localhost
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/113.0
Accept: */*
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Access-Control-Request-Method: POST
Access-Control-Request-Headers: content-type
Referer: http://plane:3000/
Origin: http://plane:3000
DNT: 1
Connection: keep-alive
Sec-Fetch-Dest: empty
Sec-Fetch-Mode: cors
Sec-Fetch-Site: cross-site

With the response of:

Response body is not available to scripts (Reason: CORS Failed)

Alcatraz077 avatar May 20 '23 04:05 Alcatraz077

When will this fix be deployed to the docker images on hub.docker.com

shadowjig avatar May 29 '23 18:05 shadowjig