A cluster lifecycle orchestrator for Airship.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

41 lines
2.1 KiB

#!/bin/bash
# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTE: If a user is executing deploy_site, update_site, update_software or
# redeploy_server workflow from outside the cluster, e.g. from a remote jump
# server, then the user will need to ensure that the DNS server is able to
# resolve the FQDN of the Shipyard and Keystone public URL (both will be
# pointing to the IP of the Ingress Controller). If the DNS resolution is not
# available, the user will need to ensure that the /etc/hosts file is properly
# updated before setting up the environment variables and running the worflow.
# Define Variable
namespace="${namespace:-ucp}"
# Export Environment Variables
# Note that 'shipyard_query_time' has a default value of 90 seconds
# Note that 'max_shipyard_count' has a default value of 60 loops (based on
# 90 seconds back off per cycle, i.e. 60 * 90 = 5400 seconds = 1.5 hr)
# Note that user can use a different value for each of the variables by
# exporting the required environment variable prior to running the script
export max_shipyard_count=${max_shipyard_count:-60}
export shipyard_query_time=${shipyard_query_time:-90}
export OS_AUTH_URL="${OS_AUTH_URL:-http://keystone.${namespace}.svc.cluster.local:80/v3}"
OS_SHIPYARD_PASSWORD=${OS_SHIPYARD_PASSWORD:-${OS_PASSWORD}}
export OS_PASSWORD=${OS_SHIPYARD_PASSWORD:-password}
export OS_PROJECT_DOMAIN_NAME="${OS_PROJECT_DOMAIN_NAME:-default}"
export OS_PROJECT_NAME="${OS_PROJECT_NAME:-service}"
export OS_USERNAME="${OS_USERNAME:-shipyard}"
export OS_USER_DOMAIN_NAME="${OS_USER_DOMAIN_NAME:-default}"