[ic] Development environment question

Daniel Davenport ddavenport at newagedigital.com
Wed Oct 26 08:53:04 EDT 2005



>>> karl.hoelscher at prudential.com 10/24/05 02:41PM >>>
>First off, let me say I know nothing about Interchange.
>
>But I am re-designing a site that is currently using Interchange. I would
>like create a dev environment so that the new page styles, product modules,
>etc.. can be built out, and then merged back in with the sites existing
>customer order and product catalog db.
>
>I am working with someone who is experienced in this, and actually set up
>the original site, but I am trying to dig up info as he doesn't have the
>time now.
>
>Any suggestions on the best way to build a new site while continuing to use
>the old, then launch everything into production?

the way i tend to do it works a little something like this....

# Set these as appropriate
CATDIR=/var/www/whateversite.com/catalog
NEWDIR=/var/www/whateversite.com/catalog2
CGIURL=/cgi-bin/whateversite
NEWURL=/cgi-bin/whateversite2
CATNAME=whateversite
NEWNAME=whateversite2
ICDIR=/usr/local/interchange

cp -Rp $CATDIR $NEWPLACE
sed -i -e "s:$CGIURL:$NEWURL:g" $NEWPLACE/products/variable.txt
sed -i -e "^Catalog/{i\
Catalog       $NEWNAME $NEWPLACE $NEWURL
: finish ; n ; b finish }" $ICDIR/interchange.cfg
/usr/local/interchange/bin/restart

Please note that i just wrote this, and it is probably buggy as i haven't bothered to script it until now.  =)  I've only needed to do it once or twice.

The effect of the above commands should be to duplicate the catalog's directory, change references to /cgi-bin/oldstore to /cgi-bin/newstore, add the required Catalog line to interchange.cfg, and restart IC.  The new catalog will share any SQL databases with the old one, but the file-based data (GDBM files, sessions, temp files, etc) will not be shared.

IIRC there is a SubCatalog directive which accomplishes something similar by using one catalog as a basis for another.  I think only the changed files need be in the new catalog directory.  Never used it, though, so i can't say too much more about it.

*
Daniel Davenport
New Age Digital
www.newagedigital.com





More information about the interchange-users mailing list