Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sudo: no tty present and no askpass program specified #41

Open
willemx opened this issue Apr 17, 2014 · 13 comments
Open

sudo: no tty present and no askpass program specified #41

willemx opened this issue Apr 17, 2014 · 13 comments

Comments

@willemx
Copy link

willemx commented Apr 17, 2014

This error message appears when running "mup setup" on my Mac to setup my Ubuntu linux machine for mup deployment.
I'm using ssh based authentication (which works fine when I open a ssh terminal session from my Mac to the Ubuntu server)
After hours of googling and experimenting with no luck so far, I now must bow my head in shame and ask for some kind advice...

@corv89
Copy link

corv89 commented Apr 23, 2014

I can confirm this error message on Ubuntu 14.04 server.

You can use the root account on ubuntu as a workaround.

@rmtmckenzie
Copy link

I had the same error, and am using root as a workaround as well.... but I'd prefer not to...

@arunoda
Copy link
Owner

arunoda commented Apr 24, 2014

You don't need to be root. But create an user and allow him to login with SSH keys and make sudo password less.

@arunoda
Copy link
Owner

arunoda commented Apr 24, 2014

BTW: Since Meteor needs port 80, that's why we need root like permission. But just after we bind to the port, your app will step down to a lower permission group.

So, if someone breach into your app, he will have some hard time.

@corv89
Copy link

corv89 commented Apr 24, 2014

@arunoda Thank you, that is good to know.

@LeCoupa
Copy link

LeCoupa commented May 12, 2014

As @arunoda said, run sudo visudo and edit the file to be sure that your user can run sudo with no password:

# replace this line
%admin  ALL=(ALL) ALL

# by this line
%admin ALL=(ALL) NOPASSWD:ALL

And then:

sudo service sudo restart

@Batistleman
Copy link
Contributor

@LeCoupa +1 for your solution (it would be a good idea to add this in the readme I guess?)

@arunoda
Copy link
Owner

arunoda commented May 14, 2014

@LeCoupa can you send me a PR with this added to the README.

Add under this: https://github.com/arunoda/meteor-up#setting-up-a-server

@kluzny
Copy link

kluzny commented Nov 12, 2014

Actually, I run my meteor app behind an apache server on 80, so I specified PORT: 3000 in my env block. I got all the way to when I think it is starting the server and poof, it requires sudo.

I'd prefer not to give my user sudoers at all, and if the port requirement is > 1024, then I don't think it should try to elevate with sudo.

I was able to get all the directory perms setup for the scp and file juggles, but this last problem confounds me.

I have found this dude, who lets node bind to any lower port, but I don't like that solution either
https://gist.github.com/gadr/6389682

@AWI-Koleok
Copy link

Ok i have been trying to get around this for 6 hours, i am stumped guys. I know this an old one, but its still open and it is making my life sad.

I edited sudoers via sudo visudo to insert to modify sudo and admin group as noted above, and have read about about 20 forum threads top to bottom. Am i missing something? Well, clearly i am. I have created lots of new users on ubuntu vm to try different solutions in isolation, just don't know what else to do.

I am about to just skip mup and try to deploy manually with demeteorizer, not the solution i was hoping for :(

@alexdmejias
Copy link

+1, which is annoying because I have made it work previsouly

@MasterJames
Copy link

Did you try mupx and follow migration?

@bgazzera
Copy link

@AWI-Koleok Surely you have moved on, but this worked for me.

The instructions on https://github.com/arunoda/meteor-up
say:

sudo visudo

# replace this line
%sudo  ALL=(ALL) ALL

# by this line
%sudo ALL=(ALL) NOPASSWD:ALL  

Note that this is different from the solution above.

chub pushed a commit to chub/magic-up that referenced this issue Oct 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests