The admin upgrade page /admin/upgrade checks with “github.com” for all the plugins.
If we have a private plugin (with bitbucket), then it does not check with bitbucket, but with github. And so the plugin is always shown as update to date with last commit id.
Due to this, in order to upgrade private plugin, I have to rebuild the app, which results in downtime.
I have followed this tutorial/thread to add link the plugin with bitbucket.
What do you guys do to update bitbucket/private plugins without rebuilding the app?
Thanks @sam , I was successfully able to seperate the standalone instance into web and data. It took me a bit of research to fully understand and implement it, but thanks for pointing me the right direction and link.
Hi @sam, I am now working on fixing the plugin. Needed some guidance.
The real problem lies here
In docker_manager/lib/docker_manager/git_repo.rb (54)
if url =~ /^git/
# hack so it works with git urls
url = "https://github.com/#{url.split(":")[1]}"
end
It converts the bitbucket url to github because bitbucket url starts with “git”
example : git@bitbucket.<account_name>/<plugin_name>.git
By adding a condition to check for bitbucket works ( and it detects the upgrade version too), but when I try to upgrade, it throws errror “Host key verification failed”
Then I came to know that it occurs because we remove the keys from .ssh folder in app.yml file for bitbucket.
But even if I let the ssh keys to be present inside docker container, and run the upgrade, I get the same error.
Here is the output of /.ssh/config file
Host bitbucket
StrictHostKeyChecking no
HostName bitbucket.org
IdentityFile /root/.ssh/id_rsa
I can successfully run the upgrade command inside docker container and upgrade the plugin myself, but it throws above error when running from /admin/upgrade.
I think it might be because the upgrader is not running as sudo user(correct me if I am wrong).
So can you give me some pointers, on how to proceed
Using ssh way ie git@bitbucket.org:<accountname>/<reponame>.git and pulling from bitbucket ( this is giving me error “host key verification failed”)
Using https way ie https://<accountname>@bitbucket.org/<accountname>/<reponame>.git, but I need to somehow provide password and username before upgrading. I think I can add textbox which asks for username and password before starting the upgrade