Quantcast
Channel: Ask Puppet: Puppet DevOps Q&A Community - RSS feed
Viewing all articles
Browse latest Browse all 6104

How can I execute bash command line in Exec resource type?

$
0
0
Hi, I have this Exec declaration: exec { 'Normalize MP3 filename': environment => ["t=0"], command => 'for i in *mp3; do mv -v $i track_`seq -f "%03g" $t $t`.mp3 ; t=`expr $t + 1`; done', cwd => "$resource_path/res/raw", } -> When my manifest runs it get this error: Error: Could not find command 'for' Error: /Stage[main]/Make_it::App_mp3files/Exec[Normalize MP3 filename]/returns: change from notrun to 0 failed: Could not find command 'for'

Viewing all articles
Browse latest Browse all 6104

Trending Articles