Neil,
I do run cf-promises on every config file I test prior to running it with
"cf-agent -vf". I received "cf3> -> Inputs are valid" message when I ran
/tmp/templates/delete_local_folder.cf.test against it.
I have implemented your suggested config and it worked like a charm.
Thank y
Neil,
Here is my self contained example. I apologize for not providing it. My
config file produces the following directory structure with files in them.
After creating this structure, I have been attempting to delete the folder
/tmp/test/create_folder1/create_folder2 and the files in it via
CORRECTION:
Nothing gets deleted but the error provided is correct.
Regards,
j
-Original Message-
From: Jerome Yanga
Sent: Friday, June 17, 2011 1:04 PM
To: 'help-cfengine@cfengine.org'
Subject: RE: Cfengine Help: Re: Cfengine Help: Deleting a Local File
Neil,
Thank you for
Neil,
Thank you for the sample config. However, there is still a problem. The
config below which is similar to your sample not only deletes create_folder2
but also create_folder1. Moreover, I have pasted the errors I got.
FYI, there are files in create_folder2.
bundle agent
Nope. This is from cfengine_stdlib.cf
body delete tidy
{
dirlinks => "delete";
rmdirs => "true";
}
Regards,
j
-Original Message-
From: help-cfengine-boun...@cfengine.org
[mailto:help-cfengine-boun...@cfengine.org] On Behalf Of no-re...@cfengine.com
Sent: Friday, June 17, 2011 10:49
Neil,
I tried your suggestion and I am getting the error below.
Config file:
bundle agent deleteLocalFolder
{
files:
"/tmp/test/create_folder1/create_folder2"
comment => "delete local folders",
include_basedir => "true",
#
Neil,
I apologize. I thought that by providing you the whole config file, it would
be easier for you to understand what I am trying to do.
To answer your question, I put a file_select in the promise because I get this
error below if I don't have it and it does not delete anything.
cf3> ..
Thanks, Neil.
Is there a way to replicate "rm -rf /tmp/"? I am getting the error below.
"cf3> !! Delete directory /data/test/create_folder1/create_folder3 failed
(cannot delete node called "create_folder3")
cf3> !!! System reports error for rmdir: "Directory not empty""
Regards,
j
-Orig