Valet-plus: Almost all CLI commands require root password

Created on 23 May 2018  Â·  6Comments  Â·  Source: weprovide/valet-plus

I'm not sure why, but running valet on-latest-version or even just valet alone prompts me for my root password:

➜  ~ valet on-latest-version
Password:

➜  ~ valet
Password:

It appears sudo is being called behind the scenes, even for commands which shouldn't need to be run as root.

If I'm not wrong, the only command which should require the root password is

valet restart [nginx|dnsmasq]

Any idea what can be done to stop this?

1.0.x

Most helpful comment

@JPry I'll look into that change, we should be able to merge upstream for it. It will probably achieve the requested result at first glance. Thanks for bringing that to our attention.

All 6 comments

Introduced in https://github.com/weprovide/valet-plus/commit/81ac3c001002712790dd0296f3649f979e5fff0c. Was reverted to laravel/valet standard. If we reintroduce that piece of code in the binary it will cause the following problems:

  • Sudo will not be the default for some commands. Some commands will be default sudo, others will default to your user.
  • Some commands will be run as the user making CommandLine#runAsUser() obsolete and a confusing function.

Could we add the trust command, like Valet did in laravel/valet#502?

@JPry I'll look into that change, we should be able to merge upstream for it. It will probably achieve the requested result at first glance. Thanks for bringing that to our attention.

@Neodork Still need this.

@tyurderi check this fix from @samgranger https://gitter.im/valet-plus/Lobby?at=5b0e8978160c567d16ebfc55
I've been using it locally and it works great. I asked in slack if that is the correct solution though, so can't make a PR yet.

Dear Contributor,

With the release of Valet+ 2.0.0 the Valet+ development team and contributors have implemented the contribution guidelines. The contribution guidelines aim to improve the support and workflow of Valet+. For further information why this was implemented please check https://github.com/weprovide/valet-plus/issues/393.

We're closing this ticket because it does not follow the correct format. If you feel your ticket is still relevant we encourage you to re-open your ticket using the correct format.

Kind regards,
The Valet+ team

Was this page helpful?
0 / 5 - 0 ratings

Related issues

perteraul picture perteraul  Â·  3Comments

NurdinDev picture NurdinDev  Â·  4Comments

SnowCommerceBrand picture SnowCommerceBrand  Â·  4Comments

dustbuster picture dustbuster  Â·  5Comments

zcuric picture zcuric  Â·  4Comments