-
-
Notifications
You must be signed in to change notification settings - Fork 50
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
Bitbucket connection issue Unexpected end of file from server #1165
Comments
I don't think this is related to dex, the main issue I think is the following |
Try connecting to the database directly, look for the Vcs table, update the vcs connection to PENDIG, login to the UI search the vcs connection and click the connect button and try to run your workspace again. |
@alfespa17 thanks for your reply. What database are you talking about? and do you mean PENDIG or PENDING? |
It looks good in the UI but maybe the internal refresh token failed, so forcing the vcs connection might fix your issue. Try connection to the terrakube database and change the values that I mentioned above |
This is the default password and you can see the user in the same place |
It is PENDING, not PENDIG
|
Updated to 'PENDING' then I reconnected via the UI to the VCS Provider. And then I ran my workspace again. But am getting the same error?
|
This is how it is on the UI: |
Not sure what could be the issue but I guess is related to some network connectivity. Did you try deleting the executor pod? From the above message it looks like it not even downloading any terraform plugins, it like it is running inside an empty folder. Can you try running this template that show the current files inside the working directory flow:
- type: "terraformPlan"
step: 100
commands:
- runtime: "BASH"
priority: 100
before: true
script: |
pwd
ls -al
cd $workingDirectory
ls -al |
I know. It is really strange. I checked the working directory. I tried again after deleteing the executor pod after updating the vcs connection. Also checked my workspace variables but I've added global variables to the workspace and I would get 'authentication' error if any variables were wrong/not updated.
|
Yeah, is weird @MARVELMafia, what I can see from your logs is that there are no files downloaded from bitbucket. I can only see 2 folders that are used by terrakube called
I am just guessing now maybe the following. Did you check if the repository that you were using was renamed? |
@alfespa17 I just tried
I created a new oauth consumer on bitbucket and tested it again and I see the following: I feel like something is terribly rotten as no workspaces are getting cloned. |
Try creating a new vcs connection using a new oauth application, once created connect to the database and update the vcs_id property inside the workspace table, maybe that works for you |
I just attempted to do that and I see the same errors. I think its time I park my terrakube quest. |
I am getting the same error, but I am not using bitbucket, instead I am using GitHub Enterprise. It seems that the token expires after a certain amount of time (I'm assuming 8 hours), since the token generated by the GitHub App is set to only last 8 hours, but should refresh with the refresh token. The refresh token in the database is set to null, so I'm assuming that the token is not getting refreshed. in the UI, i see the Any guidance @alfespa17 ? Anything that will cause the token to get refreshed? |
Maybe it is a token expiration configuration restriction in github enterprise, as you can see here we create a task to refresh the token for other vcs provider but it for github oauth app it was not needed it when I added that feature some time ago.
|
@alfespa17 thanks! so there's an option to disable token expiration, but we'd rather go the safer route if possible and refresh the tokens. If we can add this to the road map for the next release, that'd be great! This product is great BTW! We are still testing it but we can't wait to fully productionize this! Thanks! |
I would like to add something like that but I don't have a github enterprise to test github oauth app with token expiration. There is a pull request that adds support for github apps that I still need to review next week, in the future you can use a github app (I understand that you have better security options) instead of the github oauth app that is currently supported. |
interesting, i am actually already using https://docs.terrakube.io/user-guide/vcs-providers/github-enterprise it works fine except for the token refresh. |
GIthub oauth apps are the only supported right now, maybe for next version we add github apps. |
Feedback
Hi, could the following error be the reason why I any 'plan' or 'plan & apply' I run via terrakube simply tells me that
No changes. Your infrastructure matches the configuration.
The text was updated successfully, but these errors were encountered: