Skip to content

Commit 85ab8e6

Browse files
onprem: 3.0
1 parent 51abe24 commit 85ab8e6

28 files changed

+2167
-1571
lines changed

charts/codefresh-gitops/files/hooks/mongoSetCompatibilityVersion.sh

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ waitForMongoDB() {
1616
done
1717
}
1818

19+
getMongoDBVersion() {
20+
local version=$(mongosh ${MONGODB_ROOT_URI} --eval "db.version()" 2>&1)
21+
echo $version
22+
}
23+
1924
parseMongoURI() {
2025
local proto="$(echo $1 | grep :// | sed -e's,^\(.*://\).*,\1,g')"
2126
local parameters="$(echo $1 | grep '?' | cut -d '?' -f2)"; if [[ -n $parameters ]]; then parameters="?${parameters}"; fi
@@ -33,4 +38,10 @@ parseMongoURI $MONGO_URI
3338

3439
waitForMongoDB
3540

36-
mongosh ${MONGODB_ROOT_URI} --eval "db.adminCommand( { setFeatureCompatibilityVersion: \"$MONGODB_COMPAT_VERSION\" } )"
41+
MONGO_VERSION=$(getMongoDBVersion)
42+
43+
if [[ $MONGO_VERSION == 7* ]]; then
44+
mongosh ${MONGODB_ROOT_URI} --eval "db.adminCommand( { setFeatureCompatibilityVersion: \"$MONGODB_COMPAT_VERSION\", confirm: true } )"
45+
else
46+
mongosh ${MONGODB_ROOT_URI} --eval "db.adminCommand( { setFeatureCompatibilityVersion: \"$MONGODB_COMPAT_VERSION\" } )"
47+
fi

charts/codefresh-gitops/files/seed/postgresSeedJobScript.sh

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
#!/bin/bash
22

3-
set -xeuo pipefail
3+
DEBUG="${DEBUG:-false}"
4+
5+
6+
set -euo pipefail
7+
8+
if [[ $DEBUG == "true" ]]; then
9+
set -xeuo pipefail
10+
echo "Running in debug mode"
11+
fi
412

513
POSTGRES_DATABASES=(
614
"codefresh"
@@ -20,7 +28,9 @@ POSTGRES_SEED_USER="${POSTGRES_SEED_USER:-$POSTGRES_USER}"
2028
POSTGRES_SEED_PASSWORD="${POSTGRES_SEED_PASSWORD:-$POSTGRES_PASSWORD}"
2129

2230
function createDB() {
23-
psql -tc "SELECT 1 FROM pg_database WHERE datname = '${1}'" | grep -q 1 || psql -c "CREATE DATABASE ${1}"
31+
local db=$1
32+
echo "Creating ${db} database"
33+
psql -c "CREATE DATABASE ${db}" 2>&1 || true
2434
}
2535

2636
function createUser() {
@@ -29,7 +39,9 @@ function createUser() {
2939
}
3040

3141
function grantPrivileges() {
32-
psql -c "GRANT ALL ON DATABASE ${1} TO ${POSTGRES_USER}"
42+
local db=$1
43+
echo "Granting privileges on $db to ${POSTGRES_USER}"
44+
psql -c "GRANT ALL ON DATABASE ${db} TO ${POSTGRES_USER}"
3345
}
3446

3547
function runSeed() {
@@ -38,6 +50,7 @@ function runSeed() {
3850
export PGPASSWORD=${POSTGRES_SEED_PASSWORD}
3951
export PGHOST=${POSTGRES_HOSTNAME}
4052
export PGPORT=${POSTGRES_PORT}
53+
export PGDATABASE=postgres # Use the default postgres database
4154

4255
if [[ "${POSTGRES_SEED_USER}" != "${POSTGRES_USER}" ]]; then
4356
createUser
@@ -51,4 +64,4 @@ function runSeed() {
5164
done
5265
}
5366

54-
runSeed
67+
runSeed

charts/codefresh/.ci/values/defaults-hpa.yaml renamed to charts/codefresh/.ci/values/defaults.yaml

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ cfapi:
2222

2323
ingress:
2424
enabled: true
25-
ingressClassName: nginx-internal
25+
ingressClassName: nginx
2626
tls:
2727
enabled: false
2828

@@ -75,3 +75,28 @@ argo-platform:
7575
promotion-orchestrator:
7676
hpa:
7777
enabled: true
78+
79+
mongodb:
80+
migration:
81+
enabled: true
82+
image:
83+
repository: bitnamilegacy/mongodb
84+
nodeSelector:
85+
kubernetes.io/arch: amd64
86+
87+
consul:
88+
image:
89+
repository: bitnamilegacy/consul
90+
91+
nats:
92+
image:
93+
repository: bitnamilegacy/nats
94+
95+
rabbitmq:
96+
image:
97+
repository: bitnamilegacy/rabbitmq
98+
99+
hooks:
100+
mongodb:
101+
nodeSelector:
102+
kubernetes.io/arch: amd64

charts/codefresh/.ci/values/mtls-mongodb-redis.yaml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
seed:
22
mongoSeedJob:
33
mongodbRootURI: mongodb://root:XT9nmM8dZDZ@cf-mongodb:27017/?authSource=admin
4+
mongodbRootOptions: authSource=admin
5+
mongodbRootPassword: XT9nmM8dZDZ
46

57
global:
68
appUrl: "" # placeholder for ${CF_APP_HOST}
@@ -86,9 +88,9 @@ mongodb:
8688
mongosh ${MONGODB_ROOT_URI} --eval "db.getSiblingDB('${MONGODB_DATABASE}').createCollection('test')"
8789
done
8890
89-
mongoimport --uri ${MONGODB_ROOT_URI} --db codefresh --collection idps --type json --legacy --file /usr/share/extras/idps.json
90-
mongoimport --uri ${MONGODB_ROOT_URI} --db codefresh --collection accounts --type json --legacy --file /usr/share/extras/accounts.json
91-
mongoimport --uri ${MONGODB_ROOT_URI} --db codefresh --collection users --type json --legacy --file /usr/share/extras/users.json
91+
# mongoimport --uri ${MONGODB_ROOT_URI} --db codefresh --collection idps --type json --legacy --file /usr/share/extras/idps.json
92+
# mongoimport --uri ${MONGODB_ROOT_URI} --db codefresh --collection accounts --type json --legacy --file /usr/share/extras/accounts.json
93+
# mongoimport --uri ${MONGODB_ROOT_URI} --db codefresh --collection users --type json --legacy --file /usr/share/extras/users.json
9294

9395
extraVolumeMounts:
9496
- name: extras

charts/codefresh/Chart.lock

Lines changed: 48 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ dependencies:
44
version: 0.18.1
55
- name: internal-gateway
66
repository: oci://quay.io/codefresh/charts
7-
version: 0.10.2
7+
version: 0.11.0
88
- name: consul
99
repository: https://charts.bitnami.com/bitnami
10-
version: 11.4.17
10+
version: 11.4.32
1111
- name: mongodb
1212
repository: https://charts.bitnami.com/bitnami
1313
version: 15.6.26
1414
- name: postgresql
1515
repository: https://charts.bitnami.com/bitnami
16-
version: 16.7.4
16+
version: 16.7.15
1717
- name: postgresql-ha
1818
repository: oci://quay.io/codefresh/charts
1919
version: 12.0.4
@@ -28,7 +28,7 @@ dependencies:
2828
version: 15.5.3
2929
- name: nats
3030
repository: https://charts.bitnami.com/bitnami
31-
version: 9.0.17
31+
version: 9.0.22
3232
- name: builder
3333
repository: oci://quay.io/codefresh/charts
3434
version: 1.4.0
@@ -37,135 +37,135 @@ dependencies:
3737
version: 1.4.0
3838
- name: ingress-nginx
3939
repository: https://kubernetes.github.io/ingress-nginx
40-
version: 4.12.1
40+
version: 4.12.5
4141
- name: cluster-providers
4242
repository: oci://quay.io/codefresh/charts
43-
version: 1.17.15
43+
version: 1.18.0
4444
- name: kube-integration
4545
repository: oci://quay.io/codefresh/charts
46-
version: 1.31.19
46+
version: 1.32.0
4747
- name: charts-manager
4848
repository: oci://quay.io/codefresh/charts
49-
version: 1.23.1
49+
version: 1.23.4
5050
- name: cfsign
5151
repository: oci://quay.io/codefresh/charts
52-
version: 1.8.8
52+
version: 1.8.10
5353
- name: tasker-kubernetes
5454
repository: oci://quay.io/codefresh/charts
55-
version: 1.26.18
55+
version: 1.27.0
5656
- name: context-manager
5757
repository: oci://quay.io/codefresh/charts
58-
version: 2.34.2
58+
version: 2.34.5
5959
- name: pipeline-manager
6060
repository: oci://quay.io/codefresh/charts
61-
version: 3.139.2
61+
version: 3.139.5
6262
- name: gitops-dashboard-manager
6363
repository: oci://quay.io/codefresh/charts
64-
version: 1.14.22
64+
version: 1.15.0
6565
- name: cfapi
6666
repository: oci://quay.io/codefresh/charts
67-
version: 21.279.2
67+
version: 21.279.8
6868
- name: cfapi
6969
repository: oci://quay.io/codefresh/charts
70-
version: 21.279.2
70+
version: 21.279.8
7171
- name: cfapi
7272
repository: oci://quay.io/codefresh/charts
73-
version: 21.279.2
73+
version: 21.279.8
7474
- name: cfapi
7575
repository: oci://quay.io/codefresh/charts
76-
version: 21.279.2
76+
version: 21.279.8
7777
- name: cfapi
7878
repository: oci://quay.io/codefresh/charts
79-
version: 21.279.2
79+
version: 21.279.8
8080
- name: cfapi
8181
repository: oci://quay.io/codefresh/charts
82-
version: 21.279.2
82+
version: 21.279.8
8383
- name: cfapi
8484
repository: oci://quay.io/codefresh/charts
85-
version: 21.279.2
85+
version: 21.279.8
8686
- name: cfapi
8787
repository: oci://quay.io/codefresh/charts
88-
version: 21.279.2
88+
version: 21.279.8
8989
- name: cfapi
9090
repository: oci://quay.io/codefresh/charts
91-
version: 21.279.2
91+
version: 21.279.8
9292
- name: cfapi
9393
repository: oci://quay.io/codefresh/charts
94-
version: 21.279.2
94+
version: 21.279.8
9595
- name: cfapi
9696
repository: oci://quay.io/codefresh/charts
97-
version: 21.279.2
97+
version: 21.279.8
9898
- name: cfapi
9999
repository: oci://quay.io/codefresh/charts
100-
version: 21.279.2
100+
version: 21.279.8
101101
- name: cfapi
102102
repository: oci://quay.io/codefresh/charts
103-
version: 21.279.2
103+
version: 21.279.8
104104
- name: cfapi
105105
repository: oci://quay.io/codefresh/charts
106-
version: 21.279.2
106+
version: 21.279.8
107107
- name: cfapi
108108
repository: oci://quay.io/codefresh/charts
109-
version: 21.279.2
109+
version: 21.279.8
110110
- name: cfapi
111111
repository: oci://quay.io/codefresh/charts
112-
version: 21.279.2
112+
version: 21.279.8
113113
- name: cfapi
114114
repository: oci://quay.io/codefresh/charts
115-
version: 21.279.2
115+
version: 21.279.8
116116
- name: cfapi
117117
repository: oci://quay.io/codefresh/charts
118-
version: 21.279.2
118+
version: 21.279.8
119119
- name: cfui
120120
repository: oci://quay.io/codefresh/charts
121-
version: 14.98.27
121+
version: 14.98.29
122122
- name: k8s-monitor
123123
repository: oci://quay.io/codefresh/charts
124-
version: 4.11.14
124+
version: 4.11.16
125125
- name: runtime-environment-manager
126126
repository: oci://quay.io/codefresh/charts
127-
version: 3.41.1
127+
version: 3.41.5
128128
- name: cf-broadcaster
129129
repository: oci://quay.io/codefresh/charts
130-
version: 1.13.0
130+
version: 1.14.0
131131
- name: helm-repo-manager
132132
repository: oci://quay.io/codefresh/charts
133133
version: 0.20.2
134134
- name: hermes
135135
repository: oci://quay.io/codefresh/charts
136-
version: 0.21.18
136+
version: 0.21.20
137137
- name: nomios
138138
repository: oci://quay.io/codefresh/charts
139-
version: 0.11.10
139+
version: 0.11.11
140140
- name: cronus
141141
repository: oci://quay.io/codefresh/charts
142-
version: 0.8.10
142+
version: 0.8.12
143143
- name: cf-platform-analytics
144144
repository: oci://quay.io/codefresh/charts
145-
version: 0.49.87
145+
version: 0.51.0
146146
- name: cf-platform-analytics
147147
repository: oci://quay.io/codefresh/charts
148-
version: 0.49.87
148+
version: 0.51.0
149149
- name: argo-platform
150150
repository: oci://quay.io/codefresh/charts
151-
version: 1.3506.0
151+
version: 1.3525.3-onprem-24aeab4
152152
- name: argo-hub-platform
153153
repository: oci://quay.io/codefresh/charts
154-
version: 0.1.23
154+
version: 0.1.27
155155
- name: cf-oidc-provider
156156
repository: oci://quay.io/codefresh/charts
157-
version: 0.0.16
157+
version: 0.1.0
158158
- name: mailer
159159
repository: oci://quay.io/codefresh/charts
160-
version: 1.20.8
160+
version: 1.21.0
161161
- name: payments
162162
repository: oci://quay.io/codefresh/charts
163-
version: 2.23.18
163+
version: 2.24.1
164164
- name: segment-reporter
165165
repository: oci://quay.io/codefresh/charts
166-
version: 1.17.8
166+
version: 1.18.0
167167
- name: salesforce-reporter
168168
repository: oci://quay.io/codefresh/charts
169169
version: 1.30.11
170-
digest: sha256:814b879b8e7b0b276c66b821c69c2c22febbbec4a30fed89117d50530ae0ea5e
171-
generated: "2025-05-19T23:11:03.858637+03:00"
170+
digest: sha256:4e7b52e0ee6d81e910d3e7352b14cb5a7d01c51a7bcd7a8e455c53cc2564d982
171+
generated: "2025-08-29T15:06:33.935106+03:00"

0 commit comments

Comments
 (0)