dokploy icon indicating copy to clipboard operation
dokploy copied to clipboard

Internal Server Error after creating GitHub App

Open dancamdev opened this issue 1 year ago • 31 comments

To Reproduce

  1. Go to dashboard/settings/git-providers
  2. Select GitHub
  3. Enable Organization and insert a valid organization name.
  4. Get redirected to GitHub and create the GitHub App
  5. The redirectUrl after creating an app fails and displays an Internal Server Error.

Current vs. Expected behavior

It should successfully connect the GitHub created app to the dokploy instance.

Provide environment information

Operating System: Ubuntu 24.04.1

Which area(s) are affected? (Select all that apply)

Installation

Are you deploying the applications where Dokploy is installed or on a remote server?

Remote server

Additional context

No response

Will you send a PR to fix it?

Maybe, need help

dancamdev avatar Sep 15 '25 17:09 dancamdev

Same issue.

For me it also says "Internal Server Error" when not enabling Organization.

Provide environment information Distributor ID: Debian Description: Debian GNU/Linux 12 (bookworm) Release: 12 Codename: bookworm

Are you deploying the applications where Dokploy is installed or on a remote server?" Where Dokploy is installed.

laursenx avatar Sep 15 '25 18:09 laursenx

Same here. DNS configured via Cloudflare. Tried proxied and non-proxied A records. SSL on Full (Strict). Doing a docker logs <dokploy-container-id> via ssh'ing into the server shows:

Error [HttpError]:
    at <unknown> (HttpError:) {
  status: 401,
  response: [Object],
  request: [Object]
}
 ⨯ Error [HttpError]:
    at <unknown> (HttpError:) {
  status: 401,
  response: [Object],
  request: [Object]
}

exaby73 avatar Sep 15 '25 18:09 exaby73

From logs in Dokploy:

Error [HttpError]: Requires authentication - https://docs.github.com/rest
at <unknown> (HttpError: Requires authentication - https://docs.github.com/rest) {
status: 401,
response: [Object],
request: [Object]
}
⨯ Error [HttpError]: Requires authentication - https://docs.github.com/rest
at <unknown> (HttpError: Requires authentication - https://docs.github.com/rest) {
status: 401,
response: [Object],
request: [Object]
}

exaby73 avatar Sep 15 '25 19:09 exaby73

Image

It might be some Github API issue. Earlier today I was able to create a new app without any friction, but now I've tested on 3 servers including the new one that was successful earlier, none of them were able to complete the app creation.

P.s: Checking the Github Community there's some mentions to App auth issues on other platforms too: https://github.com/orgs/community/discussions/173595

jhon2c avatar Sep 15 '25 19:09 jhon2c

I am glad I am not the one facing this issue alone, had to provision 4 other servers to try fix the issue. It started with copilot:

2025-09-15 21:10:45.540 [info] Starting server pylance mcp server 2025-09-15 21:10:45.541 [info] Connection state: Starting 2025-09-15 21:10:45.542 [info] Starting server from LocalProcess extension host 2025-09-15 21:10:45.815 [info] Connection state: Running 2025-09-15 21:10:45.922 [info] Connection state: Error Error sending message to http://localhost:4599/stream: TypeError: fetch failed 2025-09-15 21:10:45.923 [error] Server exited before responding to initialize request. 2025-09-15 21:11:42.426 [info] Starting server pylance mcp server 2025-09-15 21:11:42.427 [info] Connection state: Starting 2025-09-15 21:11:42.427 [info] Starting server from LocalProcess extension host 2025-09-15 21:11:42.429 [info] Connection state: Running 2025-09-15 21:11:42.483 [info] Connection state: Error Error sending message to http://localhost:4599/stream: TypeError: fetch failed 2025-09-15 21:11:42.483 [error] Server exited before responding to initialize request. 2025-09-15 21:12:14.048 [info] Starting server pylance mcp server 2025-09-15 21:12:14.050 [info] Connection state: Starting 2025-09-15 21:12:14.050 [info] Starting server from LocalProcess extension host 2025-09-15 21:12:14.051 [info] Connection state: Running 2025-09-15 21:12:14.067 [info] Connection state: Error Error sending message to http://localhost:4599/stream: TypeError: fetch failed 2025-09-15 21:12:14.068 [error] Server exited before responding to initialize request.

Now ran into issue while connecting to Dokploy yet I configured 3 servers successfully yesterday:

I now get this error:

Error [HttpError]: Requires authentication - https://docs.github.com/rest at (HttpError: Requires authentication - https://docs.github.com/rest) { status: 401, response: [Object], request: [Object] } ⨯ Error [HttpError]: Requires authentication - https://docs.github.com/rest at (HttpError: Requires authentication - https://docs.github.com/rest) { status: 401, response: [Object], request: [Object] }

axoblade avatar Sep 15 '25 19:09 axoblade

Running into the same issue, also using a fresh Debian 12 install. I am running the dokploy instance on a server within our internal network without a domain. Is that not possible?

mvdve avatar Sep 15 '25 19:09 mvdve

Same problem here. DNS configured via Cloudflare.

morindo avatar Sep 15 '25 20:09 morindo

Same problem here. DNS configured via Cloudflare.

Be rest assured, do not touch anything, do not fall victim like i have while i destroyed already working servers

axoblade avatar Sep 15 '25 20:09 axoblade

The github status page just updated and they cleared out all the errors regarding the github api. In my case im still receiving erros when trying to add the github app...

URL https://domain.com/api/providers/github/setup?code=xxxxxxxxxxxx&organizationId=xxxxxxxx&state=xxxxxxxxx&userId=xxxxxxx

Response Internal Server Error

gabrielrf01 avatar Sep 15 '25 21:09 gabrielrf01

same here, also using cloudflare dns

agussanguesa32 avatar Sep 15 '25 22:09 agussanguesa32

any workaround for this?

parthibx24 avatar Sep 15 '25 22:09 parthibx24

I have resorted to deploy using docker-compose until this issue is fixed

axoblade avatar Sep 16 '25 03:09 axoblade

Hello, any solution?

edsonalanis avatar Sep 16 '25 04:09 edsonalanis

Hello, same issue here. Tried the old workaround: https://www.loom.com/share/8e97e897b4074fa98b61bd1d7b42e653, but no luck.

gaiborjosue avatar Sep 16 '25 04:09 gaiborjosue

Olá, mesmo problema aqui. Tentei a solução alternativa antiga: https://www.loom.com/share/8e97e897b4074fa98b61bd1d7b42e653 , mas sem sucesso.

For me it's not even enough to create the GitHub App

edsonalanis avatar Sep 16 '25 04:09 edsonalanis

It seems like a change on GitHub's part... apparently, the endpoint we used for authentication, which used to be open, now requires authentication, which is strange. I don't know if it's a bug, but it seems that other platforms are having the same problem.

Siumauricio avatar Sep 16 '25 04:09 Siumauricio

exige autenticação, o que é estranho

It may be related to the hacker attack that GitHub suffered a few days ago and made them change the way they make this connection.

edsonalanis avatar Sep 16 '25 04:09 edsonalanis

Isn't there another way to connect to GitHub other than this? Other tools offer the option to enter a generated token under "Personal access tokens."

edsonalanis avatar Sep 16 '25 05:09 edsonalanis

Ideally, automatic configuration for anything shouldn't be the only option. If we had instructions on how to configure the GitHub app manually, then this wouldn't be such a huge issue. For GitLab, Bitbucket and Gitea this is already the case. Give us manual instructions as automatic configuration is awesome until the APIs break

exaby73 avatar Sep 16 '25 06:09 exaby73

Commenting to follow. I have the same issue

cssfr avatar Sep 16 '25 06:09 cssfr