Why am I unable to push my app to Heroku? - ruby-on-rails

I haven't been able to get Heroku to update my app for some reason. This is the first app I've had problems with this happening. I've tried a couple different methods, but everything I've tried just says in the command "everything is up to date." and when I check heroku, it's just an early version of my app. Any idea why it won't update on Heroku?
Here is what I've tried:
$ bundle exec rake test
$ git add -A
$ git commit -m "..."
$ git checkout master
$ git merge blah
$ bundle exec rake test
$ git push
$ git push heroku
$ heroku run rake db:migrate
and I've also tried this as well:
$ git status
$ git add .
$ git commit -m "..."
$ git push heroku master
$ heroku run db:migrate
Heres the git status:
$ git status
On branch master
Your branch is up-to-date with 'origin/master'.
nothing to commit, working directory clean
Here's trying to force it
$ git push heroku master --force
Everything up-to-date
Here's with git remote -v
heroku https://git.heroku.com/stupidapp1.git (fetch)
heroku https://git.heroku.com/stupidapp1.git (push)
origin https://github.com/Tyrantt47/stupidapp1.git (fetch)
origin https://github.com/Tyrantt47/stupidapp1.git (push)

Curtis, I feel like this answer could be judged as the antithesis of a good dev, but if you have the code you want to deploy checked into version control and locally, why not just push it to a new Heroku app.
If the name of the repository is any indication of the scale of the application, I would say try it and see the results.
Heroku provides good documentation on migrating a database from one app to another and its add-on services are easy to get setup, if either one of those are a concern.
Food for thought...

I think that the syntax is
git push -f heroku master

Related

Database entry not showing up on Heroku

I am developing my first Rails app, and I have made some database entries that are showing up in the development environment, but not in the production environment (Heroku). I have run
git add
git commit
git push origin master
git push heroku master
rake db:migrate
in the terminal.
$ heroku create
$ git push heroku master
After running these commands, to get the application’s database to work, you’ll also have to migrate the production database:
$ heroku run rake db:migrate
$ heroku open
if this doesn't work please show your logs.
you just need to run
heroku run rake db:migrate

Why deploy my rails app on heroku does not work?

I am new on Ruby/Rails application development. I already love Ruby/Rails because it's easy to learn. I've built an Rails application and i try to deploy on Heroku.
When i type :
heroku create
Creating app... done, stack is cedar-14
https://aqueous-plateau-17182.herokuapp.com/ | https://git.heroku.com/aqueous-plateau-17182.git
I don't have the following message :
Git remote heroku added
I think there is a problem with my remote :
git remote -v
heroku git#bitbucket.org:pracede/hubapp.git (fetch)
heroku git#bitbucket.org:pracede/hubapp.git (push)
origin git#bitbucket.org:pracede/hubapp.git (fetch)
origin git#bitbucket.org:pracede/hubapp.git (push)
git config --list | grep heroku
remote.heroku.url=git#bitbucket.org:pracede/hubapp.git
remote.heroku.fetch=+refs/heads/*:refs/remotes/heroku/*
1.There are remote but heroku refers to bitbucket. Is it correct ?
If no correct, how to do, please ?
I cannot deploy. I have the following message :
git push heroku master
Everything up-to-date
My rails application is not alive. Is someone could explain me, please ?
Thanks
First delete the current remote heroku reference(i.e pointing to bitbucket remote ) with -
git remote rm heroku
Add then add heroku remote to your repo -
git remote add heroku git#heroku.com:aqueous-plateau-17182.git
Hope this helps!

How to set up rails git repos?

I want to git push to my rails app. I can't seem to find any information about it.
I want my rails app to be something like Heroku in a sense I could git push to it, though obviously building is a whole other matter.
How to be able to git push to rails app?
To Push into git you can follow those steps one after another
$ cd my_project
$ git init
$ git add *
$ git commit -m "My initial commit message"
$ git remote add origin git#example.com:my_project.git
$ git push -u origin master
To Push you rails app to heroku you have to follow the following steps
First install gem heroku
$ gem install heroku
then, Login to heroku with your credentials
$ heroku login
then, Add following gem to your Gemfile
group :production do
gem 'pg'
gem 'rails_12factor'
end
Make sure you add a specific ruby version in your Gemfile, ex: ruby '2.1.2'
run $ bundle install
Create heroku app
$ heroku create
Push to heroku
$ git push heroku master
Run migrations
$ heroku run rake db:migrate
that's it :) Here is a great documentation on heroku page, you can see for more details.

How do you push from nitrous.io to GIT

I was following this guide Nitrous to Heroku Guide
It describes the process to fork a git repo but I want to push my directory of stuff to Git and then to Heroku. Well I really wanted to just push my stuff to Heroku. Argghh now I am lost.
So either push directly to Heroku or to Git and then on to Heroku.
Tutorial links always welcome if I have missed something.
Thanks in advance. :)
You will need to add two remotes within the same project.
Initiate your project for Git
$ git init
To add Github remote to your project and push:
$ git remote add origin https://github.com/user/repo.git
# Set a new remote
$ git remote -v
# Verify new remote
# origin https://github.com/user/repo.git (fetch)
# origin https://github.com/user/repo.git (push)
$ git add .
$ git commit -m "initial commit"
$ git push origin master
To create a new Heroku project and push the remote to your project:
$ heroku create
$ git remote -v
# Verify new remote (you will see heroku and origin now
# heroku git#heroku.com:falling-wind-1624.git (fetch)
# heroku git#heroku.com:falling-wind-1624.git (push)
# origin https://github.com/user/repo.git (fetch)
# origin https://github.com/user/repo.git (push)
$ git push heroku master
This is a standard strategy which you will everytime want to git add, commit, and then push to both origin master (Github) and heroku master (Heroku).
If you have local data on your Nitrous Box, which isn't yet a git repo, what you need to do is:
cd /path/to/stuff
git init
git add .
git commit -m "Make stuff into a git repo"
From there, you can follow the steps described in the tutorial you mention in your question, except for step 7: you don't need to clone a repo, since you just created one.

Heroku rails help to push app

My git console:
Home#PC /c/rails/konkurranceportalen (master)
$ git push heroku master
Enter passphrase for key '/c/Users/Home/.ssh/id_rsa':
! No such app as warm-spring-423
fatal: The remote end hung up unexpectedly
Home#PC /c/rails/konkurranceportalen (master)
I have created a app named "vinderhimlen" that I want to push my rails app to
you need to change your remote heroku (if you typed git remote -v youd still see warm-spring-423) try something like this:
git remote rm heroku
git remote add heroku git#heroku.com:vinderhimlen.git

Resources