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

Tweaks and modifications #85

Closed
wants to merge 2 commits into from
Closed

Conversation

koenpunt
Copy link
Contributor

@koenpunt koenpunt commented Apr 3, 2013

A summary of the changes:

  • Added global option :as_user for all installers (Sprinkle::Installers::Installer) to run commands as specific user (su -c '....' -s /bin/sh #{@options[:as_user]})
  • Added :sudo as global option for all Sprinkle::Installers::Installer classes
  • Updated readability of the push_text and replace_text installers

@koenpunt koenpunt closed this May 14, 2013
@koenpunt
Copy link
Contributor Author

To run commands under a specific user. For example the installation of rbenv under my deploy user. And not having to change file ownership after creating them

@joshgoebel
Copy link
Contributor

Why wouldn't your default user be "deploy" in that case with sudo when needed?

@koenpunt
Copy link
Contributor Author

Because the deploy user has restricted permissions on the system (specific commands in sudoers file)

@joshgoebel
Copy link
Contributor

Which user is sprinkle connecting as then, root?

@koenpunt
Copy link
Contributor Author

Nope, another user with full sudo rights.

@joshgoebel
Copy link
Contributor

Isn't as_user something that really more applies to runner than to the installer base class? I guess I'm continuing this discussion to see if there is still a place for us to use as_user, since it's interesting.

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

Successfully merging this pull request may close these issues.

2 participants