Skip to content

Commit 326ad85

Browse files
authored
Merge branch 'master' into fealebenpae/search-grpc
2 parents cb83dbc + b478944 commit 326ad85

File tree

89 files changed

+2765
-965
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

89 files changed

+2765
-965
lines changed

.evergreen-functions.yml

Lines changed: 48 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,19 @@ functions:
222222
working_dir: src/github.com/mongodb/mongodb-kubernetes
223223
binary: scripts/evergreen/setup_docker_sbom.sh
224224

225+
helm_registry_login:
226+
command: subprocess.exec
227+
type: setup
228+
params:
229+
working_dir: src/github.com/mongodb/mongodb-kubernetes
230+
include_expansions_in_env:
231+
- quay_prod_username
232+
- quay_prod_robot_token
233+
add_to_path:
234+
- ${workdir}/bin
235+
- ${PROJECT_DIR}/bin
236+
binary: scripts/release/helm_registry_login.sh
237+
225238
# Logs into all used registries
226239
configure_docker_auth: &configure_docker_auth
227240
command: subprocess.exec
@@ -491,21 +504,24 @@ functions:
491504
- rh_pyxis
492505
binary: scripts/dev/run_python.sh scripts/preflight_images.py --image ${image_name} --submit "${preflight_submit}"
493506

507+
# publish_helm_chart packages and publishes the MCK helm chart to the OCI container registry
508+
publish_helm_chart:
509+
- command: subprocess.exec
510+
params:
511+
working_dir: src/github.com/mongodb/mongodb-kubernetes
512+
binary: scripts/release/publish_helm_chart.sh
513+
494514
build_multi_cluster_binary:
495515
- command: subprocess.exec
496-
type: setup
497516
params:
498517
working_dir: src/github.com/mongodb/mongodb-kubernetes
499-
binary: scripts/evergreen/build_multi_cluster_kubeconfig_creator.sh
518+
binary: scripts/release/kubectl_mongodb/build_kubectl_plugin.sh
500519

501-
build_and_push_appdb_database:
520+
download_multi_cluster_binary:
502521
- command: subprocess.exec
503522
params:
504-
working_dir: src/github.com/mongodb/mongodb-kubernetes/docker/mongodb-kubernetes-appdb-database
505-
binary: ./build_and_push_appdb_database_images.sh
506-
add_to_path:
507-
- ${workdir}/bin
508-
- ${workdir}
523+
working_dir: src/github.com/mongodb/mongodb-kubernetes
524+
binary: scripts/release/kubectl_mongodb/download_kubectl_plugin.sh
509525

510526
build_test_image_ibm:
511527
- command: subprocess.exec
@@ -526,49 +542,9 @@ functions:
526542
working_dir: src/github.com/mongodb/mongodb-kubernetes
527543
binary: scripts/release/pipeline.sh
528544
env:
529-
IMAGE_NAME: ${IMAGE_NAME}
530-
531-
pipeline_agent:
532-
- command: subprocess.exec
533-
retry_on_failure: true
534-
type: setup
535-
params:
536-
shell: bash
537-
<<: *e2e_include_expansions_in_env
538-
working_dir: src/github.com/mongodb/mongodb-kubernetes
539-
binary: scripts/release/pipeline_agent.sh
540-
env:
541-
FLAGS: ${FLAGS}
542-
543-
pipeline_ops_manager:
544-
- command: subprocess.exec
545-
retry_on_failure: true
546-
type: setup
547-
params:
548-
shell: bash
549-
<<: *e2e_include_expansions_in_env
550-
working_dir: src/github.com/mongodb/mongodb-kubernetes
551-
binary: scripts/release/pipeline_ops_manager.sh
552-
553-
pipeline_readiness_probe:
554-
- command: subprocess.exec
555-
retry_on_failure: true
556-
type: setup
557-
params:
558-
shell: bash
559-
<<: *e2e_include_expansions_in_env
560-
working_dir: src/github.com/mongodb/mongodb-kubernetes
561-
binary: scripts/release/pipeline_readiness_probe.sh
562-
563-
pipeline_version_upgrade_hook:
564-
- command: subprocess.exec
565-
retry_on_failure: true
566-
type: setup
567-
params:
568-
shell: bash
569-
<<: *e2e_include_expansions_in_env
570-
working_dir: src/github.com/mongodb/mongodb-kubernetes
571-
binary: scripts/release/pipeline_version_upgrade_hook.sh
545+
IMAGE_NAME: ${image_name}
546+
BUILD_SCENARIO_OVERRIDE: ${build_scenario}
547+
FLAGS: ${flags}
572548

573549
teardown_cloud_qa_all:
574550
- command: shell.exec
@@ -822,21 +798,6 @@ functions:
822798
script: |
823799
./scripts/code_snippets/tests/${task_name}
824800
825-
#
826-
# kubectl mongodb plugin release functions
827-
#
828-
install_goreleaser:
829-
- command: shell.exec
830-
type: setup
831-
include_expansions_in_env:
832-
- goreleaser_pro_tar_gz
833-
params:
834-
script: |
835-
set -Eeu pipefail
836-
curl -fL "${goreleaser_pro_tar_gz}" --output goreleaser_Linux_x86_64.tar.gz
837-
tar -xf goreleaser_Linux_x86_64.tar.gz
838-
chmod 755 ./goreleaser
839-
840801
install_macos_notarization_service:
841802
- command: shell.exec
842803
type: setup
@@ -850,11 +811,28 @@ functions:
850811
unzip -u macos-notary.zip
851812
chmod 755 ./linux_amd64/macnotary
852813
814+
create_chart_release_pr:
815+
- command: github.generate_token
816+
params:
817+
repo: helm-charts
818+
expansion_name: GH_TOKEN
819+
- command: subprocess.exec
820+
type: setup
821+
params:
822+
working_dir: src/github.com/mongodb/mongodb-kubernetes
823+
include_expansions_in_env:
824+
- GH_TOKEN
825+
- workdir
826+
- OPERATOR_VERSION
827+
env:
828+
GH_TOKEN: ${GH_TOKEN}
829+
binary: scripts/dev/run_python.sh scripts/release/create_chart_release_pr.py --chart_version ${OPERATOR_VERSION|*triggered_by_git_tag}
830+
853831
release_kubectl_mongodb_plugin:
854832
- command: github.generate_token
855833
params:
856-
expansion_name: generated_token
857-
- command: shell.exec
834+
expansion_name: GH_TOKEN
835+
- command: subprocess.exec
858836
type: setup
859837
params:
860838
working_dir: src/github.com/mongodb/mongodb-kubernetes
@@ -871,15 +849,7 @@ functions:
871849
- triggered_by_git_tag
872850
- OPERATOR_VERSION
873851
env:
874-
XDG_CONFIG_HOME: ${go_base_path}${workdir}
875-
GO111MODULE: "on"
876-
GOROOT: "/opt/golang/go1.24"
877852
MACOS_NOTARY_KEY: ${macos_notary_keyid}
878853
MACOS_NOTARY_SECRET: ${macos_notary_secret}
879-
# shell.exec EVG Task doesn't have add_to_path, so we need to explicitly add the path export below.
880-
script: |
881-
set -Eeu pipefail
882-
export GORELEASER_CURRENT_TAG=${OPERATOR_VERSION|*triggered_by_git_tag}
883-
export PATH=$GOROOT/bin:$PATH
884-
export GITHUB_TOKEN=${generated_token}
885-
${workdir}/goreleaser release --clean
854+
GH_TOKEN: ${GH_TOKEN}
855+
binary: scripts/dev/run_python.sh scripts/release/kubectl_mongodb/promote_kubectl_plugin.py

.evergreen-release.yml

Lines changed: 54 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ tasks:
99
commands:
1010
- func: clone
1111
- func: setup_building_host
12-
- func: build_multi_cluster_binary
12+
- func: download_multi_cluster_binary
1313
- func: pipeline
1414
vars:
15-
IMAGE_NAME: meko-tests
15+
image_name: meko-tests
1616

1717
- name: release_operator
1818
tags: [ "image_release" ]
@@ -23,7 +23,7 @@ tasks:
2323
- func: quay_login
2424
- func: pipeline
2525
vars:
26-
IMAGE_NAME: operator
26+
image_name: operator
2727

2828
# Releases init images to Quay
2929
- name: release_init_appdb
@@ -35,7 +35,7 @@ tasks:
3535
- func: quay_login
3636
- func: pipeline
3737
vars:
38-
IMAGE_NAME: init-appdb
38+
image_name: init-appdb
3939

4040
- name: release_init_database
4141
tags: [ "image_release" ]
@@ -46,7 +46,7 @@ tasks:
4646
- func: quay_login
4747
- func: pipeline
4848
vars:
49-
IMAGE_NAME: init-database
49+
image_name: init-database
5050

5151
- name: release_init_ops_manager
5252
tags: [ "image_release" ]
@@ -57,7 +57,7 @@ tasks:
5757
- func: quay_login
5858
- func: pipeline
5959
vars:
60-
IMAGE_NAME: init-ops-manager
60+
image_name: init-ops-manager
6161

6262
- name: release_database
6363
tags: [ "image_release" ]
@@ -68,7 +68,7 @@ tasks:
6868
- func: quay_login
6969
- func: pipeline
7070
vars:
71-
IMAGE_NAME: database
71+
image_name: database
7272

7373
- name: release_readiness_probe
7474
tags: [ "image_release" ]
@@ -77,7 +77,9 @@ tasks:
7777
- func: clone
7878
- func: setup_building_host
7979
- func: quay_login
80-
- func: pipeline_readiness_probe
80+
- func: pipeline
81+
vars:
82+
image_name: readiness-probe
8183

8284
- name: release_version_upgrade_hook
8385
tags: [ "image_release" ]
@@ -86,7 +88,9 @@ tasks:
8688
- func: clone
8789
- func: setup_building_host
8890
- func: quay_login
89-
- func: pipeline_version_upgrade_hook
91+
- func: pipeline
92+
vars:
93+
image_name: upgrade-hook
9094

9195
- name: prepare_and_upload_openshift_bundles
9296
tags: [ "openshift_bundles" ]
@@ -119,10 +123,27 @@ tasks:
119123
tags: [ "binary_release" ]
120124
commands:
121125
- func: clone
122-
- func: install_goreleaser
126+
- func: python_venv
123127
- func: install_macos_notarization_service
124128
- func: release_kubectl_mongodb_plugin
125129

130+
- name: create_chart_release_pr
131+
tags: [ "helm_chart_release_pr" ]
132+
commands:
133+
- func: clone
134+
- func: python_venv
135+
- func: create_chart_release_pr
136+
137+
- name: release_chart_to_oci_registry
138+
tags: [ "release_chart_to_oci_registry" ]
139+
commands:
140+
- func: clone
141+
- func: python_venv
142+
- func: setup_kubectl
143+
- func: setup_aws
144+
- func: helm_registry_login
145+
- func: publish_helm_chart
146+
126147
### Release build variants
127148
buildvariants:
128149

@@ -202,6 +223,9 @@ buildvariants:
202223
allowed_requesters: [ "patch", "github_tag" ]
203224
run_on:
204225
- release-ubuntu2404-small # This is required for CISA attestation https://jira.mongodb.org/browse/DEVPROD-17780
226+
depends_on:
227+
- name: release_kubectl_mongodb_plugin
228+
variant: release_kubectl_mongodb_plugin
205229
tasks:
206230
- name: build_test_image_for_smoke_tests
207231

@@ -228,6 +252,8 @@ buildvariants:
228252
depends_on:
229253
- name: "*"
230254
variant: release_images
255+
- name: "*"
256+
variant: init_smoke_tests
231257
tasks:
232258
- name: e2e_smoke_task_group
233259

@@ -239,3 +265,21 @@ buildvariants:
239265
allowed_requesters: [ "patch", "github_tag" ]
240266
tasks:
241267
- name: release_kubectl_mongodb_plugin
268+
269+
- name: create_chart_release_pr
270+
display_name: create_chart_release_pr
271+
tags: [ "release" ]
272+
run_on:
273+
- release-ubuntu2404-small # This is required for CISA attestation https://jira.mongodb.org/browse/DEVPROD-17780
274+
allowed_requesters: [ "patch", "github_tag" ]
275+
tasks:
276+
- name: create_chart_release_pr
277+
278+
- name: release_chart_to_oci_registry
279+
display_name: release_chart_to_oci_registry
280+
tags: [ "release" ]
281+
run_on:
282+
- release-ubuntu2404-small # This is required for CISA attestation https://jira.mongodb.org/browse/DEVPROD-17780
283+
allowed_requesters: [ "patch", "github_tag" ]
284+
tasks:
285+
- name: release_chart_to_oci_registry

.evergreen-snippets.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ variables:
77
- func: setup_mongosh
88
- func: download_kube_tools
99
- func: switch_context
10-
- func: build_multi_cluster_binary
10+
- func: download_multi_cluster_binary
1111
teardown_task:
1212
- func: upload_e2e_logs
1313
- func: upload_code_snippets_logs

.evergreen-tasks.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ tasks:
502502
commands:
503503
- func: "e2e_test"
504504

505-
- name: e2e_disable_tls_scale_up
505+
- name: e2e_disable_tls_and_scale
506506
tags: [ "patch-run" ]
507507
commands:
508508
- func: "e2e_test"
@@ -1116,7 +1116,6 @@ tasks:
11161116

11171117
- name: e2e_multi_cluster_validation
11181118
tags: [ "patch-run" ]
1119-
exec_timeout_secs: 1000
11201119
commands:
11211120
- func: e2e_test
11221121

0 commit comments

Comments
 (0)