Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.

Mirror iManager Plug-ins on local server

Mirror iManager Plug-ins on local server

Your environment runs fine, all hosts are up and running. You install the latest OES updates but then, you have to install a few iManager NPMs which are not delivered with the OES patches.

Normally you do not allow your iManager to connect to the internet. So you have to reconfigure iManager to use the proxy, maybe set a rule at the proxy ... and afterwards switch it back to secure.

On the other hand, you can use the script below, put it into your SMT-Server and configure iManager to use the local URL.

#! /bin/bash
#
# Script downloads the iManager-Plugins, store them locally and edit the XML-File.
#
# (This is the bash3 version)
#
# by thopp, Maintainet AG (c)
# April 2017
# Version: b1-0.01
#

trap cleanup EXIT

# Create temporary File which contain the XML-data after downloads and
TMPXML=$(mktemp -p /tmp/ tmpXXX)
URLLST=$(mktemp -p /tmp/ tmpXXX)
STOREPATH=/srv/www/htdocs
PSTORE=/repo/install/imanplugin
URLNEW=http://<Your SMT-Server here>$PSTORE
NEWXML="$STOREPATH$PSTORE/local_iman_mod_desc.xml"

# Cleanup
cleanup() {
# Delete TMP-File
rm -r $TMPXML
rm -r $URLLST
}

# Get the XML-File from Novell:
wget -O $TMPXML http://www.novell.com/products/consoles/imanager/iman_mod_desc.xml

# Extract the download URLs
grep "http://" $TMPXML | cut -f 3 -d [ | cut -f 1 -d ] | sort | uniq > $URLLST


# Download the NPMs an store them incl. Path
while read URL ; do
wget -nH -x -P $STOREPATH$PSTORE $URL
done < $URLLST

# Edit the XML-File
sed "s|http://cdn.novell.com/|$URLNEW/|g" $TMPXML > $NEWXML

exit 0


If you want to use this script do the following:

Copy and paste it in a file. Name it e.g. dlimanplugin.sh. Put this file to your SMT-Server into the directory /usr/local/bin.

Set the Owner to root and the rights to R/O

#chown root:root /usr/local/bin/dlimanplugin.sh
#chmod 500 /usr/local/bin/dlimanplugin.sh


Edit at least the Variable URLNEW.

Create a cronjob for a regular run. (E.g. once a week)

At last configure iManager to use the custom Download-Site (Tab Download Plugins)

Good luck
Tags (2)

DISCLAIMER:

Some content on Community Tips & Information pages is not officially supported by Micro Focus. Please refer to our Terms of Use for more detail.
Top Contributors
Version history
Revision #:
1 of 1
Last update:
‎2017-03-31 23:05
Updated by:
 
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.