summaryrefslogtreecommitdiffstats
path: root/cm-container/get-type-files.sh
diff options
context:
space:
mode:
authorJack Lucas <jflucas@research.att.com>2018-04-06 20:46:11 +0000
committerJack Lucas <jflucas@research.att.com>2018-04-06 20:46:46 +0000
commit43160301f2142d597ab7e820e53bb699f86a9b05 (patch)
treef54b5c17fa5a236ac0887f45979b7db8ec0becdb /cm-container/get-type-files.sh
parent1748ff0081f14803b7a486d80007e7cd36872853 (diff)
Update list of type files
Change-Id: I059269176399071db8f2a11f00b16d687d18525b Issue-ID: DCAEGEN2-416 Signed-off-by: Jack Lucas <jflucas@research.att.com>
Diffstat (limited to 'cm-container/get-type-files.sh')
-rwxr-xr-xcm-container/get-type-files.sh36
1 files changed, 29 insertions, 7 deletions
diff --git a/cm-container/get-type-files.sh b/cm-container/get-type-files.sh
index 038e8e0..414c8e1 100755
--- a/cm-container/get-type-files.sh
+++ b/cm-container/get-type-files.sh
@@ -21,27 +21,49 @@
# Pull type files from repos
# Set up the CM import resolver
-# $1 is the repo URL
+# $1 is the DCAE repo URL
+# $2 is the CCSDK repo URL
#
set -x
DEST=/opt/manager/resources/onapspec
-ONAPTYPEFILES=\
+
+DCAETYPEFILES=\
"\
-/dcaepolicyplugin/2.0.0/dcaepolicyplugin_types.yaml \
+/dcaepolicyplugin/2.2.1/dcaepolicyplugin_types.yaml \
/relationshipplugin/1.0.0/relationshipplugin_types.yaml \
-/k8splugin/1.0.0/k8splugin_types.yaml \
+/k8splugin/1.0.1/k8splugin_types.yaml \
"
+
+CCSDKTYPEFILES=\
+"\
+/type_files/pgaas/1.1.0/pgaas_types.yaml \
+/type_files/sshkeyshare/sshkey_types.yaml \
+
+"
+
mkdir ${DEST}
-for typefile in ${ONAPTYPEFILES}
+
+for typefile in ${DCAETYPEFILES}
do
mkdir -p ${DEST}/$(dirname ${typefile})
curl -Ss $1/${typefile} >> ${DEST}/${typefile}
done
+
+for typefile in ${CCSDKTYPEFILES}
+do
+ mkdir -p ${DEST}/$(dirname ${typefile})
+ curl -Ss $2/${typefile} >> ${DEST}/${typefile}
+done
+
chown cfyuser:cfyuser ${DEST}
+
# Add our local type file store to CM import resolver configuration
-TYPE_RULE="{${TYPE_REPO}: file://${DEST}}"
+TYPE_RULE0="{$1: file://${DEST}}"
+TYPE_RULE1="{$2: file://${DEST}}"
# This sed re is 'brittle' but we can be sure the config.yaml file
# won't change as long as we do not change the source Docker image for CM
-sed -i -e "s# rules:# rules:\n - ${TYPE_RULE}#" /etc/cloudify/config.yaml
+sed -i -e "s# rules:# rules:\n - ${TYPE_RULE0}#" /etc/cloudify/config.yaml
+sed -i -e "s# rules:# rules:\n - ${TYPE_RULE1}#" /etc/cloudify/config.yaml
+
chown cfyuser:cfyuser /etc/cloudify/config.yaml