@@ -24,9 +24,8 @@ REPO_CREDS_SECRET_NAME="autopilot-secret"
24
24
ARGOCD_TOKEN_SECRET_NAME=" argocd-token"
25
25
ARGOCD_INITIAL_TOKEN_SECRET_NAME=" argocd-initial-admin-secret"
26
26
BOOTSTRAP_APP_NAME=" csdp-bootstrap"
27
- ADDITIONAL_COMPONENTS_MANAGED=" \nevents-reporter"
28
- ADDITIONAL_COMPONENTS=" \nevents-reporter\nrollout-reporter\nworkflow-reporter"
29
- RUNTIME_DEF_URL=" https://github.com/codefresh-io/csdp-official-poc/releases/VERSION/download/runtime.yaml"
27
+ COMPONENTS_MANAGED=" argo-events,app-proxy,argo-cd,events-reporter"
28
+ COMPONENTS=" argo-events,app-proxy,argo-cd,events-reporter,rollout-reporter,workflow-reporter"
30
29
31
30
# Params:
32
31
check_required_param " namespace" " ${NAMESPACE} "
@@ -48,30 +47,18 @@ CSDP_RUNTIME_REPO_CREDS_PATTERN=`echo ${CSDP_RUNTIME_REPO} | grep --color=never
48
47
CSDP_MANAGED_RUNTIME=" ${CSDP_MANAGED_RUNTIME:- false} "
49
48
50
49
create_codefresh_secret () {
51
- # Download runtime definition
52
- RUNTIME_DEF_URL=` echo " ${RUNTIME_DEF_URL} " | sed s/VERSION/${CSDP_RUNTIME_VERSION} /g`
53
-
54
- echo " --> Downloading runtime definition..."
55
- echo " --> curl -f -L ${RUNTIME_DEF_URL} "
56
- RUNTIME_DEF=$( curl -SsfL " $RUNTIME_DEF_URL " )
57
- RESOLVED_RUNTIME_VERSION=` echo " $RUNTIME_DEF " | yq e ' .spec.version' -`
58
- echo " --> Resolved runtime version: ${RESOLVED_RUNTIME_VERSION} "
59
- echo " "
60
-
61
- # Prepare components for request
62
-
63
50
if [[ " $CSDP_MANAGED_RUNTIME " == " true" ]] ; then
64
- ADDITIONAL_COMPONENTS= ${ADDITIONAL_COMPONENTS_MANAGED}
51
+ COMPONENTS= $COMPONENTS_MANAGED
65
52
fi
66
- COMPONENT_NAMES=` echo " $RUNTIME_DEF " | yq e ' .spec.components.[].name' -`
67
- COMPONENT_NAMES=` printf " ${COMPONENT_NAMES}${ADDITIONAL_COMPONENTS} " | tr ' \n' ' ' `
68
- COMPONENTS=" [\" csdp-argo-cd\" "
53
+ COMPONENT_NAMES=` echo ${COMPONENTS} | tr ' ,' ' ' `
54
+ COMPONENTS=" "
69
55
for COMPONENT in $COMPONENT_NAMES
70
56
do
71
57
CUR_COMPONENT=` echo -n " \" csdp-${COMPONENT} \" " `
72
- COMPONENTS=" ${COMPONENTS} , ${CUR_COMPONENT }"
58
+ COMPONENTS=" ${CUR_COMPONENT} ${COMPONENTS }"
73
59
done
74
- COMPONENTS=" ${COMPONENTS} ]"
60
+ COMPONENTS=` echo $COMPONENTS | tr ' ' ' ,' `
61
+ COMPONENTS=" [${COMPONENTS} ]"
75
62
76
63
RUNTIME_CREATE_ARGS=" {
77
64
\" repo\" : \" ${CSDP_RUNTIME_REPO} \" ,
@@ -81,7 +68,7 @@ create_codefresh_secret() {
81
68
\" ingressClass\" :\" ${CSDP_INGRESS_CLASS_NAME} \" ,
82
69
\" ingressController\" :\" ${CSDP_INGRESS_CONTROLLER} \" ,
83
70
\" componentNames\" :${COMPONENTS} ,
84
- \" runtimeVersion\" :\" ${RESOLVED_RUNTIME_VERSION} \"
71
+ \" runtimeVersion\" :\" 0.0 \"
85
72
}"
86
73
87
74
RUNTIME_CREATE_DATA=" {\" operationName\" :\" CreateRuntime\" ,\" variables\" :{\" args\" :$RUNTIME_CREATE_ARGS }"
0 commit comments