Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal server error in local server welcome page #1356

Open
1 of 3 tasks
ziXet opened this issue Oct 20, 2021 · 5 comments
Open
1 of 3 tasks

Internal server error in local server welcome page #1356

ziXet opened this issue Oct 20, 2021 · 5 comments
Labels
bug Something isn't working server Something's wrong with the Go server

Comments

@ziXet
Copy link

ziXet commented Oct 20, 2021

Internal server error at creating new project page. (please find the steps below)

Location

  • Browser
  • CLI
  • API

Steps to reproduce

  1. Following https://docs.porter.run/docs/running-porter-locally (Binary download)
  2. run: porter server start
  3. open http://localhost:8080
  4. Complete registration
  5. Getting internal server error when I click on "An Individual" or same error when I go "A Company" and submitting the form in there.

Screenshot from 2021-10-20 13-12-10

@jnfrati jnfrati added bug Something isn't working server Something's wrong with the Go server labels Oct 20, 2021
@d0x7
Copy link

d0x7 commented Oct 27, 2021

Hm, I think this is similar to the issue I have. But I couldn't complete registration (well, it did complete) - but I cannot login. I get errors in the console about unauthenticated cookies, but there aren't any cookies at all. When I try to register again, it says the email is already taken, so my account exists.

Response of /login is 200 {"id":1,"email":"user@domain.tld","email_verified":false} but is instantly followed by another HTTP request to /api/users/current which gives a similar 403 {"error":"Forbidden"}.

I don't know whether I should open a separate issue, but thought I would write under this issue first, if it's maybe a dupe.
Steps were similar: Spun up a LXC container, installing the porter CLI as in the linked guide, run the same command, went to register and got these errors (the first errors were even without any user input at all, just went to :8080 and that was it).

Porter Server Log
root@porter:~# porter server start
Set the current driver as local
Set the current host as http://localhost:8080
getting release https://github.com/porter-dev/porter/releases/download/v0.11.1/portersvr_v0.11.1_Linux_x86_64.zip
getting release https://github.com/porter-dev/porter/releases/download/v0.11.1/portersvr_v0.11.1_Linux_x86_64.zip
downloaded release portersvr to file /root/.porter/portersvr_latest.zip
unzipping portersvr to /root/.porter
getting release https://github.com/porter-dev/porter/releases/download/v0.11.1/static_v0.11.1.zip
getting release https://github.com/porter-dev/porter/releases/download/v0.11.1/static_v0.11.1.zip
downloaded release static to file /root/.porter/static_latest.zip
unzipping static to /root/.porter/static
{"level":"info","time":"2021-10-27T07:17:36Z","message":"Starting server :8080"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:17:56Z"}
{"level":"info","latency":0.03751,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:17:56Z"}
{"level":"info","latency":0.01388,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:17:56Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:18:05Z"}
{"level":"info","latency":0.260272,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:18:05Z"}
{"level":"info","latency":0.00483,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:18:05Z"}
{"level":"error","time":"2021-10-27T07:19:26Z","message":"Analytics not enabled"}
{"level":"error","time":"2021-10-27T07:19:26Z","message":"Analytics not enabled"}
{"level":"info","latency":39.802457,"status":200,"method":"POST","url":"/api/users","time":"2021-10-27T07:19:26Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:19:26Z"}
{"level":"warn","internal_error":"email already taken","external_error":"email already taken","method":"POST","url":"/api/users","time":"2021-10-27T07:19:42Z"}
{"level":"info","latency":0.514923,"status":400,"method":"POST","url":"/api/users","time":"2021-10-27T07:19:42Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:19:51Z"}
{"level":"info","latency":0.02932,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:19:51Z"}
{"level":"info","latency":0.01057,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:19:51Z"}
{"level":"info","latency":18.101136,"status":200,"method":"POST","url":"/api/login","time":"2021-10-27T07:19:53Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:19:53Z"}
{"level":"info","latency":18.821011,"status":200,"method":"POST","url":"/api/login","time":"2021-10-27T07:20:02Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:20:02Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:20:20Z"}
{"level":"info","latency":0.02897,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:20:20Z"}
{"level":"info","latency":0.01091,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:20:20Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:20:23Z"}
{"level":"info","latency":0.00778,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:20:23Z"}
{"level":"info","latency":0.01076,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:20:23Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:23:25Z"}
{"level":"info","latency":0.02868,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:23:25Z"}
{"level":"info","latency":0.01465,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:23:25Z"}
{"level":"warn","internal_error":"stored cookie was not authenticated","external_error":"Forbidden","method":"GET","url":"/api/users/current","time":"2021-10-27T07:23:27Z"}
{"level":"info","latency":0.00877,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:23:27Z"}
{"level":"info","latency":0.01291,"status":200,"method":"GET","url":"/api/metadata","time":"2021-10-27T07:23:27Z"}
{"level":"warn","internal_error":"email already taken","external_error":"email already taken","method":"POST","url":"/api/users","time":"2021-10-27T07:23:32Z"}
{"level":"info","latency":0.389543,"status":400,"method":"POST","url":"/api/users","time":"2021-10-27T07:23:32Z"}

@iCyberon
Copy link

I'm also facing the same issue.

@jnfrati
Copy link
Contributor

jnfrati commented Oct 27, 2021

Hello there! @iCyberon and @ziXet, sorry for the delay! We've been super busy with our product hunt relaunch. An easy way to bypass this issue is to set up an env variable WELCOME_FORM_WEBHOOK="http://somerandomurl.com" for launching the porter server start. We're working on a solution as that form shouldn't be shown on local instances, meanwhile, the env variable should solve the problem, sorry for the inconvenience 🙌

@jnfrati
Copy link
Contributor

jnfrati commented Oct 27, 2021

On the other hand, @d0x7 I moved the cookies issue to another issue, can we continue the discussion there? It would be nice to know a little bit more about your environment as that would help us to replicate the issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working server Something's wrong with the Go server
Projects
None yet
Development

No branches or pull requests

5 participants