[ -z "${DEBUG_INSTALL}" ] || DEBUG end of function
}
-function pull_docker_images() {
- [ -z "${DEBUG_INSTALL}" ] || DEBUG beginning of function
- echo "Pulling docker images"
- [ -n "${DOCKER_REGISTRY_URL}" ] && docker_login
-
- echo "Pulling non-OSM docker images"
- sg docker -c "docker pull wurstmeister/zookeeper" || FATAL "cannot get zookeeper docker image"
- sg docker -c "docker pull wurstmeister/kafka:${KAFKA_TAG}" || FATAL "cannot get kafka docker image"
- sg docker -c "docker pull prom/prometheus:${PROMETHEUS_TAG}" || FATAL "cannot get prometheus docker image"
- sg docker -c "docker pull google/cadvisor:${PROMETHEUS_CADVISOR_TAG}" || FATAL "cannot get prometheus cadvisor docker image"
- sg docker -c "docker pull grafana/grafana:${GRAFANA_TAG}" || FATAL "cannot get grafana docker image"
- sg docker -c "docker pull kiwigrid/k8s-sidecar:${KIWIGRID_K8S_SIDECAR_TAG}" || FATAL "cannot get kiwigrid k8s-sidecar docker image"
- sg docker -c "docker pull mariadb:${KEYSTONEDB_TAG}" || FATAL "cannot get keystone-db docker image"
- sg docker -c "docker pull mysql:5" || FATAL "cannot get mysql docker image"
-
- list_of_modules="MON NBI KEYSTONE RO LCM NG-UI osmclient prometheus"
- if [ -n "$INSTALL_NGSA" ]; then
- list_of_modules="${list_of_modules} Airflow Webhook"
- else
- list_of_modules="${list_of_modules} POL"
- fi
- if [ -n "$INSTALL_PLA" ]; then
- list_of_modules="${list_of_modules} PLA"
- fi
- echo "Pulling OSM docker images for the following modules: ${list_of_modules}"
- for module in ${list_of_modules}; do
- module_lower=${module,,}
- module_tag="${OSM_DOCKER_TAG}"
- if [ -n "${MODULE_DOCKER_TAG}" ] && echo $TO_REBUILD | grep -q $module ; then
- module_tag="${MODULE_DOCKER_TAG}"
- fi
- echo "Pulling ${DOCKER_REGISTRY_URL}${DOCKER_USER}/${module_lower}:${module_tag} docker image"
- sg docker -c "docker pull ${DOCKER_REGISTRY_URL}${DOCKER_USER}/${module_lower}:${module_tag}" || FATAL "cannot pull $module docker image"
- done
-
- echo "Finished pulling docker images"
- [ -z "${DEBUG_INSTALL}" ] || DEBUG end of function
-}
-
function generate_docker_images() {
[ -z "${DEBUG_INSTALL}" ] || DEBUG beginning of function
echo "Generating docker images"
track juju juju_ok
# Deploy OSM services
- [ -z "$DOCKER_NOBUILD" ] && pull_docker_images
[ -z "$DOCKER_NOBUILD" ] && [ -z "$PULL_IMAGES" ] && generate_docker_images
track docker_images docker_images_ok