# k8s public ip. NONE will indicate no local register service DNS resolution to reach CCF, empty value will try to get ip of ingress-nginx-controller NodePort
# and any other vaule will set resolution to K8S_IP set for CAPIF_HOSTNAME.
export K8S_IP=""
# Directories variables setup (no modification needed)
export SCRIPTS_DIR=$(dirname"$(readlink-f"$0")")
@@ -29,7 +30,7 @@ echo "The base directory is: $CAPIF_BASE_DIR"
# Vault installation variables
## Vault configuration
export VAULT_HOSTNAME=vault.testbed.int
export VAULT_HOSTNAME=vault.testbed.develop
export VAULT_NAMESPACE=ocf-vault
export VAULT_SERVICE_NAME='vault'
export LABEL_TO_CHECK="app.kubernetes.io/name"
@@ -47,14 +48,14 @@ VAULT_JOB_NAME=vault-pki
# Monitoring installation variables
## Prometheus Hostname to be used at ingress configuration
### this configuration is used to add this script to ocf-mon-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN mongo-express-register-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN mongo-express-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN
export CAPIF_CI_ENV_ENDPOINT=capif
### Domain to ve used in grafana, mock-server and both mongo express instances.
export CAPIF_DOMAIN=uma.internal
export CAPIF_DOMAIN=testbed.develop
## Configuration of images to be used on deplyment
### Docker Registry to download images (must be accesible by k8s cluster)
echo"Using value on VAULT_ACCESS_TOKEN=$VAULT_ACCESS_TOKEN"
### If K8S_IP is empty, then script will try to get ingress-nginx-controller NodePort to grant DNS resolution for register to connect locally to CAPIF nginx
if["$K8S_IP"=="NONE"];then
echo"K8S_IP value is NONE. Register service will not have local DNS resolution"
elif[-z"$K8S_IP"];then
K8S_IP=$(kubectl $KUBECONFIG get svc -A | grep ingress-nginx-controller | awk'/NodePort/{ print $4 }')