I have spent many hours trying to understand the implications of local installation vs global (root?) installation, but couldn't grasp enough to even formulate a question. This issue (below) with Heroku is a part of that puzzle.
Heroku had been installed-and worked with some simple rails apps. But out of the blue, I began to get an error message that I should install Heroku CLI. Thinking perhaps I had messed things up, I went ahead and used Brew to install Heroku this time (brew install heroku/brew/heroku) Though the installation was successful, I continued to get the same error message about installing Heroku CLI.
Today, I started another rails app (rails new MyApp, got the same error message Install the Heroku CLI from https://cli.heroku.com, tried brew install heroku/brew/heroku yet again, and here's a new message:
Warning: heroku/brew/heroku 7.7.8 is already installed, it's just not linked
You can use `brew link heroku` to link this version.
When I did brew link heroku , I got this:
Linking /usr/local/Cellar/heroku/7.7.8...
Error: Could not symlink bin/heroku
Target /usr/local/bin/heroku
already exists. You may want to remove it:
rm '/usr/local/bin/heroku'
To force the link and overwrite all conflicting files:
brew link --overwrite heroku
To list all files that would be deleted:
brew link --overwrite --dry-run heroku
and brew link --overwrite --dry-run heroku led to:
Would remove:
/usr/local/bin/heroku -> /usr/local/lib/heroku/bin/heroku
Am I correct to assume that I am dealing with conflicting installations?
How do I resolve the current Heroku issue--let it remove duplicate files? What does that mean? (And which gets removed: /usr/local/bin/heroku or /usr/local/lib/heroku/bin/heroku ?
I believe I have similar issues related to ruby gem installations. I'd appreciate some pointers on understanding the fundamental issue of global vs local (vs individual app installations?), specifically related to ruby, rails and ruby gems.
Related
I have a simple rails app that runs (localhost:3000) when rails server is launched, but refuses to run when heroku open is launched. I have attempted various fixes following different pointers here (and elsewhere) and repeatedly updated and installed bundler. Today, when I tried heroku open, I got this:
Install the Heroku CLI from https://cli.heroku.com.
So I did (even though I thought Heroku CLI had been installed). Weird thing is: I couldn't find the installed Heroku CLI app on my computer. To make sure Heroku CLI had been installed properly, I tried
brew install heroku/brew/heroku
as instructed on Heroku's website. Sure enough, I got this message:
Warning: heroku/brew/heroku 7.7.8 is already installed and up-to-date
To reinstall 7.7.8, run 'brew reinstall heroku'
When I tried brew reinstall heroku, I got this message:
Error: The brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Could not symlink bin/heroku
Target /usr/local/bin/heroku
already exists. You may want to remove it:
rm '/usr/local/bin/heroku'
To force the link and overwrite all conflicting files:
brew link --overwrite heroku
To list all files that would be deleted:
brew link --overwrite --dry-run heroku
Possible conflicting files are:
/usr/local/bin/heroku -> /usr/local/lib/heroku/bin/heroku
....
==> Summary
🍺 /usr/local/Cellar/heroku/7.7.8: 17,135 files, 45.5MB, built in 1 minute 9 seconds
Error: Directory not empty # dir_s_rmdir - /usr/local/Cellar/heroku/7.7.8.reinstall
What does this even mean? Should I do it without messing up other apps? I am just beginning to understand there are differences among local/global/root installations, so could use some help figuring out this one. Thanks in advance!
As of this morning, without having change anything in my Heroku CLI setup, I received the following error when I tried to run:
heroku logs -t -app <app_name>
! Please specify a version along with Heroku's API MIME type. For example, Accept: application/vnd.heroku+json; version=3.
I have since tried updating both heroku and heroku-toolbelt via brew upgrade heroku and brew upgrade heroku-toolbelt, but this did not solve the issue.
I get this error essentially whenever I try to do anything with heroku CLI, including heroku logs, heroku apps, heroku login, and heroku auth:login.
I am running MacOS, and the error posted is the only information that I am getting back from Heroku.
This discussion here: How can I specify heroku's MIME type? pertains to upgrading Heroku in Ubuntu and does not solve my issue.
I had the same problem -- but installing the new Toolbelt did not work at first. There was one other step I needed to do.
from: https://devcenter.heroku.com/articles/heroku-cli
It has instructions for each platform on installing the new cli -- and says you need to run: which heroku in order to verify the proper version is running. In my case I also needed to do a gem uninstall heroku in order to get everything working, as it was running the gem binary instead of the newly installed heroku-cli binary.
If you were using heroko Plugin for intellij
I tried alot to make it work !
From here official response
#emzeidan thanks for the report. This plugin is deprecated, and uses an old version of the Heroku API that has been shut down. Please recommend to your users that they use one of the alternative deployment mechanisms described in our DevCenter article on WAR deployment. If you can remove from the plugin from any Bamboo marketplace (or similar thing) that would be helpful too. Thanks.
This was on Sept-2017
I run the 'heroku --version' command and the toolbelt automatically updates the client. After that the login was ok.
I had the same problem on macOS Sierra 10.12.3 when I installed heroku via brew.
To get round it I ran brew uninstall heroku-toolbelt then installed via the Mac installer at https://devcenter.heroku.com/articles/heroku-cli#macos and it works fine now.
Have you specified the heroku gem in your Gemfile? If yes, then remove it.
And then, install Heroku CLI for https://devcenter.heroku.com/articles/getting-started-with-ruby#set-up and run your command.
I'm running through a ruby on rails tutorial, and I just installed the Heroku toolkit.
My problem is that whenever I try "Heroku login", or whatever heroku command, I get :
ruby1.9.1: error while loading shared libraries: libruby-1.9.1.so.1.9: cannot open shared object file: No such file or directory
I remember having cleaned my ruby installations recently, so I wonder if I just miss some libs that I have deleted or something, but I haven't been able to find anything satisfying about that.
Do you have an idea how to get out of this situation, and be able to use Heroku ?
I managed to make heroku work by installing it with gem :
gem install heroku
instead of :
sudo apt-get heroku
It seems like heroku was trying to use a ruby version out of rvm (but i deleted the ruby version which was installed before rvm). Now the gem installation took care of that.
I'm trying to get Heroku toolbelt working and it's a total nightmare. The install runs successfully, but when I run heroku update I get:
$ heroku update
failed
! undefined method `output_with_arrow' for #<Heroku::Command::Update:0x108da0120 #options={}, #args=[]>
I've tried everything, including uninstalling my heroku gem and removing the toolbelt via:
rm -rf /usr/loca/heroku
sudo rm /usr/bin/heroku
This is VERY frustrating. My environment is Mac OS 10.7 Lion and:
$ ruby -v
ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-darwin11.3.0]
$ which ruby
/Users/J/.rvm/rubies/ruby-1.9.3-p125/bin/ruby
$ heroku version
heroku-gem/2.19.2
$ which heroku
/usr/bin/heroku
Heroku support finally helped me fix this. Long story short, if you're having this issue, just run:
$ rm -rf ~/.heroku/client
Then reinstall the Heroku Toolbelt from http://toolbelt.heroku.com
If you want the long answer, here you go:
There appear to be some edge cases where update ended up with some
incorrect data and it is somewhat more difficult to recover from this.
If you first delete the ~/.heroku/client directory and subsequently
run the installer you should end up with a working result.
Heroku toolbelt is nice, but heroku_san offers all that and more. Maybe give it a shot?
https://github.com/fastestforward/heroku_san
Dont have much fuss about about uninstalling and reinstalling it again.
Just Delete .heroku folder and it will start working fine...
I had some problems installing Heroku on Windows. After installing and running at the command line for the first time, I got something like "Updating to 5.1.4-cc" and then simply 'panic:'. I couldn't find a '.heroku' folder, and after a lot of messing around, running heroku-cli.exe in {user}AppData\Local\heroku got it past that problem, then everything was good. Until this morning - one day later :) - when it tried updating again, to 5.1.5. I uninstalled everything, re-installed, same issue - but this time there was a '.heroku' folder, and deleting that got past the update issue.
Cheers
Does anyone know of a tutorial or detailed instruction set for installing Fat Free CRM? The instructions on github are clearly meant for experienced rails developers not stupid newbies like me.
When I try downloading the source code to my Mac, rails won't work and I get dozens and dozens of errors when I try to start the server. (There are way too many to even post here) I also tried setting up a new app and painstakingly copying and pasting the files from the source into the new app after it complained numerous times that it could not find the rails server. Now it continues kvetching about syntax errors and dependencies in a dozen or so files and complaining about my gems.
I did properly update the database yaml file and have tried updating my gems and running bundle many, many times but the spaghetti bowl of errors never seems to resolve much. This is the latest Rails 3 version of the app so why would it not work and why does it seem to think that half the gems are deprecated? Other people don't seem to be getting these types of errors.
I'm clearly missing something that is plainly obvious to the rest of the world and have somehow majorly screwed up the installation. How does the process of downloading a complete app differ from installing a plugin? (I've never had this much trouble with plugins.) Does anyone know of an idiot-proof checklist for downloading, installing and setting up this app? After three months of trying to make this work, I am beyond frustrated.
Thanks so much.
The first places to look
1) The Wiki Guide
2) The Readme
Here are the steps I took on Ubuntu, mostly in this order. Remember to try to complete each step without getting errors. If you get errors then it won't work.
sudo cp -r fatfreecrm/ /var/www (Copy crm to your www root)
sudo apt-get install rails (install rails + ruby + mysql)
cd /var/www/fatfreecrm
cp config/database.mysql.yml config/database.yml (copy mysql config over)
chmod 777 config/database.yml (set write permissions)
vim config/database.yml (set db password, remove /tmp/mysql.sock )
gem install bundler (install bundler)
PATH=$PATH:/var/lib/gems/1.8/bin/ ( put bundler on your path, or not )
sudo gem install mysql2 -- --with-mysql-dir=/etc/mysql/ (install mysql2)
sudo /var/lib/gems/1.8/bin/bundle install (install bundle gems)
rake db:create
rake crm:setup
rake crm:demo:load
rake crm:settings:load
sudo ruby script/rails server
Good luck finding what works for you!