Hi folks,
More idiosyncracies of Interwoven causing one or two ulcers. (No more than usual though)
Technical Details:
Interwoven TeamSite 5.0.2, Open Deploy 5.0.1 Sp2, Data Deploy 5.2.1, Solaris 8
Background: Im trying to create a workflow which publishes an Edition from the Staging area (using iwpublish) and then deploys (using iwodstart) to a given area server by our apache server.
This breaks down as follows: We have a workflow 'publish_deploy.wft' which initiates the workflow and contains a CGI task 'pub_and_deploy.cgi'. This CGI is what calls iwpublish to create an Edition and also calls iwodstart to do the deploy. (Forget the iwodstart for the moment, we're having probs with iwpublish.)
Standard practice I would have though but when I issue the iwpublish command from within the CGI script it fails with a return code of 256. Oddly enough, when I issue the exact same command directly into the unix terminal (bash shell) it works like a charm.
Can anyone help us get to the bottom of this problem?
Command being run is:
/local/interwoven/5.0.2/iw-home/bin/iwpublish -g /default/main/company/
www.mysite.intranet STAGING 'Automatic Publish'
It runs fine from the command line but not from the CGI script.
#
This workflow calls an external (CGI) task called 'pub_and_deploy.cgi'
===========================================
publish_deploy.wft
===========================================
<workflow name="Publish and Deploy"
owner="schnero1"
creator="schnero1"
description="Deploy Edition to Live">
<cgitask name="Publish and Deploy"
owner="schnero1"
description="Deploying the new files in __TAG__('Branch_path');"
start="t"
immediate="t"
lock="f">
<areavpath v="__TAG__('iw_workarea');"/>
<successors>
<successorset description="Done">
<succ v="End"/>
</successorset>
</successors>
<command v='pub_and_deploy.cgi'/>
<variables>
<variable key="deploy_branch" value="__TAG__('Branch_path');"/>
</variables>
</cgitask>
<endtask name="End">
<activation>
<pred v="Publish and Deploy"/>
</activation>
</endtask>
</workflow>
===========================================
pub_and_deploy.cgi
#The iwpublish command publishes an edition in the /default/main/company/
www.mysite.intranet/EDITION folder
==========================================================================================================================
$status = system(" /local/interwoven/5.0.2/iw-home/bin/iwpublish -g /default/main/company/
www.mysite.intranet STAGING 'Automatic Publish' ");
if ($status == 0) #If result was good.
{
#do something
}
else
{
kotz("Couldn't publish branch: '$branch' <br><br>Status returned from Publish command: $status");
}
===========================================================================================================================
The status returned by this is 256
Deployment descriptors found in
/local/interwoven/5.0.2/iw-home/OpenDeployNG/conf (drwrwxrwx)
www.mysite.intranet.xml (rwxrwxrwx)
If I run a system command 'id' from the CGI script e.g. system("id"); and print to the client, the uid is:
uid=10001(iwui) gid=60001(nobody)
The permissions on the EDITION folder n /default/main/company/
www.mysite.intranet branch cannot be changed (even as 'root'). (Strange IW filesystem usage)
Ive also tried changing the user of the workflow within my publish_deploy.wft file e.g. owner="root" instead of owner=__TAG('iw_user'); and this hasn't solved it.
By the way, does anyone know of the IW command line tool to identify and decrypt these error codes?
Any ideas?
Cheers v.much.
Pete.