Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
Partition
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OSDU
OSDU Data Platform
System
Partition
Commits
e8440126
Commit
e8440126
authored
2 years ago
by
Manish Singh
Committed by
Shrikant Garg
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Release ibm helm 17 : Helm Chart Resource Changed
parent
e3cd5784
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!319
Release ibm helm 17 : Helm Chart Resource Changed
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
devops/ibm/ibm-partition-deploy/files/configMap_update_script.sh
+20
-16
20 additions, 16 deletions
...ibm/ibm-partition-deploy/files/configMap_update_script.sh
with
20 additions
and
16 deletions
devops/ibm/ibm-partition-deploy/files/configMap_update_script.sh
+
20
−
16
View file @
e8440126
...
...
@@ -6,29 +6,33 @@ export HOME=/tmp/cm-config
cd
/tmp/cm-config
COUCH_SECRET_NAME
=
$(
oc
get secrets |grep Opaque|
grep
couchdb|
awk
'{ print $1 }'
)
COUCH_SECRET_NAME
=
$(
kubectl
get secrets |grep Opaque|
grep
couchdb|
awk
'{ print $1 }'
)
VALUE_COUCH_SECRET
=
$(
oc
get secret
$COUCH_SECRET_NAME
-o
jsonpath
=
"{ .data.adminPassword}"
|base64
-d
)
VALUE_COUCH_SECRET
=
$(
kubectl
get secret
$COUCH_SECRET_NAME
-o
jsonpath
=
"{ .data.adminPassword}"
|base64
-d
)
oc
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
ibm.db.password
\"
:
\"
$VALUE_COUCH_SECRET
\"
}}"
kubectl
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
ibm.db.password
\"
:
\"
$VALUE_COUCH_SECRET
\"
}}"
KEYCLOAK_LB_IP
=
$(
oc
get svc keycloak-discovery-lb
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].ip}"
)
KEYCLOAK_LB_IP
=
$(
kubectl
get svc keycloak-discovery-lb
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].ip}"
)
KEYCLOAK_HOSTNAME
=
$(
oc
get svc keycloak-discovery-lb
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].hostname}"
)
KEYCLOAK_HOSTNAME
=
$(
kubectl
get svc keycloak-discovery-lb
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].hostname}"
)
KEYCLOAK_LB_IP
=
${
KEYCLOAK_LB_IP
:
=
$KEYCLOAK_HOSTNAME
}
oc
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
keycloak.auth-server-url
\"
:
\"
http://
$KEYCLOAK_LB_IP
/auth
\"
}}"
kubectl
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
keycloak.auth-server-url
\"
:
\"
http://
$KEYCLOAK_LB_IP
/auth
\"
}}"
oc
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
ibm.keycloak.endpoint_url
\"
:
\"
http://
$KEYCLOAK_LB_IP
\"
}}"
kubectl
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
ibm.keycloak.endpoint_url
\"
:
\"
http://
$KEYCLOAK_LB_IP
\"
}}"
oc
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
partition.keycloak.url
\"
:
\"
$KEYCLOAK_LB_IP
\"
}}"
kubectl
patch cm partition-config
-p
"{
\"
data
\"
: {
\"
partition.keycloak.url
\"
:
\"
$KEYCLOAK_LB_IP
\"
}}"
MINIO_
LB_IP
=
$(
kubectl get svc
osdu-deploy-minio
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].ip}"
)
MINIO_
SVC
=
$(
kubectl get svc
|
grep
minio |
awk
{
'print $1'
}
)
MINIO_LB_HOSTNAME
=
$(
kubectl get svc osdu-deploy-m
in
i
o
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].hostname}"
)
echo
"M
in
I
o
Service is :
$MINIO_SVC
"
MINIO_LB_PORT
=
$(
kubectl get svc osdu-deploy-minio
-o
=
jsonpath
=
"{.spec.ports[?(@.name=='minio-api')].port}"
)
MINIO_LB_IP
=
$(
kubectl get svc
$MINIO_SVC
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].ip}"
)
MINIO_LB_HOSTNAME
=
$(
kubectl get svc
$MINIO_SVC
-o
jsonpath
=
"{ .status.loadBalancer.ingress[0].hostname}"
)
MINIO_LB_PORT
=
$(
kubectl get svc
$MINIO_SVC
-o
=
jsonpath
=
"{.spec.ports[?(@.name=='minio-api')].port}"
)
MINIO_LB_PORT
=
${
MINIO_LB_PORT
:
=9000
}
...
...
@@ -36,7 +40,7 @@ MINIO_LB_IP=${MINIO_LB_IP:=$MINIO_LB_HOSTNAME}
kubectl patch cm partition-config
-p
"{
\"
data
\"
: {
\"
ibm.cos.endpoint_url
\"
:
\"
http://
$MINIO_LB_IP
:
$MINIO_LB_PORT
\"
}}"
oc
patch RequestAuthentication core-request-authn
--type
json
-p
=
'[{"op": "replace", "path": "/spec/jwtRules/0/issuer", "value":"http://'
$KEYCLOAK_LB_IP
'/auth/realms/OSDU"}]'
kubectl
patch RequestAuthentication core-request-authn
--type
json
-p
=
'[{"op": "replace", "path": "/spec/jwtRules/0/issuer", "value":"http://'
$KEYCLOAK_LB_IP
'/auth/realms/OSDU"}]'
echo
"Waiting for Keycloak Server to come up"
...
...
@@ -46,10 +50,10 @@ sleep 10
KEYCLOAK_CERT
=
$(
curl http://keycloak-discovery:8080/auth/realms/OSDU/protocol/openid-connect/certs
)
oc
get RequestAuthentication core-request-authn
-o
yaml |
sed
"s|jwksUri: *.*|jwks: ''|g"
|
oc
apply
-f
-
kubectl
get RequestAuthentication core-request-authn
-o
yaml |
sed
"s|jwksUri: *.*|jwks: ''|g"
|
kubectl
apply
-f
-
oc
get RequestAuthentication core-request-authn
-o
yaml |
sed
"s|jwks: *.*|jwks: '
$KEYCLOAK_CERT
'|g"
|
oc
apply
-f
-
kubectl
get RequestAuthentication core-request-authn
-o
yaml |
sed
"s|jwks: *.*|jwks: '
$KEYCLOAK_CERT
'|g"
|
kubectl
apply
-f
-
oc
get EnvoyFilter header-2-add-user-from-keycloak-token
-o
yaml |
sed
"s/x.x.x.x/
$KEYCLOAK_LB_IP
/g"
|
oc
apply
-f
-
kubectl
get EnvoyFilter header-2-add-user-from-keycloak-token
-o
yaml |
sed
"s/x.x.x.x/
$KEYCLOAK_LB_IP
/g"
|
kubectl
apply
-f
-
oc
wait
--for
=
condition
=
complete
--timeout
=
120s job/amq-pvc-permissions |
oc
get ActiveMQArtemis ex-aao
-o
yaml |
sed
"s/size: 0/size: 1/g"
|
oc
apply
-f
-
kubectl
wait
--for
=
condition
=
complete
--timeout
=
120s job/amq-pvc-permissions |
kubectl
get ActiveMQArtemis ex-aao
-o
yaml |
sed
"s/size: 0/size: 1/g"
|
kubectl
apply
-f
-
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment