Hey Ana,
execute uses mixlib-shellout under the hood, which in turn (on Unix-y platforms) forks and sets the uid of the child process. So, it does run the command “as” the specified user, but it doesn’t “log in” as that user. If what you need is for your command to run under tcsh as that user, you could use the script resource and specify an interpreter, I think.
I notice that Chef actually has a “csh” resource which might do the trick (since tcsh is csh-compatible).
Matt Moretti
hello,
I'm trying to deploy a software tha has to be install in a expecific user
when I try this, the user doesn't change(stays root).
execute 'install_scos' do
cwd '/home/S2K'
command "/opt/platform3pp/MICONYS/SCOS/S2K-5-5-1-issue-1/installMission.PARC
-c=Single -p=Standalone_single -z=Multi
/opt/platform3pp/MICONYS/SCOS/S2K-5-5-1-issue-1/SDCF_MCNYS61.xml"
user 'S2K'
group 'users'
action :run
Is there a way that i can why chef login in another user., and run commands in
there?
this has to be done in that user because it uses a diferente shell (tcsh).
Archive powered by MHonArc 2.6.16.