2 # ============LICENSE_START=======================================================
4 # ================================================================================
5 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
6 # ================================================================================
7 # Licensed under the Apache License, Version 2.0 (the "License");
8 # you may not use this file except in compliance with the License.
9 # You may obtain a copy of the License at
11 # http://www.apache.org/licenses/LICENSE-2.0
13 # Unless required by applicable law or agreed to in writing, software
14 # distributed under the License is distributed on an "AS IS" BASIS,
15 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 # See the License for the specific language governing permissions and
17 # limitations under the License.
18 # ============LICENSE_END=========================================================
20 # ECOMP is a trademark and service mark of AT&T Intellectual Property.
22 # Pull plugin archives from repos
24 # $1 is the DCAE repo URL
25 # $2 is the CCSDK repo URL
26 # (This script runs at Docker image build time)
31 # For DCAE, we get zips of the archives and build wagons
34 k8splugin/1.4.3/k8splugin-1.4.3.tgz
35 relationshipplugin/1.0.0/relationshipplugin-1.0.0.tgz
36 dcaepolicyplugin/2.3.0/dcaepolicyplugin-2.3.0.tgz
37 dockerplugin/3.2.0/dockerplugin-3.2.0.tgz \
40 # For CCSDK, we pull down the wagon files directly
43 plugins/pgaas-1.1.0-py27-none-any.wgn
44 plugins/sshkeyshare-1.0.0-py27-none-any.wgn
47 # Build a set of wagon files from archives in a repo
49 # $2 -- list of paths to archive files in the repo
53 # Could just do wagon create with the archive URL as source,
54 # but can't use a requirements file with that approach
56 target=$(basename ${plugin})
57 curl -Ss $1/${plugin} > ${target}
58 tar zxvf ${target} --strip-components=2 -C work
59 wagon create -t tar.gz -o ${DEST} -r work/requirements.txt --validate ./work
64 # Copy a set of wagons from a repo
66 # $2 -- list of paths to wagons in the repo
70 target=$(basename ${wagon})
71 curl -Ss $1/${wagon} > ${DEST}/${target}
76 build $1 "${DCAEPLUGINFILES}"
77 get_wagons $2 "${CCSDKPLUGINFILES}"