Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Dnr in Windows
rajnag
I trying to deploy with Dnr Script in windows. It seems Mask is not working . Is it not going to working in Windows Platform. If if (Mask) doesn't work with windows plaform , is there any way to do.
Find more posts tagged with
Comments
Adam Stoller
What version of OpenDeploy?
Is the *target* system Windows or just the *source* system?
The mask options are only for Unix - where mode-bits exist.
Chances are the answer is to use changeAccess or setAccess (in 5.5.2 speak)
What are you trying to do?
--fish
(Interwoven Senior Technical Consultant)
rajnag
We are using OD 5.5.2 . The target system is windows, sourch system is Sun.
Adam Stoller
I'll stick with my guess then - you want to use setAccess or changeAccess directives to set access rights on the deployed files.
--fish
(Interwoven Senior Technical Consultant)
Migrateduser
I think Adam is referring to the permissionRules section of the OD config. But I think the original poster is referring to the Mask attribute in the dnFile section. The mask attribute of a dnr is simply a regular expression, which should work on Windows. Perhaps the regular expression is malformed. Can you post your mask value?
Dave Smith
Sr. Software Engineer
Nike, Inc.
(503) 671-4238
DavidH.Smith@nike.com
rajnag
<dnrDeployment location="target" when="after" state="success" mask="test$">
<script cmd="c:/iw-home/iw-perl/bin/iwperl c:/iw-home/custom/bin/vin/dnr.ipl"
as="webmaster"
where="C:\raj"
async="yes"
/>
</dnrDeployment>
I want to run dnr script if test directory is deployed.
ex. If x directory is deployed to the production server then x.ipl should run. If x directory is not going deploy means x.ip shouldn't run(Target is widows platform.)
Migrateduser
Fair enough. Evidently it is not matching for some reason. What exactly are you deploying? Might be helpful to attach your deployment log to see what was deployed and then we can perhaps figure out why the regex did not match. Another question - does this script run or not after the deployment? You also have the 'state="success"' attribute set, which means if your deployment failed for any reason, the script would not run. Your deployment log should provide enough info - please attach it.
Dave Smith
Sr. Software Engineer
Nike, Inc.
(503) 671-4238
DavidH.Smith@nike.com
Adam Stoller
Thanks for the clarification - I was indeed thinking of the wrong 'mask'
In this case - dnrDeployment does not support a 'mask' attribute - only dnrFile and dnrDir support the 'mask' attribute.
So - I think if you change from dnrDeployment to dnrDir you will get the results you are looking for.
--fish
(Interwoven Senior Technical Consultant)
rajnag
Thank you I got it.
getCountryCodeFromCountryName_EN_DK.txt
rajnag
i hava directory X in Edition, I am deploying this edition with dnr. I wroted dnrdir with mask="x" . The script is running when x directory is deploying. but once x directory deployed to the producation server. If I add files or change the files in x directory , again deploying to the production server. In the production server x directory changed but dnr script is not running because that directory already deployed. but i want run a script on DnrDir eachtime any file is going chage in that directory then it sould run.
Ex.<dnrDir location="target" when="after" state="success" mask="test1$" >
<script cmd="c:/iw-home/iw-perl/bin/iwperl c:/iw-home/custom/bin/nw/dnr.ipl" as="webmaster" where="C:\nag" async="yes" >
</script>
</dnrDir>
The drn.ipl should run whenever any files chages in test1 directory(This directory already exists at production).
Migrateduser
A simple look at the documentation for the "mask" attribute of the dnrDir tag on page 253 of the OD Admin Guide states:
"The script is triggered
only
when the directory itself is deployed on the target host. Deploying a file that resides in the directory will
not
trigger the script."
What you really want is the dnrFile tag if you want a script to trigger on files being deployed. Set your mask to something like "test1\/.*$" or some variation of that. Maybe that'll work.
Dave Smith
Sr. Software Engineer
Nike, Inc.
(503) 671-4238
DavidH.Smith@nike.com
Edited by Smitty77 on 11/05/02 01:44 PM (server time).
Adam Stoller
There's a slight problem here. OpenDeploy deploys a "directory" only when the "directory" doesn't exist on the target side, otherwise it is deploying a "file" *within* the directory.
Off the top-of-my-head, one way you might be able to do this is if you were to list the X directory in the target-side filters section of the config. The "pro" would be that I think it would consider X as being deployed each time, the "con" is that it will re-deploy *everything* under X every time you perform a deployment.
Another possibility is using dnrFile with a mask of "X/.*" or something - again, I'm not sure if this will actually work, and the "con" is that, if it does, it will run your script for each and every file within X that gets deployed.
If neither of the above meet your need, you could try a dnrDeployment operation that runs *after* the deployment which firsts reads from STDIN to get a list of the files deployed, parses it to see if anything within X was deployed and if not - exits, otherwise do what you want.
For this last, you might want to take a look at iwodhome/solutions/perl/IWXML.pm
--fish
(Interwoven Senior Technical Consultant)