I'm facing a curious problem.
I'm running a Linux box, with two Desktops. Here's my environment:
Desktop 1: Running a pet project
Terminal 1
Heroku Login: my personal e-mail
Heroku App 1
Desktop 2: Running a real project
Terminal 2
Heroku Login:same as above: my personal e-mail
Heroku App 2
When I switch from Desktop 1 to Desktop 2, from my pet project to the real project, surprise! Terminal 2 is connected in Heroku App 1!
How can I fix this, keeping separate environments, properly switching between two Heroku's environments?
Thanks in advance.
You should use the Heroku Accounts cli plugin.
$ heroku plugins:install git://github.com/ddollar/heroku-accounts.git
$ heroku accounts:add personal
Enter your Heroku credentials.
Email: david#heroku.com
Password: ******
Add the following to your ~/.ssh/config
Host heroku.personal
HostName heroku.com
IdentityFile /PATH/TO/PRIVATE/KEY
IdentitiesOnly yes
Related
I have installed rails on digital ocean on ubuntu 16.04 as production server. Now I'm trying to run the app on browser but there's some error.
How can I check the logs?
ssh into the digital ocean server using the IP address and password
cd into the folder where your app is installed. If you do not know where it is installed, use locate <appname>
you can find the logs in log/production.log. If you run your app using a different environment than production, then your log file name will be log/<environment>.log
Im deploying a rails app to a digitalocean server with these steps.
http://dokku.viewdocs.io/dokku/application-deployment/
problem is when i get to the Deploy App section it says
Now you can deploy the ruby-rails-sample app to your Dokku server. All you have to do is add a remote to name the app. Applications are created on-the-fly on the Dokku server.
git remote add dokku dokku#dokku.me:ruby-rails-sample
git push dokku master
When i enter that its asking to enter dokku:dokku.me password.
Does anyone know why or what is the default password for this? No mention of dokku.me before this step.
We don't set a password on the user, so this is likely your ssh key's password.
dokku.me is a placeholder for the documentation. Replace it with your digital ocean droplet hostname
I solved the mine by typing this command in my terminal
cat ~/.ssh/id_rsa.pub | ssh root#serverIp "sudo sshcommand acl-add
dokku laptop"
after type your password and you can try again to deploy
i am trying to connect heroku
i downloaded heroku toolbelt and installed it .
then from the command prompt i type :
heriku login
althogh i type the right credentials (i checked!!) i get
! Unable to connect to Heroku API, please check internet connectivity and
try again.
I wanted to be sure its not something with authentication
so i typed :
heroku update
just to set up a connection that doesn't need a password.
i get the message:
! Unable to connect to Heroku API, please check internet connectivity and
try again.
i saw some answers that talked about the remote option so i did that:
heroku git:remote -a my-app-name
and i got the same response.
the internet connection is ok because the git program is able to push to github.
even when i run
heroku install:something
it works.
so I tried to debug:
i downloaded a git bash so i can operate in unix through SSH
and I followed this stack question comments and tried it:
ssh git#heroku.com -T
and got :
warning permanently added the RSA host key for ip address '50.19.85.132' to the list of
known hosts.
permission denied (publickey)
then I tried to check DNS response:
ssh host heroku.com
and got :
ssh: host: no address associated with the name.
so i guess that my connection get blocked regardless of SSH .
i run netstat -a and it seems that port: 22 , 443 , 5000 that heroku uses are free.
i turned the firewall off and still no conection
what should i do?
Try heroku login first. It authenticates you.
I have two different apps I'm working on, and have deployed both to heroku. I want to work locally and just view my app at localhost:3000, but how do I switch which app localhost:3000 displays? And how do I specify that each project gets committed/deployed to the right Heroku app?
You can start each app on a different port:
$ rails s -p 4000
Or use something like Pow
When you push to Heroku it will use the folder you're currently in (the remote repo is stored as part of the Git configuration).
I bought a godaddy server, I want to deploy my rails app on it using Apache + Passenger + Capistrano.
However, it seems I can't install passenger in my server.
After I connect to my server using ssh and type 'sudo gem install passenger', it says sudo is an unknown command..
So can anyone tell me how to deploy rails app on a godaddy server?...
It depends on the Linux distribution you have installed on your machine, in order to log in as superuser you can try "sudo su" or simply "su".
Obviously you need to have the superuser password.
By default Go Daddy servers have a user you set with a password. To gain root access you will type:
su -
You will then enter the same password you logged in with originally. By default the user and root passwords are the same.