Hi Darin, Darin Perusich wrote: > Sebastian Kayser wrote: >> does someone have a working "install me some OpenCSW packages" Jumpstart >> post-install snippet that he could pass to me? I am in the process of >> setting up my first Jumpstart server and i would like to have it install a >> list of CSW pkgs after setting up the machine. > > I attached my CSW package installation script. It's nothing fancy but > get the job done for me. > >> Is this known to work with the various postinstall scripts (or cswinitsmf) >> that we have in the packages? >> >> And out of curiosity: What are the specifics to watch out for so that a >> postinstall script will work in a Jumpstart environment, just >> $PKG_INSTALL_ROOT [1] or are there any other caveats that pop up >> frequently? > > If you chroot the package installation you don't need to worry about > $PKG_INSTALL_ROOT being set. I use chroot to install everything except > pkg-get and I've never had a problem. Granted I only install a small > number of package, sudo, amanda, etc, and build the servers out > afterwards. If it's a machine I need to make a ton of clones of I set it > up and create flash images of anyways.
thanks for posting this, I finally had some time to further work on our Jumpstart setup. I found it easiest to use JET [1] and custom_scripts_n, so that post installation scripts like this are run after the final system boot. The system is then fully functional and there is no need to mess around with PKG_INSTALL_ROOT or similar. :) Easy. The adapted version of your script is attached. Thanks again. Sebastian [1] http://wikis.sun.com/display/JET/Home
#!/bin/sh # # CSW pkg installation, basic testing version # http_proxy=... export http_proxy ARCH=`/usr/bin/uname -p` ADMIN_FILE=/tmp/admin MIRROR_BASE=http://csw.informatik.uni-erlangen.de/csw PKGS=`/usr/bin/sed -ne '/^__CSWPKGS__/,//p' $0 | grep -v __CSWPKGS__` /usr/sfw/bin/wget \ -O /tmp/pkgutil \ ${MIRROR_BASE}/pkgutil-${ARCH}.pkg cat >${ADMIN_FILE} <<EOM mail= instance=overwrite partial=nocheck runlevel=nocheck idepend=nocheck rdepend=nocheck space=nocheck setuid=nocheck conflict=nocheck action=nocheck basedir=default EOM echo yes | /usr/sbin/pkgadd -a ${ADMIN_FILE} -d /tmp/pkgutil CSWpkgutil echo "mirror=${MIRROR_BASE}/current" > /etc/opt/csw/pkgutil.conf /opt/csw/bin/pkgutil -yi $PKGS exit # Put all to be installed pkgs below here __CSWPKGS__ CSWggrep CSWless CSWfindutils CSWmutt CSWlsof CSWdtracetoolkit CSWncdu
_______________________________________________ maintainers mailing list [email protected] https://lists.opencsw.org/mailman/listinfo/maintainers
