1

Following some tutorials, on Windows 7, I installed the Heroku CLI (first Git, then Heroku-x64). Git has several options to select during installation, I kept it default for most of them, except the editor and the interface: my choice is mintty. In mintty I changed my Git username and email.

After installing Heroku-x64, mintty still does not support the heroku command. And there's nothing to run in Heroku-x64's folder, so I use system's cmd.exe instead, and it supports the heroku command.

Now, following tutorials, I run heroku container:login, several seconds later it says

! not logged in

Shouldn't it ask me to input my Heroku username and password?

ChrisGPT was on strike
  • 127,765
  • 105
  • 273
  • 257
user2650501
  • 119
  • 4
  • 11

5 Answers5

6

heroku container:login is for logging into the Heroku container registry. You probably want to use heroku login instead.

ChrisGPT was on strike
  • 127,765
  • 105
  • 273
  • 257
5
sudo heroku auth:login

then

sudo heroku container:login

use sudo for CLI login and then for container login, it worked for me

fhmisml
  • 71
  • 2
  • 3
4

Ensure you are logged in on your Heroku CLI first:

heroku auth:login

Then you can login to your Heroku container registry:

heroku container:login

Running heroku/7.47.* on Ubuntu 20+ (WSL) might require sudo for both commands listed above.

Before all these, I installed gnupg2 and pass, following the answer here Cannot login to Docker account by Anish Varghese

1

I, too, had the same issue. Running heroku/7.47.3 on Ubuntu 20.04

Make sure you are running as administrator while working on Windows.

Try logging in with CLI, by help of heroku login -i and then try heroku container:login

Dharman
  • 30,962
  • 25
  • 85
  • 135
obrutus
  • 63
  • 4
1

I had problem login with the other methods, but this worked fine:

docker login --username=_ --password=$(heroku auth:token) registry.heroku.com
lmtr0
  • 136
  • 2
  • 5