-
Notifications
You must be signed in to change notification settings - Fork 2
/
up
executable file
·67 lines (61 loc) · 2.56 KB
/
up
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#!/bin/bash
netcicd_pwd="netcicd01"
sp="/-\|"
sc=0
spin() {
printf -- "${sp:sc++:1} ( ${t} sec.) \r"
((sc==${#sp})) && sc=0
sleep 1
let t+=1
}
endspin() {
printf "\r%s\n" "$@"
}
docker-compose start consul.internal.provider.test vault.internal.provider.test
echo "Waiting for Vault to come online"
until $(curl --output /dev/null --silent --head --fail http://vault.internal.provider.test:8200); do
printf '.'
sleep 5
done
echo " "
unseal_key=`cat ./vault/key.txt`
robot --variable key:${unseal_key} -d install_log ./vault/unseal.robot
docker-compose start cicdtoolbox-db.internal.provider.test keycloak.services.provider.test
echo "Waiting for Keycloak to come online"
until $(curl --output /dev/null --silent --head --fail http://keycloak.services.provider.test:8080); do
printf '.'
sleep 5
done
echo " "
# echo "****************************************************************************************************************"
# echo " Creating Grafana Keycloak Client secret"
# echo "****************************************************************************************************************"
# export Grafana_CLIENT_SECRET=$(grep Grafana_token install_log/keycloak_create.log | cut -d' ' -f2 | tr -d '\r')
# echo $Grafana_CLIENT_SECRET
docker-compose start
echo "****************************************************************************************************************"
echo " Waiting for the containers to come up"
echo "****************************************************************************************************************"
echo " Gitea"
let t=0
until $(curl --output /dev/null --silent --head --insecure --fail https://gitea.tooling.provider.test:3000); do
spin
done
endspin
echo "Nexus"
let t=0
until $(curl --output /dev/null --insecure --silent --head --fail https://nexus.tooling.provider.test:8443); do
spin
done
endspin
echo "Jenkins"
let t=0
until $(curl --output /dev/null --insecure --silent --head --fail https://jenkins.tooling.provider.test:8084/whoAmI); do
spin
done
endspin
echo "****************************************************************************************************************"
echo " Validating install"
echo "****************************************************************************************************************"
robot --variable VALID_PASSWORD:${netcicd_pwd} -d install_tests/ install_tests
robot --variable VALID_PASSWORD:${netcicd_pwd} -d install_tests/ -o ./install_log/runner.xml -l ./install_log/runner_log.html -r ./install_log/runner_report.html ./jenkins_buildnode/runner_validate.robot