Invalid redirect_uri This integration is misconfigured. Contact the vendor for assistance.
I want to use drone on my server that resides in my room. It’s IP is always 192.168.1.7
Do I need to do something specific in OAuth settings on Bitbucket? Do I have to do something with IP?
The most common root cause for Invalid redirect_uri is when the redirect url is not configured properly when creating your Bitbucket oauth client. When Drone redirects to Bitbucket for login, it send a redirect_url query parameter, which must match exactly what you configured in Bitbucket.
Do I need to do something specific in OAuth settings on Bitbucket? Do I have to do something with IP?
The redirect happens client-side in the browser. So there are no issues using a localhost address in your authorization flow. With that being said, Bitbucket cannot send webhooks to 192.168.1.7, which means you will be unable to activate a repository in Drone. You must have a public address in order to receive webhooks from a public version control system.
So, would I be able to do it with dyn dns address?
I don’t know what that is … but you basically need an IP address or hostname that can be reached by Bitbucket. If Bitbucket cannot post an HTTP request to your Drone server, it will not be able to trigger builds.
Thanks, that is really good answer you gave me. And I think stuff like that should be provided in documentation. I bet there would be a more people with same question like mine.
If you are setting up drone on your local machine, it might be worth it to use a tool such as ngrok.
According to your docker-compose.yml you would just need to run ngrok http 80 and it will create a tunnel with a public url for you that will forward traffic to your local machine port 80. Use that url for DRONE_HOST and also for the OAUTH authorization url in bitbucket.
Of course everything is much easier if you have your own domain already
@moderators: Discourse rule of "new users can only put 2 links in the post makes it very hard to provide a helpful answer…